Ruuvi Gateway logs to a remote syslog server - the DIY way

As some of you probably know already, the Ruuvi Gateway outputs some logs that are useful, especially in troubleshooting situations. However, in order to access these logs, you need to have the gateway connected to a computer or other usb host capable device in order to read the logs over USB.

I was having some random issues with the gateway that occur very rarely so that wasn’t really a feasible option for me, so I decided to explore alternative solutions, and came up with the idea of reading the logs over the serial using another device. In my case I decided to go with a ESP8266 based NodeMCU which I have plenty of, as they cost like 3€ a piece if you order a bunch of them.

My adventure to this project started on the Ruuvi matrix / telegram group (they’re bridged) where Lauri was kind enough to provide me some relatively easy soldering points for connections. Soldered some wires and tested with a simple usb to ttl dongle, and I was able to read the logs! I soldered wires for RX, TX, +3.3V and GND, although I don’t use TX for anything, at least not yet.

Then I got to write the code, which was basically 90% copypaste from my other random ESP8266 projects. I decided to implement both syslog and MQTT support because why not, and published the code here if you want to build something similar.

Final setup has the NodeMCU hanging on some wires, getting 3.3V directly from the gateway so no other cables or power supplies are needed. I might switch to a bare ESP8266 module some day and try to fit it inside the gateway enclosure, but we’ll see.

And finally I’m able to see Ruuvi Gateway logs on my Grafana Loki stack. (there are a lot of “easier” options than the full Loki stack, I don’t recommend setting up Loki if your only need is to have the gateway logs)

1 Like