Australia - Electrically Certified Hardware

I would start with the ID being 107 or 108. The true and false values are usually the on/off ones.

For more in-depth value determination I used the tuyapi python script to work out all the dps for my fan.

See my previous post for an example if the types of dp output.
Link

Edit:

Also check out the wiki on the localtuya GitHub. It has some info on how to work out the DPS
Link

1 Like

I agree, but I cant find a type I zigbee plug with energy monitoring?

1 Like

How about Z-Wave? More expensive but they work well (in my experience).

1 Like

I’ve just go the Centralite a couple of days ago. Easy to pair (zha, Conbee II) and has been working great so far. I still have not played with any automations and it’s only working based on it’s own thermostat. I am new in this stuff and I’ve just started to setup things in the past weeks. So, when I say is that the setup was easy and that this comes from a newbie! Also the price is really good at only 40 usd in Amazon.

My main motivation to get into home automation is to improve the temperature across the different rooms in the house. I am already testing Aqara sensors (also, cheap and easy) and I am now evaluating options for smart vents and smart dumpers (in places where I have access) to control the hot or cold air flow to each room. Let’s see when the “easy” trend is interrupted! :slight_smile:

2 Likes

@tinglis1, I’ve implemented localtuya, thanks for the suggestion. Wasn’t able to get the speeds, nor the light controls other than power to work, but I’ve made a fan template that just calls localtuya.set_dp and it’s working great for the fan. I haven’t gotten around to to doing the light yet but at least I know it will work with a template now.

Glad you had some success. The localtuya project definitely has some development to do but it is good that there is an option that doesn’t involve the cloud or reflashing.

Just in case it helps I have added a screenshot of the config I use for my fan.


I modified the fan.py to get fan speed of 6 for high speed.

I’m not smart enough to do that :laughing:

I intend on submitting my changes when I get some time so others can benefit.
Too busy with a newborn baby at the moment to do much more than post on here.

1 Like

Hey Shane, sorry to hear your Brilliant smart plug couldn’t be flashed.

Just to encourage others, I bought two more of these from Officeworks Glen Waverly VIC today and was able to flash them successfully using Tuya-Convert on a Raspberry Pi so there are still devices on the older firmware out there for those brave enough to try.

Unfortunately it looks like the packaging is identical to Shane’s so there’s no way to know before you buy. I assume if you’re careful with the packaging you could return these if they couldn’t be flashed though.

If anyone is setting these up with ESPHome, I got fairly accurate power monitoring calibrated with the values below and mine all seem to take the same calibration values so it might save someone some time.

current_resistor: 0.00103
voltage_divider: 2160

I’ll post the whole .yaml contents if it’s useful to anyone starting out, I couldn’t find an exact reference so had to piece a few different configs together.

2 Likes

:face_vomiting:

Reading that, I was thinking… Am I just an idiot???

The answer to that question is… Yes I am HAHAHA

I honestly don’t know what I was doing wrong. I think maybe I didn’t have the Pi close enough, or did not have the plug in the right pairing mode.

But, more then anything else, so sorry guys HAHA. I honestly thought it wasn’t working.

Well that’s about 10 hours of stuffing around that Im never getting back :frowning:

Anyway, these two are on Tasmota and Im off to OW to get a few more LOL

Kill me HAHA

1 Like

Thanks for reporting back. Looks like they are still the go then. :+1:

That would be useful if you don’t mind.

1 Like

Would love to this in context, with the rest of the .yaml?

Also, just trying to move them over the ESPhome and getting;

Upload Failed

Upload buffer miscompare

How did you get around that?

EDIT!

If anyone runs into this, its because I upgraded to the full firmware before I went to ESPhome. Just leave it on the minimal, and you will be fine :slight_smile:

Good job figuring it out! Also good to know there aren’t unflashable versions on sale (yet).

Here’s my current yaml file to get switching with energy monitoring in Home Assistant via ESPHome. It’s based on the Gosund SP1 config in the ESPHome cookbook here, but using the pins from the Tasmota template here.

I’m no expert so use this at your own risk. That said it’s working fine for me on four devices and as mentioned, I’ve tweaked the energy monitoring settings to match an independent power monitor fairly closely.

For newcomers; my first two plugs I flashed with the tasmota-lite firmware bundled with Tuya-convert before compiling the below ESPHome yaml in Home Assistant then flashing it to the device from the Tasmota page on the device’s IP address. The next two plugs I skipped the tasmota step and flashed the compiled ESPHome firmware directly from tuya-convert which worked fine. I’d recommend the second approach as there’s no need to involve Tasmota.

