lmatula / ha_chint_pm

homeassistant Chint power meter integration
Creative Commons Zero v1.0 Universal
13 stars 7 forks source link

Unclear how to set up Connection #6

Closed rolandsteinmeyer closed 9 months ago

rolandsteinmeyer commented 1 year ago

I want to connect to a DTSU666-H via a modbus tcp adapter efin ee11. How to set this up ? After adding this repo via HACS I tried to set up a new integration. HA asks for model DTSU666-H (Huawei) or DTSU666 (Normal). Have chosen Huawei. Next config page asks for serial or network. Have chosen network. Next page wants 3 entries. No default for 1st entry. I expect to enter IP adress of Modusbus Adapter here. Second entry probably TCP Port (default: 502) and third modbus adress of DTSU666 (default: 11). But IP address is not accepted for 1st field, giving me just "unknown".

cesarvoggithub commented 1 year ago

Have you configured modbus in configuration.yaml ?

Example taken from my own working setup:

modbus:
  name: "elfin_ew11"
  type: rtuovertcp 
  host: <ip-address of your RS485 to ETH adapter, in my case an elfin_ew11A>
  port: <socket port set in your RS485 to ETH adapter for tcp communication>
  close_comm_on_error: false
  delay: 10
  timeout: 10

Once the above is done and HA has restarted, you can go to the devices screen and add the CHINT integration. Then select your smart meter type (Huawei or Normal), network and finally, in the next screen add the same ip-address and socket port you used for your RS485 to ETH adapter, exactly as set above in configuration.yaml.

You may need to experiment with different types (tcp, rtuovertcp, udp), depending on your setup. The above worked perfectly fine with an Elfin EW11A adapter I got from AliExpress.

As always, YMMV. Good luck