Australia - Electrically Certified Hardware

@nickrout You had better Tuya-convert the hell outta that fan and send the Tasmota config.

I need 2 myself, those Arlec ones on the NZ site would be perfect. I’m it won’t be long until they arrive here. I can wait a month.

I use a normal Arlec fan with RF remote currently in the bedroom and use OMG to change fan speed, on/off via scripts and Alexa. Works fine, but a Tasmota fan would make life easier.

I just bought 3 and will try them on the weekend :slight_smile:

Aldi Hornsby (NSW) now has 4 Garden Light Kits left for $70 each.

@bavotto do you have a tasmota template for the aldi powerboard

Sorry, I was having issues with my Tasmota setup, and have moved everything across to ESPHome now, so I can’t give you a template string that will work. I also no longer have the status LED work for the whole board (the individual socket LEDs are linked), but I am not as fussed about this since it is just on if any of the sockets are on…

That said, the three sockets are operated by GPIO 3, 4 and 5 and from memory Relay1, Relay2, Relay3 settings.

switch:
  - platform: gpio
    id: red_led
    pin:
      number: GPIO01
      inverted: true

  - platform: gpio
    name: "Fire Fan"
    pin: GPIO5
    id: relay1
  - platform: gpio
    name: "Living Room Lamp"
    pin: GPIO4
    id: relay2
  - platform: gpio
    name: "Spare Living Switch"
    pin: GPIO13
    id: relay3

That is my ESPHome config, which is essentially a copy of a Brilliant switch setting from ESPHome, with a couple of extra relays. I will work on it some more over the weekend and see if I can get it all properly setup and a proper config for other people.

@sparkydave and others with the brilliant fan switches.

