Hello.
We will deal with this aroma diffuser.
I have successfully loaded the tasmota firmware. There is no problem here.
However, the moment I started configuring the device and Tasmota, the problems began.
I set up the Tasmota template, and I found that there was an error in it.
{"NAME":"YX-088","GPIO":[0,2272,0,2304,0,0,0,0,0,0,0,0,0,0],"FLAG":0,"BASE":54,"CMND":"TuyaMCU 11,1|TuyaMCU 61,2|TuyaMCU 62,3|TuyaMCU|12,5|TuyaMCU 63,6|TuyaMCU 21,7|TuyaMCU 24,8|TuyaRGB 3|DimmerRange 1,255|TuyaEnumList 1,2|TuyaEnumList 2,2|TuyaEnumList 3,1"}`
There is one vertical character " | " In the command :
TuyaMCU|12,5
I fixed that and continued.
I put Rule1 in the tasmota console with my own specific /%topic%/
Rule1
on power1#state=0 do publish stat/%topic%/fanmode none endon
on tuyareceived#dptype5id9 do publish stat/%topic%/error %value% endon
on tuyareceived#dptype4id2==0 do publish stat/%topic%/fanmode medium endon
on tuyareceived#dptype4id2==1 do publish stat/%topic%/fanmode low endon
on tuyareceived#dptype4id2==2 do publish stat/%topic%/fanmode high endon
on tuyareceived#dptype4id3==0 do publish stat/%topic%/timer 2h timer endon
on tuyareceived#dptype4id3==1 do publish stat/%topic%/timer 4h timer endon
on tuyareceived#dptype4id3==2 do publish stat/%topic%/timer timer off endon
on tuyareceived#dptype4id6==0 do publish stat/%topic%/colormode solid endon
on tuyareceived#dptype4id6==1 do publish stat/%topic%/colormode cycle endon
on event#fanmode==-1 do power1 0 endon
on event#fanmode!=-1 do backlog power1 1; tuyaenum1 %value% endon
on event#solid do tuyaenum3 0 endon
on event#cycle do tuyaenum3 1 endon
I also noticed %value% in two lines
I left it unnoticed
Label web UI buttons:
Backlog WebButton1 Fan; WebButton2 Light; FriendlyName1 Diffuser Fan; FriendlyName2 Diffuser Light
OK, I thought.
But I started configuring the fan in Home Assistant and found other writing errors
fan:
- platform: mqtt
name: "Diffuser"
icon: "mdi:smoke"
state_topic: "stat/%topic%/RESULT"
state_value_template: "{% if value_json.POWER1 is defined %}{{ value_json.POWER1 }}{% endif%}"
command_topic: "cmnd/%topic%/POWER1"
preset_modes:
- "2h timer"
- "4h timer"
- "timer off"
preset_mode_state_topic: "stat/%topic%/timer"
preset_mode_command_topic: "cmnd/%topic%/tuyaenum2"
preset_mode_command_template: >-
{% if value == "2h timer" %}
{{ 0 }}
{% elif value == "4h timer" %}
{{ 1 }}
{% else %}
{{ 2 }}
{% endif %}
percentage_state_topic: "stat/%topic%/fanmode"
percentage_value_template: >-
{% if value == "low" %}
{{ 1 }}
{% elif value == "medium" %}
{{ 2 }}
{% elif value == "high" %}
{{ 3 }}
{% else %}
{{ 0 }}
{% endif %}
percentage_command_topic: "cmnd/%topic%/event"
percentage_command_template: >-
{% if value == 1 %}
{{ 'fanmode=1' }}
{% elif value == 2 %}
{{ 'fanmode=0' }}
{% elif value == 3 %}
{{ 'fanmode=2' }}
{% else %}
{{ 'fanmode=-1' }}
{% endif %}
speed_range_max: 3
availability_topic: "tele/%topic%/LWT"
payload_available: "Online"
payload_not_available: "Offline"
unique_id: "fan-diffuser"
select:
- platform: mqtt
name: "Diffuser Color Mode"
command_topic: "cmnd/%topic%/event"
state_topic: "stat/%topic%/colormode"
options:
- "solid"
- "cycle"
availability:
- payload_available: "Online"
payload_not_available: "Offline"
topic: "tele/%topic%/LWT"
unique_id: "select-livingroom-diffueser-color-mode"
binary_sensor:
- platform: mqtt
name: "Difuser Error"
state_topic: "stat/%topic%/error"
value_template: "{{ 'ON' if value != '0X00' else 'OFF' }}"
device_class: problem
availability_topic: "tele/%topic%/LWT"
payload_available: "Online"
payload_not_avail: "Offline"
unique_id: "binary-diffueser-error"
And here is my end.
Home Assistant hardly communicates with the diffuser.
In fact, it communicates, but insufficiently. I can choose any combination of preset and speed and send it to the diffuser, but the attributes of the fan entity never change.
I intended to use a fan card in the hunt, but it doesn’t work.
Please nice, would anyone be willing to check the configuration and compatibility for HA?
The author of the template does not communicate.
I’m sorry, and I ask for help again.
1 post - 1 participant
Read full topic