MQTT2+Shelly: erste Konfiguration und template-Entwicklung

Begonnen von miggun, 03 Dezember 2018, 21:05:34

Vorheriges Thema - Nächstes Thema

Beta-User

 :) Jetzt wird es heller.
(Details spare ich mir erst mal)

Funktioniert das mit "GetConfig"? Dann könnte man per userReadings auf das "config_changed" reagieren und den gesetzten Wert abholen...
Server: HP-elitedesk@Debian 12, aktuelles FHEM@ConfigDB | CUL_HM (VCCU) | MQTT2: MiLight@ESP-GW, BT@OpenMQTTGw | MySensors: seriell, v.a. 2.3.1@RS485 | ZWave | ZigBee@deCONZ | SIGNALduino | MapleCUN | RHASSPY
svn: u.a MySensors, Weekday-&RandomTimer, Twilight,  div. attrTemplate-files

draddy

hast ja gesagt, screenshots sind genau deins gell! xD


also hab getList gesetzt

shellyplus1-441793a3b110/rpc {"id": 1, "method": "Switch.GetConfig", "params": {"id": 0}}


mehr passiert nicht und fhem meldet eben timeout (siehe screenshot)
OMV5@AsRock j3455 8GB RAM
FHEM@Docker, Shelly "starter pack" 4x PlugS, 2x Bulb Duo RGB, Shelly 2.5, Shelly Plus 1, DoorBird 2103V

draddy

#827
!

shellyplus1-441793a3b110/rpc {"id": 1, "src":"fhem2shelly", "method": "Switch.GetConfig", "params": {"id": 0}}
fhem2shelly/rpc {"id":1,"src":"shellyplus1-441793a3b110","dst":"fhem2shelly","result":{"id":0, "name":null,"in_mode":"flip","initial_state":"restore_last", "auto_on":false, "auto_on_delay":60.00, "auto_off":false, "auto_off_delay": 60.00}}


hab geblickt was du gestern meintest mit "src" rein knoddeln - fhem webUI gibt immer noch timeout, ABER reading kommt wenigstens im m_sub timeout denke ich, kommt davon das fhem per default mit dem json nix anfängt?
OMV5@AsRock j3455 8GB RAM
FHEM@Docker, Shelly "starter pack" 4x PlugS, 2x Bulb Duo RGB, Shelly 2.5, Shelly Plus 1, DoorBird 2103V

Beta-User

...noch heller...

Über den timeout kannst du dich noch lange beklagen, das fixen wir ggf. zum Schluss, bis dahin ist das (wie bereits erwähnt) völlig normal ;D !

Dann versuchen wir mal, ihm eine andere src unterzuschieben:shellyplus1-441793a3b110/rpc {"id": 1,"src":"shellyplus1-441793a3b110", "method": "Switch.GetConfig", "params": {"id": 0}}
Das hat den Hintergrund: Schaltanweisungen wollen wir nicht auf dem "habe die Anweisung erhalten"-Weg auswerten, sondern die "es wurde geschaltet"-Info verwenden, die zusätzlich da ist. Daher wird der "fhem"-Topic ins digitale Nirvana geschickt. Da landen aber grade auch die Infos aus der Anfrage... Falls er die "eigene" ID nicht will: "request2shelly"
Server: HP-elitedesk@Debian 12, aktuelles FHEM@ConfigDB | CUL_HM (VCCU) | MQTT2: MiLight@ESP-GW, BT@OpenMQTTGw | MySensors: seriell, v.a. 2.3.1@RS485 | ZWave | ZigBee@deCONZ | SIGNALduino | MapleCUN | RHASSPY
svn: u.a MySensors, Weekday-&RandomTimer, Twilight,  div. attrTemplate-files

draddy

getList:

in_mode:noArg in_mode shellyplus1-441793a3b110/rpc {"id": 1,"src":"shellyplus1-441793a3b110", "method": "Switch.GetConfig", "params": {"id": 0}}


m_sub

shellyplus1-441793a3b110/rpc {"id": 1,"src":"shellyplus1-441793a3b110", "method": "Switch.GetConfig", "params": {"id": 0}}
shellyplus1-441793a3b110/rpc {"id":1,"src":"shellyplus1-441793a3b110","dst":"shellyplus1-441793a3b110","result":{"id":0, "name":null,"in_mode":"flip","initial_state":"restore_last", "auto_on":false, "auto_on_delay":60.00, "auto_off":false, "auto_off_delay": 60.00}}