Ive managed to get a similar one from SRL-tech working (https://srltech.com.au/portfolio_page/fan-series/), Id be fairly certain the Brilliant one is the same, I might try and flash one of mine later to confirm.

In any case, you will need to be running Tasmota 7.0.0.1 or later, I flashed latest dev myself.

Configure module as a TuyaMCU, the dimmer and light functionality should be the same as the configs posted above but the fan speed is where it gets a little more tricky.

Go to console and type weblog 4 and then view the output after hitting buttons on the RF remote, it should look something like

11:50:26 {"TuyaReceived":{"Data":"55AA00070005020400010012","Cmnd":7,"CmndData":"0204000100","DpId":2,"DpIdType":4,"DpIdData":"00"}}
11:49:27 {"TuyaReceived":{"Data":"55AA00070005020400010113","Cmnd":7,"CmndData":"0204000101","DpId":2,"DpIdType":4,"DpIdData":"01"}}
11:49:28 {"TuyaReceived":{"Data":"55AA00070005020400010214","Cmnd":7,"CmndData":"0204000102","DpId":2,"DpIdType":4,"DpIdData":"02"}}
11:49:29 {"TuyaReceived":{"Data":"55AA00070005020400010315","Cmnd":7,"CmndData":"0204000103","DpId":2,"DpIdType":4,"DpIdData":"03"}}
11:49:29 {"TuyaReceived":{"Data":"55AA00070005020400010416","Cmnd":7,"CmndData":"0204000104","DpId":2,"DpIdType":4,"DpIdData":"04"}}
11:49:30 {"TuyaReceived":{"Data":"55AA00070005020400010517","Cmnd":7,"CmndData":"0204000105","DpId":2,"DpIdType":4,"DpIdData":"05"}}

This was the result of me going from the lowest to highest fan speed setting (this switch supports 6 speeds).

In the lastest development version they have added a TuyaSend command and TuyaReceived event which you do use in rules.

You will want a rule something like this, where you replace the Data with the values you received in console and potentially customise the MQTT topic you want to post the result to

Rule1 on TuyaReceived#Data=55AA00070005020400010012 DO publish2 stat/Event/speed 1 endon on TuyaReceived#Data=55AA00070005020400010113 DO publish2 stat/Event/speed 2 endon on TuyaReceived#Data=55AA00070005020400010214 DO publish2 stat/Event/speed 3 endon on TuyaReceived#Data=55AA00070005020400010315 DO publish2 stat/Event/speed 4 endon on TuyaReceived#Data=55AA00070005020400010416 DO publish2 stat/Event/speed 5 endon on TuyaReceived#Data=55AA00070005020400010517 DO publish2 stat/Event/speed 6 endon

This will only post the updated status to the topic we still need to have a way to set the current speed. This is achieved by
Rule2 on Event#1 DO TuyaSend4 2, 0 endon on Event#2 DO TuyaSend4 2, 1 endon on Event#3 DO TuyaSend4 2, 22 endon on Event#4 DO TuyaSend4 2, 3 endon on Event#5 DO TuyaSend4 2, 4 endon on Event#6 DO TuyaSend4 2, 5 endon

This will result in sending the correct command to the TuyaMCU when a message is posted to cmnd/sonoff/Event with the corresponding fan speed of 1-6.

To determine the correct values look again at the console output
{"Data":"55AA00070005020400010517","Cmnd":7,"CmndData":"0204000105","DpId":2,"DpIdType":4,"DpIdData":"05"}

DpId is 2
Enum value is 5
DpIdType 4 is enum so use TuyaSend4 to send an enum

Dont forget to enable the rules after setting them with
Rule1 ON
and
Rule2 ON

Hope this helps.

5 Likes

@sparkydave Ok I think i have the brilliant fan switch cracked!

Use the following TuyaMCU settings

9 => Light Switch
10 => Dimmer
12 => Global fan on/off

There is an additional dpid #2 which never seems to have its value changed in my testing and didnt seem to do anything

Dpid 3 is used for the fan speed, when changing the fan speed the Dpid 12 must be on or it will have no effect.

{"TuyaMCU":[{"fnId":11,"dpId":9},{"fnId":21,"dpId":10},{"fnId":12,"dpId":1}]}

Update MQTT with current fan status
Rule1 on TuyaReceived#Data=55AA03070005030400010016 DO publish2 stat/Event/speed 1 endon on TuyaReceived#Data=55AA03070005030400010117 DO publish2 stat/Event/speed 2 endon on TuyaReceived#Data=55AA03070005030400010218 DO publish2 stat/Event/speed 3 endon

Set fan speed based on MQTT message, note this will also turn the fan on when setting the speed
Rule2 on Event#1 DO Backlog Power2 1; TuyaSend4 3, 0 endon on Event#2 DO Backlog Power2 1; TuyaSend4 3, 1 endon on Event#3 DO Backlog Power2 1; TuyaSend4 3, 2 endon

I dont have a fan actually connected to test this and have been using a cheap LED bulb so its hard to confirm but looking at the response from the MCU I’m pretty sure its correct.

4 Likes

Hi guys,

The latest smart switches are starting to look good and are at a price point worth considering. Just wondering if there are any that also have a dimmer function to them? All I’ve managed to see so far is basic on/off.

Thanks!

The brilliant fan one does support dimming, otherwise they also have an inline dimmer you can add

Awesome work! All this Tasmota stuff is new to me and I’m currently away at work so can’t do any testing but it looks like you have made great progress on it. It would be great to see if it all works and also if there is a way to convert your findings to ESPhome code

Thanks. That Brilliant in line dimmer seems a bit limiting. If I’m not mistaken it can only be controlled via wifi? In my mind that would just be the equivalent of using a smart bulb in that the physical switch would need to be on 100% of the time and control could only come from Home Assistant/mobile apps.

I’ve been toying with the idea of using smart globes but mounting some kind of wireless switch over the top of the physical switches. Eg Ikea Tradfri remote or similar.

What’s turning me away from this however, is that if the system was down then the lights also would not work. Compared to if I had a smart switch with ESPhome I could have some of the smarts built into the switch itself and still have manual control via the switch.

I’ve been grappling with this as well. I think the approach I’ll use is to replace my existing light switches with some smart wall switches running Tasmota, and then configure the switches so that they send an MQTT command to turn on the smart globes. I’ll also set it up so that a long-press on the wall switch actually triggers the relay in the wall switch and cuts the power to the smart globe, in case the MQTT server goes down.

I’ve done something similar with the button on a smart plug, to control another smart plug attached to a bathroom fan via MQTT: Update to smart plug rules for controlling bathroom fans manually

In some locations I have smart globes and leave the light switch on at all times. I then have Xiaomi wireless buttons mounted over the switch which I use to control the smart globe via various automations for ON/OFF/AUTO settings. If HA was to fail, I can simply use the light switch and the globes are set to turn ON after a power cycle (ie: if HA is down I can turn the switch OFF, then ON and the globe will come ON). My plan at some point is to hard-wire the switch ON in the wall and mount the Xiaomi button inside / behind the wall plate such that a momentary button on the plate switches the Xiaomi button. Obviously this would prevent me power cycling the globe easily…but…

Honestly this hasn’t been an issue for a long time now as HA has been really stable for me since…
a) I got a lot better at coding YAML without errors
b) I switched to a NUC
c) The config checker is / seems a lot better these days and I always do a check config before restarting HA

1 Like

This is the smart house lighting dilemma, combining dumb switches, “customer” expectations, the possibility of system outage/backup control. You can’t have everything.

However it is wrong to say that you cannot control a wifi dimmer other than by an app or the home assistant gui. A rotary encoder can do it. And they have a momentary switch too.

This is what I do and it is great, until someone (won’t name you, lets just call you daughter’s boyfriend) fiddles with the switch trying to do some last century manual thing…

:rofl::rofl::rofl:

Thanks guys.

I think the best plan for me will be to mount a wireless switch over the top of the physical switch. Maybe 3D print a magnetic mount/cover or something.

I’d like to retrofit some older lamps with smarts. Yes, I could use smart bulbs, but the problem is the existing switches will physically power off the globe, making it useless.

Instead, I am looking for something that will allow me to make the power button a ‘soft toggle’ rather than a hard power switch.

Some solutions exist like this: https://www.amazon.com/Pack-iDevices-Socket-Enabled-Required/dp/B01M72SCXO

Does anyone know of a product that’ll either allow me to convert, or re-wire lamps?

TIA.

Any smart switch. Just bypass the load and use detection of a switch press/toggle in HA to change the smart light state.

The only way I can think of would be a DIY approach… Nothing off-the-shelf

Thanks for the suggestion, but this will not pass with wife’s approval. It needs to have an integrated switch/button like a normal lamp.