Hi OSD, thanks for your input.
Those are the 4 relays on IO-MCU. I buzzed out the circuit and found that I had an open circuit on the 12v line to the relays.
Furthermore 2 of the relays indicator LEDs were illuminating, 2 were not.
I suspect, when I first juiced up the circuit on this MCU, the 2 relays fired, but I'd made the trace too thin for the required current. I wired up some jumper wire on the reverse of the PCB and the 2 relays started working.
The 2 that remain inoperable?
https://forum.arduino.cc/t/using-pins-a6-a7-on-pro-mini-compatible/118050
A6 and A7 can only be analogue inputs, cannot be digitally written to..... - so this part of my PCB is now redundant.
However, all in all, some good fault finding, found the two issues, and I'm now going away to re-think my PCB trace widths and reading the datasheets more accurately
Thanks
Don't ask me why, but now it works. I changed nothing! Went to my girl over the weekend, coming back, the node was registred. Maybe a jammer went away?
Hm, maybe the problem is that your rPI has a short interruption in the WIFI connection, the MQTT TCP connection is interrupted and does not autostart again. Maybe there is something in the logs. Maybe you can find something about reconnects in one of these:
journalctl --unit=systemd-networkd
journalctl --unit=wpa_supplicant
You could try to run wpa_cli in daemon mode to react to disconnects and connects. Create a script like this:
#!/bin/bash
case "$2" in
CONNECTED)
<your command to start the gateway>;
;;
DISCONNECTED)
<your command to stop the gateway>;
;;
esac
then, start wpa_cli in deamon mode:
wpa_cli -a /path/to/your/script #use sudo if your gateway commands need sudo
If that helps, you could create a service from this command.
Regards, Edi
@Mizar03 sorry for the late response. getStream() only works for firmware transfers. I'd suggest getString(), this should also work for all types of payloads, as they are normaly ASCII and not binary data.