mirror of https://github.com/arendst/Tasmota.git
Updated Rules (markdown)
parent
0deeeb65ea
commit
9182aa2f23
10
Rules.md
10
Rules.md
|
@ -366,6 +366,16 @@ on SI7021#temperature>%var1% do backlog var1 %value%; publish stat/sonoff/temp %
|
|||
on SI7021#temperature<%var2% do backlog var2 %value%; publish stat/sonoff/temp %value%; var1 %value%; add1 2; sub2 2 endon
|
||||
```
|
||||
|
||||
* Example: Adjust the value of a sensor and send it by MQTT
|
||||
|
||||
This example adds 2 degrees to the measured temperature and then sends that value to a MQTT topic.
|
||||
|
||||
```
|
||||
rule
|
||||
on tele-SI7021#temperature do backlog var1 %value%; add1 2; event sendtemp endon
|
||||
on event#sendtemp do publish stat/sonoff/temp %var1% endon
|
||||
```
|
||||
|
||||
------------------------------------------------------------------------------
|
||||
|
||||
#### 9. Simple Thermostat Example
|
||||
|
|
Loading…
Reference in New Issue