und der obligatorische halt ^^
OMV5@AsRock j3455 8GB RAM
FHEM@Docker, Shelly "starter pack" 4x PlugS, 2x Bulb Duo RGB, Shelly 2.5, Shelly Plus 1, DoorBird 2103V

Beta-User

Jo, timeout, aber neue Readings, oder...?
Sowas wie "result_in_mode" ;)
Server: HP-elitedesk@Debian 12, aktuelles FHEM@ConfigDB | CUL_HM (VCCU) | MQTT2: MiLight@ESP-GW, BT@OpenMQTTGw | MySensors: seriell, v.a. 2.3.1@RS485 | ZWave | ZigBee@deCONZ | SIGNALduino | MapleCUN | RHASSPY
svn: u.a MySensors, Weekday-&RandomTimer, Twilight,  div. attrTemplate-files

draddy

öh öh ehm, öh,  nein?

also, man sieht am m_sub das er über den topic namen angefragt hat ... aber readings habe ich sonst keine erhalten

hier ne raw

defmod MQTT2_shellyplus1_441793a3b110 MQTT2_DEVICE shellyplus1_441793a3b110
attr MQTT2_shellyplus1_441793a3b110 devStateIcon {my $onl = ReadingsVal($name,'online','false') eq 'false'?'10px-kreis-rot':'10px-kreis-gruen';; $onl = FW_makeImage($onl);; my $light = FW_makeImage(ReadingsVal($name,'state','off'));; my $temp = ReadingsVal($name,'temperature','-100');; my $ip = ReadingsVal($name,'ip','none');; my $reb = ReadingsVal($name,'sys_restart_required','false') eq 'true'?'<a href="/fhem?cmd.dummy=set '.$name.' x_reboot&XHR=1"> ... Notwendigen Reboot durchführen</a>':'';; qq(<a href="http://$ip" target="_blank">${onl}</a><a href="/fhem?cmd.dummy=set $name toggle&XHR=1">${light}</a>$reb<div>Temp: $temp °C</div>)}
attr MQTT2_shellyplus1_441793a3b110 devicetopic shellyplus1-441793a3b110
attr MQTT2_shellyplus1_441793a3b110 getList in_mode:noArg in_mode shellyplus1-441793a3b110/rpc {"id": 1,"src":"shellyplus1-441793a3b110", "method": "Switch.GetConfig", "params": {"id": 0}}
attr MQTT2_shellyplus1_441793a3b110 icon message_socket
attr MQTT2_shellyplus1_441793a3b110 jsonMap switch_state:state switch_temperature_tC:temperature switch_temperature_tF:0 params_wifi_sta_ip:ip
attr MQTT2_shellyplus1_441793a3b110 model shellyPlus_1
attr MQTT2_shellyplus1_441793a3b110 readingList $DEVICETOPIC/online:.* online\
  $DEVICETOPIC/events/rpc:.* { json2nameValue($EVENT,'',$JSONMAP) }\
  $DEVICETOPIC/status/mqtt:.* { json2nameValue($EVENT, 'mqtt_', $JSONMAP) }\
  $DEVICETOPIC/status/sys:.* { json2nameValue($EVENT, 'sys_', $JSONMAP) }\
  $DEVICETOPIC/status/switch_0:.* { $EVENT =~ s/"output":true/"state":"on"/g;; $EVENT =~ s/"output":false/"state":"off"/g;; json2nameValue($EVENT, 'switch_', $JSONMAP) }\
  $DEVICETOPIC/status/cloud:.* {}\
  $DEVICETOPIC/rpc:.* {}\
  fhem2shelly/rpc:.* {}
attr MQTT2_shellyplus1_441793a3b110 room MQTT2_DEVICE
attr MQTT2_shellyplus1_441793a3b110 setList toggle:noArg $DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Toggle","params": {"id":0}}\
  off:noArg $DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Set","params": {"id":0,"on":false}}\
  on:noArg $DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Set","params": {"id":0,"on":true}}\
  on-for-timer $DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Set","params": {"id":0,"on":true,"toggle_after":$EVTPART1}}\
  off-for-timer $DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Set","params": {"id":0,"on":false,"toggle_after":$EVTPART1}}\
  x_update:noArg $DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Shelly.Update","params": {"stage":"stable"}}\
  x_reboot:noArg $DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Shelly.Reboot"}\
  x_eco:true,false $DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Sys.SetConfig","params": {"config": {"device": {"eco_mode": $EVTPART1}}}}\
  in_mode:flip,detached $DEVICETOPIC/rpc {"id":1,"src":"fhem2shelly","method":"Switch.SetConfig","params": {"id":0, "config": {"in_mode": "$EVTPART1"}}}
