-
Notifications
You must be signed in to change notification settings - Fork 1
Raspberry Pi Installation
Download a Raspbian image (or Raspbian Lite, which doesn't include a GUI) and follow the official installation guide to copy it to an SD card.
In short (for Linux):
sudo dd bs=4M if=raspbian-jessie.img of=/dev/mmcblk0
where /dev/mmcblk0 is the SD card and raspbian-jessie.img the unzipped Raspbian image.
Then insert the SD card into the Raspberry Pi.
sudo apt update
sudo apt full-upgrade
(Timezone, GPIO, Boot, Change password, ...)
sudo raspi-config
sudo dpkg-reconfigure keyboard-configuration
Follow the instructions. In short:
Scan for networks:
sudo iwlist wlan0 scan
Add to the bottom of the file /etc/wpa_supplicant/wpa_supplicant.conf:
network={
ssid="The_ESSID_from_earlier"
psk="Your_wifi_password"
}
Then:
sudo ifdown wlan0
sudo ifup wlan0
To check if IP address has been assigned:
ifconfig wlan0
To solve Wifi connection problems I installed a cronjob which automatically reconnects the Wifi if the connection gets lost:
Create the file /usr/local/bin/wifi-rebooter.sh:
#!/bin/bash
# The IP for the server you wish to ping (10.0.0.5 is my router, 8.8.8.8 is a public Google DNS server)
SERVER=10.0.0.5
# Only send one ping, sending output to /dev/null
ping -c1 ${SERVER} > /dev/null
# If the return code from ping ($?) is not 0 (meaning there was an error)
if [ "$?" != 0 ]
then
echo "Restart the wireless interface"
#ifdown --force wlan0
# note: for some reason the above will not stop wpa_supplicant, therefore:
wpa_action wlan0 stop
ifup wlan0
fi
Make sure to replace the SERVER address with the IP address of your router or a public server (like the Google server 8.8.8.8).
Make it executable:
sudo chmod +x /usr/local/bin/wifi-rebooter.sh
Add this line to /etc/crontab:
*/5 * * * * root /usr/local/bin/wifi-rebooter.sh 2>&1 | /usr/bin/logger -t wifi-rebooter
Oh, Balcony is Oliver and Hermann's system for automated irrigation (watering) of plants on our balcony using a Raspberry Pi or Arduino. The balcony irrigitation controller is extensible with components like tanks, pumps, valves, soil moisture sensors, hoses (e.g. Gardena Micro-Drip) and can also be used as an irrigation controller for a garden.
--
Oh, Balcony ist Oliver und Hermanns System zur automatischen Bewässerung der Pflanzen auf unserem Balkon mit Hilfe eines Raspberry Pi bzw. Arduino. Das flexible System zur Balkonbewässerung lässt sich beliebig um Komponenten wie Wassertanks, Pumpen, Ventile, Feuchtigkeitssensoren, Schläuche (z.B. Gardena Micro-Drip) erweitern und auch zur Bewässerung eines ganzen Garten einsetzen.