I picked up this nifty hack when setting up a new Raspberry Pi 4 without a monitor connected. In fact I’m just acting as a parrot from the web, but here goes:
- Burn your Raspberry OS to the SD card using W32imagewriter
- Create a blank file named SSH on the root of the drive, no content,no extension
- Create a file called wpa_supplicant.conf on SD card root with the following content:
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=<Insert 2 letter ISO 3166-1 country code here>
network={
ssid="<Name of your wireless LAN>"
psk="<Password for your wireless LAN>"
}
And you’re all set 🙂
And by the way, if you’re wondering about your little tweaked RPI4 system temperatures, you could create a small bash script showing this
#!/bin/bash cpu=$(</sys/class/thermal/thermal_zone0/temp) echo “$(date) @ $(hostname)” echo “——————————————-“ echo “GPU => $(/opt/vc/bin/vcgencmd measure_temp)” echo “CPU => $((cpu/1000))’C” |
antoher alternative could be to use Sysinfo PHP, put in on your webserver.
Edit phpsysinfo.new and change line SENSOR_PROGRAM to SENSOR_PROGRAM=Pitemp
Save the file as phpsysinfo.ini