Hi there,
I bought 4 neo coolcam power plugs woth energy monitoring:
https://nl.aliexpress.com/i/32966183521.html
Does somebody know how to configure them in esphome?
greets,
Sholofly
Hi there,
I bought 4 neo coolcam power plugs woth energy monitoring:
https://nl.aliexpress.com/i/32966183521.html
Does somebody know how to configure them in esphome?
greets,
Sholofly
I’m not sure you need esphome to integrate those into home assistant. Did you have an idea for connecting these to an ESP somehow?
I can using tasmota, but I really prefer esphome…
I have one on ESPhome, I have to look tonight after work for the code.
Energy monitoring is working only the LED is not working.
Ok,looking forward to it. I’m on tasmota, currently and the led is flashing in off and on mode…
did you flash them with tasmota? Which tools do you use, the old tuya convert, the new tuya convert, or?
This is the Esphome yaml code I used to flash the neo coolcam smart plug.
Everything is working except the LED, if I have some spare time I will figure it out.
substitutions:
plug_name: energy_plug1
# Higher value gives lower watt readout
current_res: "0.00221"
# Lower value gives lower voltage readout
voltage_div: "800"
esphome:
name: ${plug_name}
platform: ESP8266
board: esp8285
wifi:
ssid: 'secretssidpassword'
password: 'secretpassword'
# Enable logging
logger:
# Enable Web server
web_server:
port: 80
# Enable Home Assistant API
api:
password: 'secretapipassword'
ota:
password: 'secretotapassword'
time:
- platform: homeassistant
id: homeassistant_time
binary_sensor:
- platform: gpio
pin:
number: GPIO0
inverted: True
name: "${plug_name}_button"
switch:
- platform: gpio
name: "${plug_name}_Relay"
pin: GPIO14
restore_mode: ALWAYS_ON
#- platform: gpio
# name: "${plug_name}_LED_Blue"
# pin: GPIO1
# inverted: True
# restore_mode: ALWAYS_OFF
- platform: gpio
name: "${plug_name}_LED_Red"
pin: GPIO13
inverted: True
restore_mode: ALWAYS_OFF
sensor:
- platform: hlw8012
sel_pin:
number: GPIO12
inverted: True
cf_pin: GPIO04
cf1_pin: GPIO05
current_resistor: ${current_res}
voltage_divider: ${voltage_div}
current:
name: "${plug_name}_Amperage"
unit_of_measurement: A
voltage:
name: "${plug_name}_Voltage"
unit_of_measurement: V
power:
name: "${plug_name}_Wattage"
unit_of_measurement: W
id: "${plug_name}_Wattage"
change_mode_every: 8
update_interval: 10s
- platform: total_daily_energy
name: "${plug_name}_Total Daily Energy"
power_id: "${plug_name}_Wattage"
filters:
# Multiplication factor from W to kW is 0.001
- multiply: 0.001
unit_of_measurement: kWh
# Extra sensor to keep track of plug uptime
- platform: uptime
name: ${plug_name}_Uptime SensorPreformatted text
I used the Tuya-Convert 2.0 on a fresh raspberry. Works very well for me. Flashed 4 devices without any problem.
Thanks. Led and button aren’t working for me, but remote it seems to function very well.
For the first flash i had to remove the web_server part. It didn’t compile. Not tested, but it should work if you add it in a second flash.
For remote you intend the switch (on/off)?
Yes, and the sensors values are coming through. But it seems the button is not working neither does the button-LED.
Oh, the LED I do not care, but button could be important to have. Have you tried all the GPIO?
No I didn’t had the time yet. But i hope to find some documentation about this product
can you open it (without breaking it)?
No screws present, but it should be possible. It’s something i try to prevent, thats why i’m so happy with the Tuya-Convert 2.0…
Info about the plug from the Tuya Convert Wiki site:
GPIO0: Button1 (17), GPIO04: HWL8012 CF (133), GPIO05: HWLBL CF1 (132), GPIO12: HWLBL SELi(132), GPIO13: Led1i (56), GPIO14: Relay1 (21)
yes of course, just to see the pins to the ESP
but seems incorrect if sholoffy followed the code above
well, I stick withe Osram + , they cost 34 Euro 4 pieces (sometimes on offer in amazon) and with Zigbee less problems, at least for me.
Unfortunately no power metering and 10A
I think it is correct but there is no action attached to the button in the above code.
If you add something like:
on_press:
- switch.toggle: relay
to the binary_sensor it should work.