attr MQTT2_shellyplus1_441793a3b110 setStateList on off toggle on-for-timer off-for-timer
attr MQTT2_shellyplus1_441793a3b110 webCmd :

setstate MQTT2_shellyplus1_441793a3b110 off
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:08:19 IODev m2s
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:11:01 attrTemplateVersion 20220118
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 dst shellyplus1-441793a3b110/events
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:09:53 in_mode set detached
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:40 ip 192.168.177.47
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 method NotifyEvent
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:40 mqtt_connected true
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:40 online true
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 params_events_1_cfg_rev 11
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 params_events_1_component switch:0
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 params_events_1_event config_changed
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 params_events_1_id 0
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 params_events_1_restart_required false
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 params_events_1_ts 1646320685.66
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:40 params_mqtt_connected true
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:58:39 params_switch_0_id 0
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:58:39 params_switch_0_output false
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:58:39 params_switch_0_source MQTT
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:40 params_switch_0_temperature_tC 48.84
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:40 params_switch_0_temperature_tF 119.91
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 params_sys_available_updates_beta_version 0.10.0-beta6
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 params_ts 1646320685.66
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:40 params_wifi_rssi -53
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:40 params_wifi_ssid WLAN-Alex
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:40 params_wifi_status got ip
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 16:18:04 src shellyplus1-441793a3b110
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:58:39 state off
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:58:39 switch_id 0
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:58:39 switch_source MQTT
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_available_updates_beta_version 0.10.0-beta6
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_cfg_rev 5
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_fs_free 237568
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_fs_size 458752
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_mac 441793A3B110
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_ram_free 178940
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_ram_size 249488
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_restart_required false
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_time 15:46
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_unixtime 1646318812
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:46:51 sys_uptime 11
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:58:39 temperature 49.6
setstate MQTT2_shellyplus1_441793a3b110 2022-03-03 15:11:01 x_reboot set
OMV5@AsRock j3455 8GB RAM
FHEM@Docker, Shelly "starter pack" 4x PlugS, 2x Bulb Duo RGB, Shelly 2.5, Shelly Plus 1, DoorBird 2103V

Beta-User

 :-[ ... da hatte ich übersehen, dass dieser Topic ja auch "beerdigt" wird. Bitte mit dem "request"-src das ganze nochmal. Dann sollte ein neuer Eintrag in der rL erfolgen.
Server: HP-elitedesk@Debian 12, aktuelles FHEM@ConfigDB | CUL_HM (VCCU) | MQTT2: MiLight@ESP-GW, BT@OpenMQTTGw | MySensors: seriell, v.a. 2.3.1@RS485 | ZWave | ZigBee@deCONZ | SIGNALduino | MapleCUN | RHASSPY
svn: u.a MySensors, Weekday-&RandomTimer, Twilight,  div. attrTemplate-files

draddy

nochmal fanta4
solangs beiden gefällt und nicht dem einen nur zeit raubt ... :P


hoffe habs richtig gemacht
getList

in_mode:noArg in_mode shellyplus1-441793a3b110/rpc {"id": 1,"src":"request2shelly", "method": "Switch.GetConfig", "params": {"id": 0}}


m_sub

shellyplus1-441793a3b110/rpc {"id": 1,"src":"request2shelly", "method": "Switch.GetConfig", "params": {"id": 0}}
request2shelly/rpc {"id":1,"src":"shellyplus1-441793a3b110","dst":"request2shelly","result":{"id":0, "name":null,"in_mode":"flip","initial_state":"restore_last", "auto_on":false, "auto_on_delay":60.00, "auto_off":false, "auto_off_delay": 60.00}}


readingList neu:

shellyplus1_441793a3b110:request2shelly/rpc:.* { json2nameValue($EVENT) }



neue readings

result_auto_off false 2022-03-03 17:16:41
result_auto_off_delay 60.00 2022-03-03 17:16:41
result_auto_on false 2022-03-03 17:16:41
result_auto_on_delay 60.00 2022-03-03 17:16:41
result_id 0 2022-03-03 17:16:41
result_in_mode flip 2022-03-03 17:16:41
result_initial_state restore_last 2022-03-03 17:16:41
OMV5@AsRock j3455 8GB RAM
FHEM@Docker, Shelly "starter pack" 4x PlugS, 2x Bulb Duo RGB, Shelly 2.5, Shelly Plus 1, DoorBird 2103V

Beta-User

 :)

