Some stuffs…
To check if we are on lite version, (well one way to do it…) is to check if raspberrypi-ui-mods package is installed. The following command will return nothing if it is not installed - so, we are probably on lite then.
$ sudo apt list raspberrypi-ui-mods --installed
I run desktop-less Raspbian (Buster) and somehow the timezone got reset. To set that,
# sudo timedatectl set-timezone Asia/Kuala_Lumpur
Edit /etc/hostname
and /etc/hosts
- modify accordingly, and reboot immediately.
$ name=my1pi $ prev=$(cat /etc/hostname) $ sudo sed -i "s/$prev/$name/" /etc/hostname $ sudo sed -i "s/$prev/$name/" /etc/hosts $ sudo reboot
The simplest way is… install xscreensaver and disable it!
# sudo apt install xscreensaver
Script to make Pi an e-Photo Frame.
#!/bin/bash SHOW_PATH="/home/pi/Pictures" [ -d "$1" ] && SHOW_PATH=`cd $1;pwd` SHOW_EXEC="feh" SHOW_FULL=`which $SHOW_EXEC 2>/dev/null` # args: delay 5s, fullscreen, recursive, randomize SHOW_ARGS="-D5 -F -r -z" echo "Accessing pictures in $SHOW_PATH..." # press esc to quit? ${SHOW_FULL} ${SHOW_ARGS} ${SHOW_PATH}
$ ifconfig eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 10.170.7.195 netmask 255.255.255.0 broadcast 10.170.7.255
$ netstat -nr Kernel IP routing table Destination Gateway Genmask Flags MSS Window irtt Iface 0.0.0.0 10.170.7.1 0.0.0.0 UG 0 0 0 eth0 10.170.7.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
/etc/network/interfaces
and change iface eth0 inet dhcp
to
iface eth0 inet static address xxx.xxx.xxx.xxx netmask xxx.xxx.xxx.xxx network xxx.xxx.xxx.xxx broadcast xxx.xxx.xxx.xxx gateway xxx.xxx.xxx.xxx
note: fill in the info accordingly
Note Got these from R-Pi site.
The HDMI monitor (or HDMI adapter) may only support a limited set of formats for CEA (TV) or DMT (Monitor). To find out which formats are supported, use the following method:
Then edit config.txt to select:
Note: This assumes a Raspbian installation with desktop environment, and username is pi.
/home/pi/.config/autostart
[Desktop Entry] Type=Application Name=Monitor Exec=/path/to/exec
#!/bin/bash chromium-browser http://server.local:1337 --start-fullscreen