Pi Recipes
We have a number of Raspberry Pi's around our home and family. The little system has been deployed to simplify techno-life, entertain or integrate household technology. This collection of RPi Recipes is maintained to help with builds/rebuilds and may range from half-baked concepts to step-by-step procedures, typically for my own pursuit, but possibly of interest to others. Pi recipes will slowly be migrated to this site from good old Ventures.TPedersen.net as needed, hopefully saving anything important before Google Transitions everyone to 'New' Sites.
Pi Recipes
ServerPi - RPi-based server for local, self-hosted apps and utilities - Evolving, handy
SuitiePi - WiFi AP/Extender using a old RPi 1 Model B - Retired, worked great for years
SmartiePi - Grandkids are outgrowing CutiePi, time for a KidKomputer! - Done, it all works!
HomePi - RPi 3 that provides Apple Air Play and HomeKit Integration Services - Done, handy
CamperPi - Off-grid entertainment Pi for new camper. Gaming, Movies & Music - Now on RPi0W!
SentinelPi - RPi-based network monitor to watch over growing collection of 'Smart Things' - It works!
MiPi - Desktop replacement project. Primary Linux desktop (replaced x86/Mint) - Manjaro works GREAT!!
MoviePi - A Semi-smart TV gizmo for my parents - operates similar to the VCR/DVD they know/love! - Retired
GramPi - RPi-based Windoze XP look-a-like for my parents and other elderly friends - Retired (RIP), worked great!
CutiePi - Grandbaby's Musicbox Pi, initially used to pipe lullabies into nursery - evolving with her! - Done, still evolving
Half Baked (below)
MeePi - Its alive! Currently PICroft based AI thingy. See below ... Active project, but loooong ways to go!
PanelPi - Integrate hardwired home security sensors into smart home - Stalled in VERY Early Stages (see below)
OccuPi - Remote controlled kiosk-like gizmo for my parents TV - Stalled (see below)
ProbePi - RPI-based Vulnerability Scanner and web-based packet sniffer - early, still in the fumbling stage.
<Odds and Ends below>
Half-Baked
(Works in process, likely VERY unsettled)
ProbePi
August 2023 - slight change of direction? ... now looking at Threat Hunting. Lots to learn, compare/contrast with IDS, Vulnerability Scanning, et al
Stumbled upon PIhunter @ https://github.com/jeffvader84/piHunter. Will see if I have a rpi/buster kicking around.
RPI4 2g + a 64g SD (hopefully enough to play with this)
Buster Lite from https://www.raspberrypi.com/software/operating-systems/#raspberry-pi-os-legacy
Sing-a-long with https://github.com/jeffvader84/piHunter/blob/main/README.md
Boot 64g - remember, default uc/pw on raspios was pi/raspberry
sudo raspi-config (while connected to monitor and keyboard)
System Options: Change Pi Password, Set Hostname
Interface Options: Enable SSH
Localisation Options: Set Locale, Timezone & WAN Country code (in case we need it?)
Advanced Options: Expand Filesystem
Haven't played with OpenVAS for a ver y long time, and never on an RPI. Interested to see how its evolved and how all these IoT 'Things' do on vulnerability scans ...
*** June 2023 - initial playtime
Dietpi Base ... DietPi_RPi-ARMv7-Bookworm.img to see if SentinelPi (RPI 2 v1.1) could handle this
Software: Docker and Portainer (port 9002)
OpenVAS via Docker: Sing-a-long with https://pensivesecurity.io/blog/2020/11/16/RPi-Network-Vulnerability-Scanner/
Brute Force install via https://dayne.broderson.org/2018/05/24/RPi_Vulnerability_Scanner.html
Kali via https://www.offensive-security.com/kali-linux-arm-images/ - blow-by-blow on RPI OS Alternatives page
Steps
sudo apt-get install openvas (this substituted gvm)
sudo gvm-setup // Couple of errors (or warnings) when attempting to change directory to /home/kali ... we'll see //
sudo gvm-check-setup // "It seems like your GVM-22.5.0 installation is OK" ... woo hoo! //
sudo greenbone-feed-sync // If any feed sync's faile during setup ... then re-run check-setup until its good to go //Tried to fire up browser to see if https://127.0.0.1:9392/ was alive ... kali hung ... Boot-A-Roo!
<saga will continue>
MeePi [Progress?]
Initial play with private AI gizmo ... ultimately hope to build something creepy like this https://homespace.is/ai
*** May 2023 - Some Mycroft work, apschedule (pip install apscheduler) followed by
routine skill (msm install https://github.com/ChristopherRogers1991/mycroft_routine_skill.git)
*** Feb 2023 - Ack! one step forward, one step back ... I knew Picroft was precarious (Nov 2022 was last of it) but there are some troubles upstream with Mycroft - here's the note from the CEO - https://community.mycroft.ai/t/update-from-the-ceo-part-1/13268. I will monitor and also follow antics of https://openvoiceos.com/
In the meantime .... Taking a look at Rhassby via https://rhasspy.readthedocs.io/. Sing-a-long @ https://rhasspy.readthedocs.io/en/latest/tutorials/#from-scratch-on-a-raspberry-pi
Raspberry Pi imager -> 32-bit RaspOS Lite to 16g SD
Per instructions: Created ssh directory in boot partition and added a known-good wpa_supplicant.conf so I could bootup and ssh in (I didn't know this! Handy!) ... BUT THAT DIDN'T work ... it looks like the new RaspOS requires a user setup (pi is no longer default). Oh well, boot with monitor&keyboard and enable ssh and season to taste! (as always_
via ssh:
Install Docker via - curl -sSL https://get.docker.com | sh
Add pi to docker group - sudo usermod -aG docker pi
<reboooootaaaarooooo> - sudo reboot
ssh back in and (sit tight, this will take time) .... docker pull rhasspy/rhasspy
Then - fire it up via -
docker run -it \
-p 12101:12101 \
-v "$HOME/.config/rhasspy/profiles:/profiles" \
-v "/etc/localtime:/etc/localtime:ro" \
--device /dev/snd:/dev/snd \
rhasspy/rhasspy \
--user-profiles /profiles \
--profile ensudo rebootBrowser in via http://<IP_ADDRESS>:12101
To live through reboot use:
docker run -d \
-p 12101:12101 \
--name rhasspy \
--restart unless-stopped \
-v "$HOME/.config/rhasspy/profiles:/profiles" \
-v "/etc/localtime:/etc/localtime:ro" \
--device /dev/snd:/dev/snd \
rhasspy/rhasspy \
--user-profiles /profiles \
--profile en
Then into getting started guide @ https://rhasspy.readthedocs.io/en/latest/tutorials/#getting-started-guide
--------- Earlier ....
We'll start with https://mycroft.ai/ - Baby steps!
Easiest start is via https://mycroft-ai.gitbook.io/docs/using-mycroft-ai/get-mycroft/picroft. Came right up on RPI3B+ and ran even better on RPI4. Started with monitor, keyboard/mouse and HDMI sound. Good way to get to know mycroft and related components.
*** Jan 21 2023 - back to picroft image ...
Fixed on major roadblock to my headless hardware set up ... could not get audio to come out of standard 3.5mm headphone jack
using raspi-config or mycroft-setup-wizard. Finally brute force fix it via these steps:Check list of audio playback hardware using aplay command - it looks like this:
$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: b1 [bcm2835 HDMI 1], device 0: bcm2835 HDMI 1 [bcm2835 HDMI 1]
Subdevices: 4/4 Subdevice #0: subdevice #0
Subdevice #1: subdevice #1
Subdevice #2: subdevice #2
Subdevice #3: subdevice #3
card 1: Headphones [bcm2835 Headphones], device 0: bcm2835 Headphones [bcm2835 Headphones]
Subdevices: 4/4
Subdevice #0: subdevice #0
Subdevice #1: subdevice #1
Subdevice #2: subdevice #2
Subdevice #3: subdevice #3Edit /etc/mycroft/mycroft.conf to set correct card number (hw:1 is headphone jack) ... first 2 lines in my .conf
// Oddly, didn't have to mess with conf to get sound & mic working this time around currently set to:
"play_wav_cmdline": "aplay -Dhw:0,0 %1",
"play_mp3_cmdline": "mpg123 -a hw:0,0 %1",Set rpi activity let to 'heartbeat' rather than sd activity ... more appropriate for a headless gizmo like this!
Edit good old /boot/config.txt using stuff found in /boot/overlays/README (heartbeat is also a load indicator, we'll know if picroft is working harder)
# TPed was here trying to turn RPI act led into heartbeat rather than
dtparam=act_led_trigger=heartbeat
Start to make it me!
mycroft-config edit user
{
"max_allowed_core_version": 21.2,
"hotwords": {
"hey papa": {
"module": "precise",
"phonemes": "HH EY . P AA P AH",
"threshold": 1e-90,
"lang": "en-us"
},
"wake up": {
"module": "pocketsphinx",
"phonemes": "W EY K . AH P",
"threshold": 1e-20,
"lang": "en-us"
}
},
"listener": {
"wake_word": "hey papa"
}
}
mycroft-config set listener.wake_word "hey papa"
Reference stuff moved from Pi-in-the-sky area
https://iotdesignpro.com/projects/how-to-build-ibm-watson-chatbot-using-raspberry-pi-and-tjbot
https://python-telegram-bot.org/
From Class:
https://www.aclweb.org/portal/
Spacy.io - Industrial Strength Natural Language Processing
Gensim Topic Modelling for Humans @ https://radimrehurek.com/gensim/
Mycroft.ai Stuff:
Underpinnings @ https://mycroft.ai/initiatives/
https://github.com/sparky-vision/mycroft-precise-tips
----------------------------------------------
**** Dietpi abort (hopefully just a pause) struggling with permissions (I think when I try to run mycroft utilities - like skill maker (mycroft-msk) .... ****
I moved on to fav foundation - dietpi. doc/quickstart @ https://dietpi.com/docs/. Mycroft is part of optimized software library *and* seems to run better than the picroft image, see https://dietpi.com/docs/software/hardware_projects/#mycroft-ai.
NetAidPi+Internet-Pi ServerPi [Overcooked]
This one looks like a keeper! ... I'll cleanup the recipe below and probably call ours "ServerPi". It is now basically a local utility server with a nice face (UI) .... I think there will be a number of handy Self-Hosted apps to come.
------
Project history (in nutshell): Started looking into monitoring our ISP internet speeds and stumbled upon https://github.com/geerlingguy/internet-pi with thoughts of cramming it into SentinelPi. Had many struggles attempting to get Internet-pi in/up/running and ended up building a utility server that combines a number of handy local network services and links (instead of Browser bookmarks). The server was initially built using DietPi, Pi-Hole, Speedtest Tracker, docker (portainer) and a friendly web face (homer). This server will be foundation for our self-hosted apps - including Internet Speedtest-tracker to monitor our ISP (much easier).
Initially just replaced/documented our NetAidPi. It was an old rpi (Model B!) that has been running on the network for quite a long time (Pi-hole, Murmer and some other services that I didn't even remember! Simply notes for now ....
-------
Sometime between March and August 2023
Added File Browser from Dietpi software: https://dietpi.com/docs/software/cloud/#file-browser
March 2023: Too many eggs in this basket? Had to do a rebuild due to networking issues (it now really hurts when pi-hole server goes down!)
Also lots of putzing and playing with dietpi software ....
Removed MotionEye (beta and it's friend FFmpeg) ... not sure if these caused issues but wasn't really needed
Removed hostapd (aka WiFi Hotspot) ... used temporarily and possibly cause of networking issues (docker+pi-hole+hostapd=NetConfusion?)
V2 mods
To help SentinelPi downgrade to RPI2 .... Moved grafana to ServerPi .... sort of creates a rats-nest of gizmo that rely on each other but we'll see
77 Grafana: platform for analytics and monitoring
Decided to go with MariaDB instead of SQLite (noticed that many SH apps need more)
81 LLMP: Lighttpd + MariaDB + PHP
Skipped Folding@Home for now .... keep it simple
---------------
From the beginning .... hopefully final
dietpi, downloaded https://dietpi.com/downloads/images/DietPi_RPi-ARMv8-Bullseye.7z
rpi imager ... just a couple of mins
Boot on the target network and config via ssh (pi-hole needs static IP)
Dietpi setup (approx 10 mins)
Change passwords
Disable serial/UART
Dietpi-config
Display->GPU Memory Split to 16 (server)
Language/Local->Season to taste (timezone)
Security->Set Hostname
Network Adapters->Wifi off, Ethernet set to Static (for Pi-Hole's sake) ... will need to re-ssh after this one is applied
<fumble thru reconnect & reboot here>
Dietpi Software
2 Folding@Home: distributed disease research project. Interface @ http://<NetAidPi>:7396/
17 Git: Clone and manage Git repositories locally
34 PHP Composer: Package manager for PHP
77 Grafana: platform for analytics and monitoring
81 LLMP: Lighttpd + MariaDB + PHP
89 PHP: Hypertext Preprocessor for dynamic web content
93 Pi-hole: block adverts for any device on your network. Interface @ http://<NetAidPi>/admin
// Don't forget to record admin PW during install or you will need to do one of these: pihole -a -p //94 ProFTPD: Efficient, lightweight FTP server
103 DietPi-RAMlog: Makes /var/log a RAM disk, preserves file structure on reboot
104 Dropbear: Lightweight SSH server
130 Python 3: Runtime system, pip package installer and development headers
162 Docker: Build, ship, and run distributed applications
185 Portainer: Simplifies container management in Docker (standalone host). Interface @ http://<NetAidPi>:9002
// Set password when you first fire it up via browser - do it soon after install or it times out and needs to be restarted200 DietPi-Dashboard: Official lightweight DietPi web interface. Interface @ http://<NetAidPi>:5252
// Config @ /opt/dietpi-dashboard/config.toml205 Homer: Homer is a modern and lightweight dashboard & homepage for your services. Interface @ http://<NetAidPi>/homer
Non Dietpi software
My buddy joe, the editor: apt-get install joe
Speedtest-tracker installed via portainer - doc @ https://docs.speedtest-tracker.dev/
Clink on local Environment (set up above) - click around until you add a Stack
In create Stack dialog:
name=speedtest-tracker (must be lower case)
Web Editor, paste in Docker Compose (sqlite) snippet from https://docs.speedtest-tracker.dev/getting-started/installation
Clink on Deploy Stack
Interface @ http://<NetAidPi>:8080/ - default uc/pw= admin@eample.com/password
Settings: Set timezone
Authentication currently required even though there is a toggle. update periodically to see new features
<Test everything here>
Pull it all into homer screens
icons (I made 64x64 png) are stored in /var/www/home/assets/icons
homer as doc root in lighttpd.conf - DONT DO THIS! Then EVERYTHING must be under homer!
server.dir-listing = "enable" OR dir-listing.activate = "enable"
---------------
Notes from Attempt #4 - Looks like a keeper. Decided that NetAidPi will remain standalone, I forgot that SentinelPi sits on a mirrored Ethernet port, it sees all IoT traffic, NetAidPi doesn't need all that. Also upgraded to RPI4 for ISP monitoring (RPI3B+ ethernet seemed to max out ~150M) and for folding@home.
Homer is nice - pulling together all home hardware/servers/apps that have web interfaces.
See https://github.com/bastienwirtz/homer/blob/main/README.mdLearning about FontAwsome @ https://www.webdevsplanet.com/post/font-awesome-icon-style-classes
It also has some <can't remember what I was going to type here ... fun!>
Had to install php for Pi-Hole ...I was getting "503 Service Unavailable" when accessing Admin console. Dietpi software is missing something (either with Lighttpd or Pi-Hole)
I'll cut an image of NetAidPi at this point ... it works! "Internet-pi" made a mess in here last time
Uninstalled unbound dns *and* pi-hole because pi-hole was coughing up errors instead of statistics on its dashboard - "unknown error while loading data". Seems better
Will try https://docs.speedtest-tracker.dev/ this time around ... docker via portainer
Aiming at this UI (I use grafana on sentinelpi) https://grafana.com/grafana/dashboards/17460-speedtest-tracker-v2/
installed docker, docker-composer, portainer and sqlight, lighttpd from dietpi software
----------
Attempt #3! ACK ACK ACK - Enough with https://github.com/geerlingguy/internet-pi! Way too complicated for the problem at hand ... I just need a speedtest script/datastore, a dashboard *AND* I want to see how it all goes together!!!!! RaspOs, intrnet-pi (and friends) was blowing up all over the place - I was chasing missing packages, path issues and my usual config fumblings (due to briefly scanning instructions!)
------------------------
Attempt #2 - ACK ACK! This was a bust too! All sorts of fumbling installing ansible (missing rust complier ... followed by comedy of errors)
----------------
Attempt #1 - ACK! This was a bust! Internet-pi seems to be dependent on stock raspos (maybe pi user? I'll revisit at some point)
MonitorPi or ContainmentPi [Done, Good One!]
This one is turned into SentinelPi - original notes/fumbling/flailing moved over there
SmartiePi - First Computer for 4-6 Year Old [Done]
Jan 2023: FINALLY Back at it! Ran GCompris on stock RPIOS for the heck of it and it ran MUCH better than on DietPi ... not sure why, but it's running great on an RPI3 and looks like it will live in harmony with CutiePi world if need be .. .
Final notes/recipe @ SmartiePi - First Computer for 4-6 Year Old
Feb 2022: Moved to this site. Cut/Paste from 'Classic' Google site page @ http://ventures.tpedersen.net/errata/raspberrypi/smartiepi ... did not paste in very well!
WiFi Bootstrapping : Comitup+Dietpi [Works!], Comitup+Q4OS [TBD]
I often make Pi's for others - pre-configuring them for WiFi in someone else's home is a pain in the drain!
Gave Comitup a quick once over - there was a downloadable image @ https://davesteele.github.io/comitup/. It looks to be JUST what I need AND it WORKS!
Posted experiences with the downloadable image (RaspOS that boots up with Comitup) in Raspberry Pi OS Alternatives.
I am currently exploring installing/incorporating Comitup packages into my projects as opposed to starting with the image because I use a variety of OS underpinnings - Q4OS, DietPi, Manjaro ... it (comitup-1.15-1) seems to be in latest RaspOS which should allow me to apt-get install on everything except Manjaro. I don't see it in Manjaro or Arch AUR
Dietpi+Comitup:
Downloaded Dietpi ARMv6 32-bit. Uses the Raspbian package repository which provides comitup for install!
Booted on RPi4 to start with ... usual blow-by-blow
Auto updates itself & reboots - now at v8.3.1 - ~5min
Forced PW changes, disabled serial console
Dietpi config/software
Audio: Enabled, Sound card usb-dac (I'm going to mess with CutiePi enhancements first)
Language/Regional: Locale en_US.UTF8, Timezone & us keyboard
Security: Set Hostname
Network/Adapters: Enable Wifi
Network/Other: Turned Off Boot wait for network (just to be safe)
Dietpi Software (season to taste: I installed stuff I want to live/play together): Shairport, Murmur, Raspotify, RPI.GPIO, python3, go, ALSA, GIT
Stuff I had to install by hand ... via ssh
My editor: good old joe - apt-get install joe
comitup from https://davesteele.github.io/comitup/ - apt-get install comitup
// Whoops! WiFi was disabled by default in Dietpi, comitup choked during install - Make sure you add Network steps in dietpi-config above //Whoops AGAIN! I forgot to RTFM @ https://github.com/davesteele/comitup/wiki/Installing-Comitup ... and I quote:
Allow NetworkManager to manage the wifi interfaces by removing references to them from /etc/network/interfaces.
Rename or delete /etc/wpa_supplicant/wpa_supplicant.conf.
The systemd.resolved service should be disabled and masked to avoid contention for providing DNS service.
The line dns=dnsmasq should not be in /etc/NetworkManager/NetworkManager.conf.
also changed default ssid in /etc/comitup/comitup.conf - now ap_name: <hostname>-<nnn>
I also added comitup to dietpi-services (right or wrong?)
comitup-cli is a useful command line tool here
Hey! It works!
Q4OS+Comitup
<next in queue ... I'd think it would work, raspos-based>
FlypaperPi (Honeypot) [Interesting]
Playing w/ OpenCanary Honeypot ... this is a mess/work-in-process
Sing-a-long w/ https://github.com/thinkst/opencanary#readme but ....
.... watching this one as I do: https://simpaul.com/opencanary-on-a-pi-quick-setup/
Step by step (notes to self)
RPIOS - lite is fine, usual setup: update/upgrade, rpi-config: pw, hn, local/kb, yada/yada
Switch to Ubuntu 20.04 LTS 32-Bit for 3 reasons - NOPE! That came out badly
From guide ....
OS Tweaks: Set interesting Mac Address (per Paul's guide) ... add "smsc95xx.macaddr=<enticing mac>" to cmdline.txt
Python Prep is a combo Open Canary Guide & Paul's (Including samba and scapy/pcapy because I want it all!)
sudo apt-get install python3-dev python3-pip python3-virtualenv python3-venv python3-scapy libssl-dev libpcap-dev
sudo apt install samba # if you plan to use the smb moduleBack to Paul's guide - looks like he skipped virtual env this go round ... sounds simpler
pip3 install --upgrade setuptools
git clone https://github.com/thinkst/opencanary
cd opencanary
sudo apt-get install libffi-dev # Paul may have missed this one, fatal err missing
sudo python3 setup.py install
Set up a couple of links ... from Paul's guide but check version of scripts directory in copy below ... his were 3.7, mine are 3.9
sudo link /usr/local/bin/twistd /home/pi/opencanary/bin/twistd
sudo cp ./build/scripts-3.9/opencanary.tac /usr/local/bin/opencanary.tacBack to Opencanary guide for this part ... it did generate config file for me
$opencanaryd --copyconfig
[*] A sample config file is ready /etc/opencanaryd/opencanary.conf
[*] Edit your configuration, then launch with "opencanaryd --start"Edit /etc/opencanaryd/opencanary.conf ... I just poked around initially - Banners
Fire it up ... see if it runs foreground
opencanaryd --devCouple of warnings to cleanup from initial run ...
<clip>
UserWarning: You do not have a working installation of the service_identity module: 'No module named 'service_identity''.
Please install it from <https://pypi.python.org/pypi/service_identity> and make sure all of its dependencies
are satisfied. Without the service_identity module, Twisted can perform only rudimentary TLS client hostname verifica
tion. Many valid certificate/hostname mappings may be rejected.
I'm a good guesser ... closed my eyes and fixed this via ...
pip3 install service_identity
Turn it into a service so it starts on boot (thx again, Paul)
File /etc/systemd/system/opencanary.service created, it now contains:
[Unit]
Description=OpenCanary honeypot
After=syslog.target
After=network.target
[Service]
User=root
Restart=always
WorkingDirectory=/home/pi/opencanary
ExecStart=/home/pi/opencanary/bin/opencanaryd --dev
[Install]
WantedBy=multi-user.target
Fire it up ...
sudo chmod 644 /etc/systemd/system/opencanary.service
sudo systemctl enable opencanary.service
sudo systemctl start opencanary.service
sudo systemctl status opencanary.serviceBoot ... to see what happens
enough for now ...
-----------------
Leftovers to deal with
pip install scapy pcapy # optional
Install fail that forced me to install libffl h
Whoops! that failed
No package 'libffi' found
c/_cffi_backend.c:15:10: fatal error: ffi.h: No such file or directory
15 | #include <ffi.h>
| ^~~~~~~
Samba install output (in case I need it)
Setting up samba (2:4.13.13+dfsg-1~deb11u3) ...
Adding group `sambashare' (GID 125) ...
Done.
Samba is not being run as an AD Domain Controller: Masking samba-ad-dc.service
Please ignore the following error about deb-systemd-helper not finding those services.
(samba-ad-dc.service masked)
Created symlink /etc/systemd/system/multi-user.target.wants/nmbd.service → /lib/systemd/system/nmbd.service.
Failed to preset unit: Unit file /etc/systemd/system/samba-ad-dc.service is masked.
/usr/bin/deb-systemd-helper: error: systemctl preset failed on samba-ad-dc.service: No such file or directory
Created symlink /etc/systemd/system/multi-user.target.wants/smbd.service → /lib/systemd/system/smbd.service.
samba-ad-dc.service is a disabled or a static unit, not starting it.
Processing triggers for man-db (2.9.4-2) ...
Processing triggers for libc-bin (2.31-13+rpt2+rpi1+deb11u2) ...
CutiePi V4 Collection [Kinda Stalled]
A few links at this point ... my bookmarks are a mess
https://github.com/mental32/spotify.py
Related: Murmer Server for Push4Papa testing
DietPi software - https://dietpi.com/docs/software/media/#murmur
Murmer Server config @ /etc/mumble-server.ini
Also: Dietpi possibilities for V4
Samba instead of FTPing - https://dietpi.com/docs/software/file_servers/#samba
Raspotify? Playlist rather than uploaded songs/sounds?
Lighttpd for configing and such - https://dietpi.com/docs/software/webserver_stack/#lighttpd
TightVNC Server [Looks OK]
Bottomline: This MAY work if I need it ... more putzing to do to get it installed and not as full featured as rpi default vnc server (realvnc).
Considerations/ToDo's
- XP lookswitcher (XPQ4 Desktop) does not show in remote session (I'm probably NOT in the session I'd like to be)
- Below includes definitions for systemd service but I think I'd just fire this up via CLI on an as needed basis
- I still need to double check that it works via remote.it (remote control gizmo I use)
-------
Motivation: Struggling with stock (RealVNC) vncserver on latest GramPi rebuid ... thought I'd try TightVNC for the heck of it
Rough notes as I go ... Working with Q4OS, but I'd guess this will work on RaspiOS too
TightVNC looks to be GPL, actively maintained and has been around for a long time (> 10 years).
Most doc seems to be focused on windoze, but this guy posted a RPi step-by-step
Notes as I go in case I need to retrace my steps
Turned off stock VNC Server via sudo raspi-config -> Interface Options -> Disable VNC
Install via sudo apt-get install tightvncserver (this did remove package realvnc-vnc-server)
Initial run of vncserver to setup passwords ... it went a little like this ...
vncserver
You will require a password to access your desktops.
Password:
Verify:
Would you like to enter a view-only password (y/n)? n
New 'X' desktop is GramPiV2:1
Creating default startup script /home/pi/.vnc/xstartup
Starting applications specified in /home/pi/.vnc/xstartup
Log file is /home/pi/.vnc/GramPiV2:1.logCreate service per devdude's example, it looks like this:
cat /etc/systemd/system/vncserver.service
[Unit]
Description=TightVNC Server
After=network.target
[Service]
Type=forking
User=pi
ExecStart=/usr/bin/vncserver :1
ExecStop=/usr/bin/vncserver -kill :1
[Install]
WantedBy=multi-user.target
Enable the service to get links built and such ... like this
sudo systemctl enable vncserver
systemctl status vncserver
● vncserver.service - TightVNC Server
Loaded: loaded (/etc/systemd/system/vncserver.service; disabled; vendor preset: enabled)
Active: inactive (dead)
pi@GramPiV2:~ $ systemctl enable vncserver
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-unit-files ===
Authentication is required to manage system service or unit files.
Multiple identities can be used for authentication:
1. pi
2. root
Choose identity to authenticate as (1-2): 1
Password:
==== AUTHENTICATION COMPLETE ===
Created symlink /etc/systemd/system/multi-user.target.wants/vncserver.service → /etc/systemd/syste
m/vncserver.service.
==== AUTHENTICATING FOR org.freedesktop.systemd1.reload-daemon ===
Authentication is required to reload the systemd state.
Multiple identities can be used for authentication:
1. pi
2. root
Choose identity to authenticate as (1-2): 1
Password:
==== AUTHENTICATION COMPLETE ===
Tested via screen sharing on macbook and tigervnc viewer on linux ... seems to work
some notes ...
- port is 5901
- not as full featured as realvnc
OccuPi - Remote Controlled Full Screen Kiosk-Like thingy [Stalled]
Moved to tech.tpedersen.net Feb 2022. Cut'n Paste from 'Classic' Google site page @ http://ventures.tpedersen.net/errata/raspberrypi/occupi ... VERY STRANGE, this page pasted into new sites quite well, PanelPi was a total mess!
OccuPi - Remote Controlled Full Screen Kiosk-Like thingy
Last update: 09 October 2020
Original 15 September 2020
VERY EARLY Stages, this page will be a mess as I stumble thru this ...
The Goal is to build a little Pi that will connect to my parents TV to allow me to share (project) videos, web pages and such. Will be used during COVID-19 to keep them occupied over the winter months. More to come as this idea develops.
Notes/Updates
09 Oct: Struggling to find OS fast enough to use Google Streetview in Full Screen or Kiosk mode on a Raspberry Pi 3. It appears that I MUST run Chromium browser to pull this off. Have tried Arch, Dietpi and Raspbian lite. On to Chromium OS. Also created subordinate startpage to simplify testing ... we may end up with a simple webpage providing links to all activities,
25 Sept: General concept works very well, even had an old gyration remote control working with it. RaspOS was painfully slow on the RPi3. Switching to LXDE desktop from Dietpi to see how that runs. Dietpi has been my goto for servers, really haven't played with desktop.
Dietpi/Chromium kiosk is pretty slow. Friggin streetview map is upside down too! Added a startpage to facilitate adding activities/features without connecting to or messing with OccuPi system
Research/Reference
- https://blog.gordonturner.com/2020/06/30/raspberry-pi-full-screen-browser-2020-05-27-raspios-buster/
- https://www.instantstreetview.com/
- https://peter.sh/experiments/chromium-command-line-switches/
- Upside down google maps - https://www.raspberrypi.org/forums/viewtopic.php?f=91&t=274315
- Bigscreen Project - https://plasma-bigscreen.org/
- Chromium OS - Image to try quickly here - https://github.com/FydeOS/chromium_os-raspberry_pi/releases
- Chromium remote desktop - https://remotedesktop.google.com/?pli=1
- Puffins OS - https://www.puffin.com/raspberry-pi/ - Install
Software
- Stock RaspOS - Raspberry Pi OS (32-bit) with desktop to start
- Switching to Rspbian via Dietpi
Hardware
- RPi 3
- 16g
- Old Gyration MCE Remote!
Dietpi Setup Notes
Diepi-config ... minimal work here, let software packages tweak as needed
Language/Regional: en_US.UTF-8, set TZ and US Keyboard
Security: Set Hostname
Autostart: Try Chromium under browser kiosk! - NOT YET!
dietpi-software
[X} Chromium: web browser for desktop or autostart
[X] RealVNC Server: desktop for remote connection
[X] Remot3.it: (Weaved) access your device over the internet
REMEMBER to select START INSTALLATION!
NOW back to diet-pi-config
Autostart: Chromium under browser kiosk!
----------- RaspOS aborted for now - Save in case I fallback -----------
Steps (raspos)
Etcher
New RaspOS (or whatever) resizes & does a GUI setup on first boot
Set Language, Timezone and keyboard
Forces user pi password change
Screen Setup - gets rid of boarder
WiFi Connect (if needed)
Software Update - But .... "Error Comparing Versions" - Nice try!
<Attempted reboot ... but I wasnt read!>
Via Terminal - sudo raspi-config
Boot Options
Desktop w/ Autologin Pi
Wait for Network
Graphical Splash Screen
Interfacing Options
SSH Enable (for remote me!)
VNC Enabled (for remote me!)
Couple of Installs
Joe - my editor of choice -> sudo apt-get install joe
remote.it - Remote Control software (nice)
sudo apt-get install remoteit (to install)
http://occupi.local:29999 (to config - sooo nice!)
Now Attempt Full Screen Browser ...
from https://blog.gordonturner.com/2020/06/30/raspberry-pi-full-screen-browser-2020-05-27-raspios-buster/Finally learning to follow directions!
sudo apt-get update -y
sudo apt-get upgrade -y
sudo apt-get dist-upgrade -y
sudo apt-get autoremove -yInstall Dependencies
sudo apt-get install -y ttf-mscorefonts-installer unclutter x11-xserver-utils
According to guide:
ttf-mscorefonts-installer adds common web fonts
unclutter is used to hide the mouse cursor
x11-xserver-utils installs xset, which is used to disable screen blanking
PanelPi - Integrate hardwired home security sensors into smart home [Stalled]
Last Update - 21 July 2020
Here wee go again! PanelPi - A little Pi help to integrate old wired alarm system
*** VERY early in the project, this page is expected to be a mess for quite a while (as usual) ***
Background
PanelPi was initially cobbled together to explore sprucing up our wired home security system. Current plan is to integrate a number of hardwired sensors into our 'Smart' home. We'll see!
Software
Dietpi.com - My Favorite! Download latest RPI version (Donate!)
Etcher.io - Much easier way to flash OS images to SD
Couple of Software installs from DietPi's Optimised Software Collection
OpenSSH instead of Dropbear SSH Server. Supports SCP xfers
RPi-Monitor - Web interface system stats
RPi.GPIO - gpio interface library for rpi (python)
WebIOPi - web interface to control rpi.gpio
WebIOPi - web interface to control GPIO. Install by hand dietpi install fails
Hardware
Current Config
Raspberry Pi 1 Model B. Arm6 w/ Ethernet + two USB ports
EDIMAX USB WiFi adapter
Old/Original RPi Power Supply (1 amp!)
Really Old 8g Micro USB card
Multimeter, some hook clip test thingies (from my Burroughs days!!!)
Stuff to Explore
Shelly.cloud - Smart relays, switches, sensors
Konnected.io - Designed to smarten old wired alarms/sensors
https://reolink.com/use-upgrade-existing-home-security-alarm-system/
https://www.instructables.com/id/Ethernet-Enabled-DSC-Home-Security-System/
Step by Step (rough notes to self, I'll cleanup later)
Phase I - Pi in Panel.
Get Panel online - currently in Wifi deadspot. Use Webiopi to see what is going on with existing sensors.
Dietpi via etcher
dietpi-config - as usual - security, naming, etc
dietpi-software: Openssh + RPI-Monitor, RPi.GPIO from optimized software list
Don't forget my editor - apt-get install joe
Webiopi via instructions @ http://webiopi.trouch.com/INSTALL.html
Easiest to download via gui on main system and scp to PanelPi. Syntax:
scp WebIOPi-0.7.1.tar.gz root@panelpi:/home/WebIOPi-0.7.1.tar.gz
Via SSH:
Install (setup.sh took a looong time on RPi 1!)
$ tar xvzf WebIOPi-x.y.z.tar.gz
$ cd WebIOPi-x.y.z
$ ./setup.shFire it up to test
webiopi -d -c /etc/webiopi/config
Access via http://panelpi:8000
Default user/pw "webiopi"/"raspberry".
Change pw using webiopi-passwd
Check /etc/webiopi/config
Run a daemon
/etc/init.d/webiopi start/stop
Start at boot
update-rc.d webiopi defaults
<reboot> to get the witches out and to make sure it all comes up OK before disconnecting keyboard & monitorand moving to the panel!
Cleanup
RPi Monitor data.conf (no ethernet): Comment out network.conf, uncomment wlan.conf
Disable wifi powersave mode (iwconfig wlan0 power off DID NOT WORK)
iw dev wlan0 set power_save offReboot with old PS, just to make sure it works!
Hardware Contraption
<coming soon>
Notes
- PanelPi will have to Wifi to SuitiePi - forgot to run Ethernet to panel area when I had wall out!!! Argh!
- remember to static route and reserve dhcp so I can find/access PanelPi on that subnet
- WebIOPI did not install via Dietpi ... attempting by hand
- RPi 1 Model B -> Install instructions @ http://webiopi.trouch.com/INSTALL.html
- RPi 2 and beyond (40pin GPIO) @ https://thepiguy.altervista.org/webiopi-rp3/
Log, Odd and Ends and fond memories
July 2020 - rebuild
Can't recall details but had to rebuild, Dietpi Buster
Decided to switch to RPI 1 Model B - good use for it
26-pin GPIO is fine.
FINALLY traced my steps .... current recipe above
June 2020 - Back at it
Had to turn on WiFi reconnect in dietpi-config. I wonder if wifi is dowzing off, powersave?
downloaded attached a GPIO pinout leaf - We'll see if it helps, pretty small print for old eyes!
https://github.com/splitbrain/rpibplusleaf
- Ghazooks! To keep all this stuff going on our network remember the following.
Add host to local DNS in protected router
DHCP reservation in AP (SuitiePi), remember to change when hardware is swapped
Static Route to PanelPi in ISP router