Damit müßte dann (in "attrTemplate-Sprache") in etwa das hinhauen:
attr DEVICE setList\
  toggle:noArg $\DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Toggle","params": {"id":0}}\
  off:noArg $\DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Set","params": {"id":0,"on":false}}\
  on:noArg $\DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Set","params": {"id":0,"on":true}}\
  on-for-timer $\DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Set","params": {"id":0,"on":true,"toggle_after":$EVTPART1}}\
  off-for-timer $\DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Switch.Set","params": {"id":0,"on":false,"toggle_after":$EVTPART1}}\
  in_mode:flip,detached $DEVICETOPIC/rpc {"id":1,"src":"fhem2shelly","method":"Switch.SetConfig","params": {"id":0, "config": {"in_mode": "$EVTPART1"}}}\
  x_update:noArg $\DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Shelly.Update","params": {"stage":"stable"}}\
  x_reboot:noArg $\DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Shelly.Reboot"}\
  x_eco:true,false $\DEVICETOPIC/rpc {"id":0,"src":"fhem2shelly","method":"Sys.SetConfig","params": {"config": {"device": {"eco_mode": $EVTPART1}}}}
attr DEVICE readingList $\DEVICETOPIC/online:.* online\
  $\DEVICETOPIC/events/rpc:.* { json2nameValue($EVENT,'',$JSONMAP) }\
  $\DEVICETOPIC/status/mqtt:.* { json2nameValue($EVENT, 'mqtt_', $JSONMAP) }\
  $\DEVICETOPIC/status/sys:.* { json2nameValue($EVENT, 'sys_', $JSONMAP) }\
  $\DEVICETOPIC/status/switch_0:.* { $EVENT =~ s/"output":true/"state":"on"/g; $EVENT =~ s/"output":false/"state":"off"/g; json2nameValue($EVENT, 'switch_', $JSONMAP) }\
  $\DEVICETOPIC/status/cloud:.* {}\
  $\DEVICETOPIC/rpc:.* {}\
  fhem2shelly/rpc:.* {}\
  request2shelly/rpc:.* json2nameValue($EVENT, 'req_', $JSONMAP, 'in_mode') }
attr DEVICE getList in_mode:noArg in_mode $\DEVICETOPIC/rpc {"id": 1,"src":"request2shelly", "method": "Switch.GetConfig", "params": {"id": 0}}
attr DEVICE devStateIcon {my $onl = ReadingsVal($name,'online','false') eq 'false'?'10px-kreis-rot':'10px-kreis-gruen'; $onl = FW_makeImage($onl); my $light = FW_makeImage(ReadingsVal($name,'state','off')); my $temp = ReadingsVal($name,'temperature','-100'); my $ip = ReadingsVal($name,'ip','none'); my $reb = ReadingsVal($name,'sys_restart_required','false') eq 'true'?'<a href="/fhem?cmd.dummy=set '.$name.' x_reboot&XHR=1"> ... Notwendigen Reboot durchführen</a>':''; qq(<a href="http://$ip" target="_blank">${onl}</a><a href="/fhem?cmd.dummy=set $name toggle&XHR=1">${light}</a>$reb<div>Temp: $temp °C</div>)}
attr DEVICE jsonMap switch_state:state switch_temperature_tC:temperature switch_temperature_tF:0 params_wifi_sta_ip:ip params_switch_0_temperature_tC:temperature params_switch_0_temperature_tF:0 req_result_in_mode:in_mode


Du darfst dir dann noch Gedanken machen, ob/wie du ggf. das automatisierte Abholen des geänderten Werts machen willst :P .
Server: HP-elitedesk@Debian 12, aktuelles FHEM@ConfigDB | CUL_HM (VCCU) | MQTT2: MiLight@ESP-GW, BT@OpenMQTTGw | MySensors: seriell, v.a. 2.3.1@RS485 | ZWave | ZigBee@deCONZ | SIGNALduino | MapleCUN | RHASSPY
svn: u.a MySensors, Weekday-&RandomTimer, Twilight,  div. attrTemplate-files

draddy

#835
jetzt nicht gleich übertreiben ^^

ich versuch da grade durch zu steigen ...

also

request2shelly/rpc:.* json2nameValue($EVENT, 'req_', $JSONMAP, 'in_mode') }