I noticed the ESPHome implementation makes switching the device almost instant, where Tasmota had a noticeable delay. I also don’t see the need to involve an MQTT broker as another point of failure however that’s just personal preference.

ESPHome yaml configuration for an Australian Brilliant Smart Plug with energy monitoring (BL20925)

esphome:
  # Make sure this name is unique for each device
  name: monitoring-plug-1
  platform: ESP8266
  board: esp01_1m

wifi:
  ssid: "YourWifiNameHere"
  password: "YourWifiPasswordHere"

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Monitoring-Plug-1"
    password: "StrongPasswordHere"

captive_portal:

# Enable logging
logger:

# Enable Home Assistant API
api:
  # Optional password for adding this device to Home Assistant
  password: "StrongPasswordHere"

ota:
  # Optional password for flashing the device over the air from ESPHome
  password: "StrongPasswordHere"

binary_sensor:
  - platform: gpio
    pin:
      number: 3
      mode: INPUT_PULLUP
      inverted: true
  # Make sure this name is unique for each device
    name: "Plug 1 Power Button"
    on_press:
      - switch.toggle: relay

switch:
  - platform: gpio
    id: led
    pin:
      number: GPIO13
      inverted: true

  - platform: gpio

  # Make sure this name is unique for each device.
  # This is the entity you'll add to a Home Assistant dashboard to control the switch
    name: "Plug 1"
    pin: GPIO14
    id: relay
      
sensor:
  - platform: hlw8012
    sel_pin:
      number: GPIO12
      inverted: True
    cf_pin: GPIO04
    cf1_pin: GPIO05

  # These values can be tweaked to calibrate the energy monitoring.
  # Start with the voltage divider to get the voltage right, then adjust the current resistor to adjust the watts as this relies on the voltage being right.
    current_resistor: 0.00103
    voltage_divider: 2160
    
    current:
      # Make sure this name is unique for each device.
      name: "Plug 1 current"
      unit_of_measurement: A
      
    voltage:
      # Make sure this name is unique for each device.
      name: "Plug 1 Voltage"
      unit_of_measurement: V
      
    power:
      # Make sure this name is unique for each device.
      name: "Plug 1 Wattage"
      unit_of_measurement: W
      id: "energy_temp_Wattage"
    
    # Total energy use may not be very useful as it will be reset if the device looses power, monitoring may be better done in Home Assistant. If needed, uncomment the following lines.
    ##energy:
    # Make sure this name is unique for each device.
    ##  name: "Plug 1 Energy"
    ##  unit_of_measurement: Wh
    
    # How often the device will report energy usage stats to Home Assistant
    update_interval: 60s

    # The initial report mode - useful if not auto-switching between report types, see below.
    initial_mode: CURRENT

    # The hlw8012 energy monitor can only report voltage and watts or amps and watts at a time. This setting will switch between them. If you want to stay on one report type, set the 'initial mode' above, then set 'change mode every' to 4294967295.
    change_mode_every: 8
1 Like

All’s well that ends well I guess, but still annoyed that I wasted so much time on something thats so easy LOL

Oh well, thanks for giving it another go and making me try it again :slight_smile:

I ended up using this as the template in the end.

Seems to be working well.

Is anyone using Node Red to run automations off of the power draw… eg have alexa notify you when the washings finished?

Please upload to https://www.esphome-devices.com/

Good idea nick, although it looks like there’s a better version on esphome-devices already that Shane found (don’t know how I missed this!).

Could have been worse, you could have missed that they can still be flashed HAHA

Has anyone see this? It wont show the correct voltage, other one works fine. I was thinking about deleting and readding it… But no idea if that would actually make a difference.

Any ideas?

Thanks guys

image

EDIT,

Was a faulty plug swapped it out

Sorry if this has been discussed but I couldn’t find it in the search.

Does anyone know about a dimmer switch with 4 buttons? I was hoping for something like https://www.bunnings.co.nz/deta-grid-connect-smart-quad-gang-touch-light-switch_p0161015 but with dimmers instead of just buttons.

I was also wondering if anyone knew of any pet-sensitive motion detectors?

Cheers

I have seen the Xiaomi plugs with power monitoring. But I don’t know if they’re certified (or even need certification). I have a couple and they work quite well. Trying to get away from the Xiaomi ZigBee stuff though

Anyone know of any others?