Dies ist eine alte Version des Dokuments!


Tasmota

Achtung:

Bei Tasmota ist das so, dass der jeweilige Schalter oder Taster (Switch/Button) IMMER das jeweilige Relais schaltet. z.B. Wenn Switch 1 ODER Button1 betätigt wird, dann schaltet Relais1! Bei Switch2 das 2. Relai (wenn vorhanden). Das kann nerven und einen in den Wahnsinn treiben, wenn man das nicht weiß. Abschalten lässt sich das mit:

SetOption114 1

By default a switch toggles the corresponding power state (e.g., Switch1 controls Power1). Every time the switch gets flipped the power state of the relay toggles.

Damit zusammenhängend:

Ein Schalter wirs gar nicht via MQTT gemeldet (wenn nicht detached mit SetOption114 1). Wenn detached, gibt es eine 'RESULT = {„Switch1“:{„Action“:„OFF“}}'. Das versteht ha aber nicht und der Sensor wird erst geupdated, wenn das nächste SENSOR kommt (zeitgesteuert).Es dauert oft Minuten, bis der Schalter geupdated wird.

Daher: 1)

With command

SwitchMode<x> 15

you can decouple Switch<x> from its power output and it will instead send MQTT messages in the following format:

MQT: tele/tasmota/SENSOR = {"Time":"2021-01-01T00:00:00","Switch1":"OFF"}
MQT: tele/tasmota/SENSOR = {"Time":"2021-01-01T00:00:01","Switch1":"ON"}
You can globally change the status text with StateText command.
You can change the default "Switch1" text using SwitchText<x> command. For example: SwitchText1 Garage_Door_State

When Setoption114 1 is used together with SwitchMode<x> 15, Tasmota Integration in Home Assistant will create a binary sensor in HA using the Default text „String1“ or the text mentioned in the SwitchText command.

Dann erkennt ha die Änderungen am Schalter sofort.

Turn on Auto-discovery for Home Automation

Go to your sonoff console and enter

SetOption19 1

This turns on auto discover.

Then in HA go to Configuration > Integrations > MQTT .

I had a similar experience with the Teckin plug. Autodiscovery wouldn’t work. I finally did this:

  • in tasmota: configuration > others > disable MQTT
  • switch will reboot
  • re-enable MQTT from configuration > others
  • go to console and type the discovery cmd: “SetOption19 1”
  • it should show now in homeassistant under the MQTT integration

MQTT Discovery REMOVED~ Home Assistant MQTT Discovery is removed from all builds of Tasmota and development of this feature is halted! 2)

Tasmota-Version muss >9 sein!

Eigene Geräte (Schalter) an Tasmota

https://tasmota.github.io/docs/Expanding-Tasmota

If you can avoid it, don't use GPIOs: 0, 1, 2, 6-11, 15 and 16. That leaves 4, 5, 12, 13, 14 as GPIOs without any constraints. 3 being RX is also good to avoid (PWM is not working on this GPIO).

Garage

  • GND (Schwarz)
  • GPIO 02
  • GPIO 12
  • GPIO 13

Pull-UP 10k

Geräte

Sonoff RF Bridge

https://tasmota.github.io/docs/devices/Sonoff-RF-Bridge-433/

Kellerlicht aus & an:

20:47:03.567 MQT: tele/rf_tasmota_B29E24/RESULT = {"Time":"2023-08-19T20:47:03","RfReceived":{"Sync":10380,"Low":270,"High":950,"Data":"504014","RfKey":"None"}}
20:47:07.085 MQT: tele/rf_tasmota_B29E24/RESULT = {"Time":"2023-08-19T20:47:07","RfReceived":{"Sync":10390,"Low":270,"High":940,"Data":"504015","RfKey":"None"}}
20:58:32.825 CMD: RfRaw AAB155
20:58:32.832 MQT: stat/rf_tasmota_B29E24/RESULT = {"RfRaw":"ON"}
20:58:32.854 MQT: tele/rf_tasmota_B29E24/RESULT = {"Time":"2023-08-19T20:58:32","RfRaw":{"Data":"AAA055"}}
20:58:38.138 MQT: tele/rf_tasmota_B29E24/RESULT = {"Time":"2023-08-19T20:58:38","RfRaw":{"Data":"AA B1 03 014A 03E8 2878 28190819081818181819081818181818181818190819081818 55"}}
20:58:40.601 MQT: tele/rf_tasmota_B29E24/RESULT = {"Time":"2023-08-19T20:58:40","RfRaw":{"Data":"AA B1 03 0154 03DE 2896 28190819081818181819081818181818181818190819081908 55"}}

Nach Konvertierung:

Aus: AA B0 21 03 08 014A 03E8 2878 28190819081818181819081818181818181818190819081818 55

An: AA B0 21 03 08 0154 03DE 2896 28190819081818181819081818181818181818190819081908 55

Topic:

cmnd/rf_tasmota_B29E24/RFsend

Funktioniert: an/aus

cmnd/rf_tasmota_B29E24/RFCode

Payload:
#504014 (aus)
#504015 (an)
 
Nach oben
tasmota.1708299189.txt.gz · Zuletzt geändert: 2024/02/29 13:35 (Externe Bearbeitung)
chimeric.de = chi`s home Creative Commons License Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0
DFmW2CEce3htPL1uNQuHUVu4Tk6WXigFQp   Dogecoin Donations Accepted Here    DFmW2CEce3htPL1uNQuHUVu4Tk6WXigFQp  DFmW2CEce3htPL1uNQuHUVu4Tk6WXigFQp