esphome / feature-requests

ESPHome Feature Request Tracker
https://esphome.io/
420 stars 26 forks source link

Support for HLW8112 #2590

Open kostasdimos opened 9 months ago

kostasdimos commented 9 months ago

Describe the problem you have/What new integration you would like I have purchased a power sensor with two clamps. The model on the box is described as PJ-1103 A. On my search it uses the cb2s as wifi module and the hlw8112 power sensor chip. I have a plan to replace the cb2s with esp chip and to flash with esp home. But as I can see there is not yaml configuration for the hlw8112 chip.

poldim commented 8 months ago

I'm in the same boat. My device is labeled PJ1203A V8 on the PCB. There are only 5 pins attaching the CB2S to the main PCB. So it should be easy to swap in an ESP.

image image image

mpissarello commented 6 months ago

Hi all! Same here with my power meter Earu PC311-W-TY.

The WiFi chip is a WBR3 (W701-VA2-CG): https://developer.tuya.com/en/docs/iot/wbr3-module-datasheet?id=K9dujs2k5nriy FWIU this chip is not supported ATM, but it's swappable with an ESP-12S (of F)

The energy measure chip is HLW8112, and it's connected via SPI: https://redmine.laas.fr/attachments/download/3444/DS_HLW8110_HLW8112_EN_Rev1.01%20.pdf

I found this Git with a preliminary driver for the HLW8112, may be ported to ESPHome? https://github.com/MahdaSystem/HLW811x

01 02 03 04

CladZo91 commented 2 months ago

Here another generic Aliexpress Tuya Meter that has the HLW8112.

PCB version is PM01_A002 and datecode is 20240705.

The WiFi Chip is Tuya - CBU which is supported in ESPHome.

IMG_20240827_044834_253 20240827_045423 IMG_20240827_044929_495 20240827_051137

I had some spare time and traced the connections between the CBU and HLW8112: image

I dumped the firmware with ltchiptool: meter1.uf2.zip

nschimme commented 2 months ago

@Hossein-M98 has created a driver here: https://github.com/MahdaSystem/HLW811x

nschimme commented 2 months ago

@Hossein-M98 would you have any interest integrating your driver into the esphome ecosystem?

Hossein-M98 commented 2 months ago

@Hossein-M98 has created a driver here: https://github.com/MahdaSystem/HLW811x

I am so sorry. The driver has not been completed. I am working on other projects and do not have time to complete this driver. The HLW811x has bad documentation and took several days from me. So we decided to drop it for a while and work on other important projects.

@Hossein-M98 would you have any interest integrating your driver into the esphome ecosystem?

I do not have any idea about esphome :)