ist quasi das reading für in_mode ... ja?  und das soll in zukunft nicht mehr alles, sondern "nur" noch in_mode lesen und das läuft NICHT automatisch sonder müsste irgendwie angestossen werden? oO <-- passiert das nicht automatisch? kann man das irgendwie mit event-on-change-reading regeln?

wird die getList überhaupt noch gebraucht?

für mich, viel wichtiger .. was passiert in jsonMap mit

req_result_in_mode:in_mode


und Final (man stellt ja was einem selbst wichtig ist meist als letzte frage ...)
wie bekomm ich jetzt meinen toggle ins devStateIcon ohne wieder meine if / else in die setList zu mauscheln ... und, wenn die wieder da rein muss, wie kann man sie besser / schöner machen xD

und dann noch, DANKE bis hier hin ^^


€dit:

attr DEVICE jsonMap switch_state:state switch_temperature_tC:temperature switch_temperature_tF:0 params_wifi_sta_ip:ip params_switch_0_temperature_tC:temperature params_switch_0_temperature_tF:0 req_result_in_mode:in_mode

sicher das der so muss? irgendwie schreit mich da copy paste fehler an, aber ich kenn mich ja nicht aus xD
OMV5@AsRock j3455 8GB RAM
FHEM@Docker, Shelly "starter pack" 4x PlugS, 2x Bulb Duo RGB, Shelly 2.5, Shelly Plus 1, DoorBird 2103V

Beta-User

...du wirfst da grade ein paar Grundbegriffe reichlich frei durcheinander, und solltest davon ausgehen, dass schon so ziemlich alles seinen Sinn hat :P ...
Zitatist quasi das reading für in_mode ... ja?
Wenn man "quasi" sehr frei interpretieren wollte. Im Ergebnis vielleicht, in der Vorgehensweise ist es die Methode, um (zusammen mit anderen Angaben und dem, was der Shelly konkret hier liefert!) aus einem bestimmten Topic ein bestimmtes Reading rausziehen zu können...

Zitattoggle ins devStateIcon
Ich würde sagen: gar nicht :P .

Würde eher über webCmd gehen in Verbindung mit einem "widget" aus https://wiki.fhem.de/wiki/FHEMWEB/Widgets, das ganze ergänzt mit widgetOverride und (vermutlich) iconSwitch.
Server: HP-elitedesk@Debian 12, aktuelles FHEM@ConfigDB | CUL_HM (VCCU) | MQTT2: MiLight@ESP-GW, BT@OpenMQTTGw | MySensors: seriell, v.a. 2.3.1@RS485 | ZWave | ZigBee@deCONZ | SIGNALduino | MapleCUN | RHASSPY
svn: u.a MySensors, Weekday-&RandomTimer, Twilight,  div. attrTemplate-files

draddy

durcheinander hauen kann ich manchmal ganz gut xD

Zitat von: Beta-User am 03 März 2022, 18:01:56
Ich würde sagen: gar nicht :P .

Würde eher über webCmd gehen in Verbindung mit einem ...
da würde ich sagen, meine if else steht, und mit der bekomm ich es schön hübsch ind devStateIcon :D :D :D

persönlich mag ich webCmd nicht, und, mich jetzt noch stunden rumschlagen, wie ich es schaffe, das mir im webCmd EIN icon zum toggeln angezeigt wird, welches sich auch noch ändert, jehnach status ... irgendwie nicht so ^^

und mit meinem if  else fürn toggle, ists halt rap zap im devStateIcon drin
OMV5@AsRock j3455 8GB RAM
FHEM@Docker, Shelly "starter pack" 4x PlugS, 2x Bulb Duo RGB, Shelly 2.5, Shelly Plus 1, DoorBird 2103V

TomLee

Trotzdem kannst dir den Status zyklisch holen, für den Fall das mal nicht über Fhem die "Kindersicherung" eingeschaltet wurde (weil dieses Event bekommst bisher nicht mit), auch wenn das nicht unbedingt brauchst wie in dem anderen Thread erwähnt hast, im MQTT2_DEVICE ist das halt einfach umzusetzen mit peridicCmd.

Beta-User

Server: HP-elitedesk@Debian 12, aktuelles FHEM@ConfigDB | CUL_HM (VCCU) | MQTT2: MiLight@ESP-GW, BT@OpenMQTTGw | MySensors: seriell, v.a. 2.3.1@RS485 | ZWave | ZigBee@deCONZ | SIGNALduino | MapleCUN | RHASSPY
svn: u.a MySensors, Weekday-&RandomTimer, Twilight,  div. attrTemplate-files