LoraWAN weather station

I’ve just received a nice new ‘headless’ weather station from China, and I am engaged in connecting to its RS485 feed and understanding the protocol. They supplied a RS485-UART USB stick with it, and after playing around with some containerised NodeRED flows which couldn’t read the USB finally just used PySerial and have started dumping the data. Although it is advertised with the tag line “we will supply the communications protocol” this wasn’t forthcoming so I just dumped the bits down on the screen and have started reading them. Apparently they are a Fine Offset type of station and equivalent to the WH2950 type, without the monitor or network link. It’s all down to me!


The bytes look like this:

24 B3 7A 62 61 46 00 00 00 00 00 01 00 00 00 48 A3 $.zbaF………H.
24 B3 7A 62 61 46 00 00 00 00 00 00 00 00 00 D3 2D $.zbaF……….-
24 B3 7A 62 61 46 00 00 00 00 00 02 00 00 00 D4 30 $.zbaF……….0
24 B3 7A 62 61 46 00 00 00 00 00 00 00 00 00 D3 2D $.zbaF……….-

… which is fun. I quickly worked out that the standard size was 17 bytes, now I have run it through a hex dumper and started eye-balling the bytes. I may need to spin the anemometer to generate events to get readings, but this looks good.

I’ve also now connected it via a LoRaWAN link and have the data flowing back to me via MQTT. I need to compress the data as well as recording and averaging the readings, since the standard interval time of 16 seconds would exceed the fair-use policy of The Things Network. Meteorological masts (or ‘metmasts’) conform to an IEC standard, but mine can be much less rigorous than that: I’ve decided to take ten measurements and transmit the min/avg/max of them every 160 seconds. Given enough compression I think I can get the seven measurements (wind speed and direction, temperature, humidity, UV, lux, rainfall) into less than 10 bytes.

The git repo is up on BitBucket.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s