Monday, 23 September 2024

Tomzn/hiking DDS238-2 rs485 Energy Meter with ESPHome for Home Assistant

There seem to be several branded versions of this cheap 2 unit wide energy meter available online from the regular stores. I have a 'tomzn' branded on purchased several years ago and monitored the shed power in our last house. It's been relocated to the new place and is now in the switchboard in the shed^Wart studio in the garden.

Interfacing to home-asisstant

There are a pair of RS485 terminals and second pair provide pulse output. I got the sparky to run a short length of RS485 cable to a convenient location near a GPO for a USB power supply. I then have this connected to a cheap MAX485 module and on to an ESP8266 using the hardware serial port pins. I'm driving the max485 breakout with 3.3v so I don't need to worry about level shifters.

It's using a full-size Wemos D1 R2, purely because that's what I had on hand. As I'm using the serial port pins for connection to the RS485 converter, unplug before serial flashing. (OTA updates are fine)

My current software polls the meter every 5 seconds (note the RX/TX leds lit on the breakout, and the phone symbol on the meter LCD when this happens) https://github.com/Elwell/ESPHome-DDS238 has a very similar config to production

and you end up with this on the esphome and home assisstanr web interfaces
 



No comments:

Word of mouth Skye History

Many years ago we lived in the Old Manse in Waternish, Skye. If you look on the maps, you'll spot that unlike nearly all the other house...