Installation goes fine and I can access emoncms but I’m struggling with connecting to the pi zero W after a reboot; I think there may be something going on with DHCP on my router or it could be an issue with wifi configuration of the pi zero W. When I have it figured out, I’ll update, but things are looking good for using the script on a pi zero W.
I’ve run the emonscript a few times for installation on the raspberry pi zero w and every time it works great right after the installation but if I perform a reboot, the pi will not connect to my wifi network and I cannot access the raspberry pi zero w…
I’ve checked the /etc/wpa_supplicant/wpa_supplicant.conf before initiating a reboot and it has my SSID and password in there; so i’m thinking that at start up it is changing the network configuration to something that is not my SSID.
I also get an error that the hostname raspberry.local is invalid at the end of installation, per the emonsd.sh script. I’ll investigate a little more.
Hi @ajw85 I moved it to a new thread so I could actually find it!
I have been thinking about this @TrystanLea, I think the scripted WiFi installation needs some modification. For the prebuilt image, what is done is correct, but if a user is running the script, they must either have Console or SSH access to the Pi command line. In this case the raspi-config utility can be used.
I think the default position for the scripts should be that the WiFi AP is not installed but the module to manage WiFi is. The installation and setup of the AP should be a separate script that is usually only needed for pre-built images.
I tried a few times to edit the config.ini and flag install_wifiap=false, and again, installation was fine but upon first reboot after installation is complete, something happened in the network configuration and the raspi zero w wouldn’t connect. I tried a USB OTG → USB Ethernet adapter and it also wouldn’t connect to my network. The LEDs on the ethernet adapter and my network switch would light I could not connect to the raspi zero w through ethernet after the first reboot after installation is complete.
I then tried disabling all the emonSD items in config.ini and it works and i can reboot it as many times as I want! Great success! I’ll report back if anything changes.
Progress. There are a few lines in the emonsd.sh file relating to network. If it works with the wifiap disabled and and then the emonsd install disabled, try commenting out those lines.