MQTT2+Shelly: erste Konfiguration und template-Entwicklung

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

Vorheriges Thema - Nächstes Thema

Beta-User

Hmm, also FHEM läuft, es scheint "nur" FHEMWEB betroffen zu sein.

Steht was im FHEM-log bzw. ist da was mit starting USB-irgendwas?

Dann mal alles abstöpseln, was USB ist, warten und dann bitte "delete initialUsbCheck" (oder disable).

Ansonsten FHEM beenden und die beiden Devices nochmal löschen (bzw., wenn du noch nicht dazu gekommen sein sollte, liegt es nicht daran....)
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

miggun

#46
USB habe ich nichts dran, war auch schon auf disable
service fhem status
● fhem.service - FHEM Home Automation
   Loaded: loaded (/etc/systemd/system/fhem.service; enabled; vendor preset: ena
   Active: activating (start) since Wed 2018-12-05 11:36:39 CET; 814ms ago
Main PID: 825 (code=exited, status=1/FAILURE); Control PID: 827 (perl)
   CGroup: /system.slice/fhem.service
           └─827 /usr/bin/perl fhem.pl fhem.cfg

Dez 05 11:36:39 raspberrypi systemd[1]: Starting FHEM Home Automation...


Wie komme ich an das FHEM-Log ohne FHEM Web
Raspberry Pi 3 B+
MapleCUN
Shelly1, Shelly2, Shelly4pro, FS20

Beta-User

ssh...

die logs liegen in /opt/fhem/log (meine ich; jedenfalls irgendwo im FHEM-Verzeichnis)
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

miggun

Gefunden

perl fhem.pl -d fhem.cfg
2018.12.05 11:43:41 5: Loading ./FHEM/99_FHEMControlPush.pm
2018.12.05 11:43:41 5: Loading ./FHEM/99_SUNRISE_EL.pm
2018.12.05 11:43:41 5: Loading ./FHEM/99_Utils.pm
2018.12.05 11:43:41 5: Initializing Type Library:
2018.12.05 11:43:41 1: Including fhem.cfg
2018.12.05 11:43:41 5: Cmd: >attr global userattr cmdIcon devStateIcon devStateStyle genericDeviceType:security,ignore,switch,outlet,light,blind,thermometer,thermostat,contact,garage,window,lock homebridgeMapping:textField-long icon siriName sortby webCmd webCmdLabel:textField-long widgetOverride<
2018.12.05 11:43:41 5: Cmd: >attr global autoload_undefined_devices 1<
2018.12.05 11:43:41 5: Cmd: >attr global autosave 0<
2018.12.05 11:43:41 5: Cmd: >attr global logfile ./log/fhem-%Y-%m.log<
2018.12.05 11:43:41 5: Cmd: >attr global modpath .<
2018.12.05 11:43:41 5: Cmd: >attr global motd SecurityCheck:
  WEB is not password protected
  MQTT2_SERVER is not password protected
  tPort is not password protected

Protect this FHEM installation by defining an allowed device with define allowed allowed
You can disable this message with attr global motd none<
2018.12.05 11:43:41 5: Cmd: >attr global statefile ./log/fhem.save<
2018.12.05 11:43:41 5: Cmd: >attr global verbose 3<
2018.12.05 11:43:41 5: Cmd: >define WEB FHEMWEB 8083 global<
2018.12.05 11:43:41 5: Loading ./FHEM/01_FHEMWEB.pm
2018.12.05 11:43:42 3: WEB: port 8083 opened
2018.12.05 11:43:42 5: Cmd: >attr WEB editConfig 1<
2018.12.05 11:43:42 5: Cmd: >define Logfile FileLog ./log/fhem-%Y-%m.log fakelog<
2018.12.05 11:43:42 5: Loading ./FHEM/92_FileLog.pm
2018.12.05 11:43:42 1: define Logfile FileLog ./log/fhem-%Y-%m.log fakelog: Can't open ./log/fhem-2018-12.log: Permission denied
2018.12.05 11:43:42 5: fhem.cfg line 20 returned >Can't open ./log/fhem-2018-12.log: Permission denied<
2018.12.05 11:43:42 5: Cmd: >define autocreate autocreate<
2018.12.05 11:43:42 5: Loading ./FHEM/98_autocreate.pm
2018.12.05 11:43:42 5: Cmd: >attr autocreate filelog ./log/%NAME-%Y.log<
2018.12.05 11:43:42 5: Cmd: >define eventTypes eventTypes ./log/eventTypes.txt<
2018.12.05 11:43:42 5: Loading ./FHEM/91_eventTypes.pm
2018.12.05 11:43:42 2: eventTypes: loaded 196 events from ./log/eventTypes.txt
2018.12.05 11:43:42 5: Cmd: >define initialUsbCheck notify global:INITIALIZED usb create<
2018.12.05 11:43:42 5: Loading ./FHEM/91_notify.pm
2018.12.05 11:43:42 5: Cmd: >attr initialUsbCheck disable 1<
2018.12.05 11:43:42 5: Cmd: >define tPort telnet 7072 global<
2018.12.05 11:43:42 5: Loading ./FHEM/98_telnet.pm
2018.12.05 11:43:42 3: tPort: port 7072 opened
2018.12.05 11:43:42 5: Cmd: >define siri siri<
2018.12.05 11:43:42 5: Loading ./FHEM/39_siri.pm
2018.12.05 11:43:42 5: Cmd: >define nRestartHomebridge notify global:INITIALIZED set homebridge restart<
2018.12.05 11:43:42 5: Cmd: >define homebridge serviced homebridge<
2018.12.05 11:43:42 5: Loading ./FHEM/98_serviced.pm
2018.12.05 11:43:42 5: Cmd: >attr homebridge alias Service homebridge<
2018.12.05 11:43:42 5: Cmd: >attr homebridge cmdIcon restart:rc_REPEAT stop:rc_STOP status:rc_INFO start:rc_PLAY<
2018.12.05 11:43:42 5: Cmd: >attr homebridge devStateIcon Initialized|status:light_question error|failed:light_exclamation running:audio_play:stop stopped:audio_stop:start stopping:audio_stop .*starting:audio_repeat<
2018.12.05 11:43:42 5: Cmd: >attr homebridge genericDeviceType switch<
2018.12.05 11:43:42 5: Cmd: >attr homebridge homebridgeMapping On=state,valueOff=/stopped|failed/,cmdOff=stop,cmdOn=start
StatusJammed=state,values=/error|failed/:JAMMED;/.*/:NOT_JAMMED<
2018.12.05 11:43:42 5: Cmd: >attr homebridge icon hue_room_garage<
2018.12.05 11:43:42 5: Cmd: >attr homebridge room Services<
2018.12.05 11:43:42 5: Cmd: >attr homebridge webCmd start:restart:stop:status<
2018.12.05 11:43:42 5: Cmd: >define MapleCUN1 CUL 192.168.1.8:2323 0000<
2018.12.05 11:43:42 5: Loading ./FHEM/00_CUL.pm
2018.12.05 11:43:42 3: Opening MapleCUN1 device 192.168.1.8:2323
2018.12.05 11:43:43 5: SW: V
2018.12.05 11:43:43 5: CUL/RAW (ReadAnswer): V 1.26.04 a-culfw Build: 306 (2018-10-02_16-37-10) MapleCUNx4_8F (F-Band: 868MHz)

2018.12.05 11:43:43 5: SW: ?
2018.12.05 11:43:43 5: CUL/RAW (ReadAnswer): ? (? is unknown) Use one of B b C F i A Z N E k G M K L U Y R T V W X e f l p t x z *

2018.12.05 11:43:43 3: MapleCUN1: Possible commands: BbCFiAZNEkGMKLUYRTVWXeflptxz*
2018.12.05 11:43:43 5: SW: X21
2018.12.05 11:43:43 5: SW: T01
2018.12.05 11:43:43 5: CUL/RAW (ReadAnswer): 0000

2018.12.05 11:43:43 5: GOT CUL fhtid: 0000
2018.12.05 11:43:43 3: MapleCUN1 device opened
2018.12.05 11:43:43 5: Cmd: >attr MapleCUN1 rfmode SlowRF<
2018.12.05 11:43:43 5: Cmd: >define MapleCUN2 STACKABLE_CC MapleCUN1<
2018.12.05 11:43:43 5: Loading ./FHEM/16_STACKABLE_CC.pm
2018.12.05 11:43:43 5: SW: *V
2018.12.05 11:43:43 5: CUL/RAW (ReadAnswer): *V 1.26.04 a-culfw Build: 306 (2018-10-02_16-37-10) MapleCUNx4_8F (F-Band: 433MHz)

2018.12.05 11:43:43 5: SW: *?
2018.12.05 11:43:43 5: CUL/RAW (ReadAnswer): *? (? is unknown) Use one of b C F i A Z N E G M K L U Y R T V W X f x z *

2018.12.05 11:43:43 3: MapleCUN2: Possible commands: bCFiAZNEGMKLUYRTVWXfxz*
2018.12.05 11:43:43 5: SW: *X21
2018.12.05 11:43:43 5: Cmd: >define MapleCUN3 STACKABLE_CC MapleCUN2<
2018.12.05 11:43:43 5: SW: **V
2018.12.05 11:43:43 5: CUL/RAW (ReadAnswer): **V 1.26.04 a-culfw Build: 306 (2018-10-02_16-37-10) MapleCUNx4_8F (F-Band: 868MHz)

2018.12.05 11:43:43 5: SW: **?
2018.12.05 11:43:43 5: CUL/RAW (ReadAnswer): **? (? is unknown) Use one of b C F i A Z N E G M K L U Y R T V W X f x z *

2018.12.05 11:43:43 3: MapleCUN3: Possible commands: bCFiAZNEGMKLUYRTVWXfxz*
2018.12.05 11:43:43 5: SW: **X21
2018.12.05 11:43:43 5: Cmd: >define MapleCUN4 STACKABLE_CC MapleCUN3<
2018.12.05 11:43:43 5: SW: ***V
2018.12.05 11:43:43 5: CUL/RAW (ReadAnswer): ***V 1.26.04 a-culfw Build: 306 (2018-10-02_16-37-10) MapleCUNx4_8F (F-Band: 868MHz)

2018.12.05 11:43:43 5: SW: ***?
2018.12.05 11:43:43 5: CUL/RAW (ReadAnswer): ***? (? is unknown) Use one of C A Z N E L Y V X f z

2018.12.05 11:43:43 3: MapleCUN4: Possible commands: CAZNELYVXfz
2018.12.05 11:43:43 5: SW: ***X21
2018.12.05 11:43:43 5: Cmd: >define au_Hallentor FS20 1111 01<
2018.12.05 11:43:43 5: Loading ./FHEM/10_FS20.pm
2018.12.05 11:43:43 5: Cmd: >attr au_Hallentor IODev MapleCUN1<
2018.12.05 11:43:43 5: Cmd: >attr au_Hallentor devStateIcon on:fts_garage_door_10@red off:fts_garage_door_100@green<
2018.12.05 11:43:43 5: Cmd: >attr au_Hallentor genericDeviceType GarageDoorOpener<
2018.12.05 11:43:43 5: Cmd: >attr au_Hallentor icon fts_garage<
2018.12.05 11:43:43 5: Cmd: >attr au_Hallentor room FS20<
2018.12.05 11:43:43 5: Cmd: >define FileLog_au_Hallentor FileLog ./log/au_Hallentor-%Y.log au_Hallentor<
2018.12.05 11:43:43 1: define FileLog_au_Hallentor FileLog ./log/au_Hallentor-%Y.log au_Hallentor: Can't open ./log/au_Hallentor-2018.log: Permission denied
2018.12.05 11:43:43 5: fhem.cfg line 54 returned >Can't open ./log/au_Hallentor-2018.log: Permission denied<
2018.12.05 11:43:43 5: Cmd: >attr FileLog_au_Hallentor logtype text<
2018.12.05 11:43:43 5: Cmd: >attr FileLog_au_Hallentor room FS20<
2018.12.05 11:43:43 5: Cmd: >define au_Garagentor FS20 1111 b1<
2018.12.05 11:43:43 5: Cmd: >attr au_Garagentor IODev MapleCUN1<
2018.12.05 11:43:43 5: Cmd: >attr au_Garagentor eventMap /on-for-timer 1:Taster/<
2018.12.05 11:43:43 5: Cmd: >attr au_Garagentor icon fts_garage<
2018.12.05 11:43:43 5: Cmd: >attr au_Garagentor room FS20<
2018.12.05 11:43:43 5: Cmd: >attr au_Garagentor siriName Garagentor<
2018.12.05 11:43:43 5: Cmd: >attr au_Garagentor webCmd Taster<
2018.12.05 11:43:43 5: Cmd: >define FileLog_au_Garagentor FileLog ./log/au_Garagentor-%Y.log au_Garagentor<
2018.12.05 11:43:43 1: define FileLog_au_Garagentor FileLog ./log/au_Garagentor-%Y.log au_Garagentor: Can't open ./log/au_Garagentor-2018.log: Permission denied
2018.12.05 11:43:43 5: fhem.cfg line 64 returned >Can't open ./log/au_Garagentor-2018.log: Permission denied<
2018.12.05 11:43:43 5: Cmd: >attr FileLog_au_Garagentor logtype text<
2018.12.05 11:43:43 5: Cmd: >attr FileLog_au_Garagentor room FS20<
2018.12.05 11:43:43 5: Cmd: >define Hallentor dummy<
2018.12.05 11:43:43 5: Loading ./FHEM/98_dummy.pm
2018.12.05 11:43:43 5: Cmd: >attr Hallentor genericDeviceType switch<
2018.12.05 11:43:43 5: Cmd: >attr Hallentor homebridgeMapping On=state,valueOff=off,valueOn=on,cmdOff=off,cmdOn=on<
2018.12.05 11:43:43 5: Cmd: >attr Hallentor icon fts_garage<
2018.12.05 11:43:43 5: Cmd: >attr Hallentor room Homekit<
2018.12.05 11:43:43 5: Cmd: >attr Hallentor webCmd on:off<
2018.12.05 11:43:43 5: Cmd: >define n_Hallentor_a notify Hallentor:on set au_Hallentor on<
2018.12.05 11:43:43 5: Cmd: >define n_Hallentor_z notify Hallentor:off set au_Hallentor off<
2018.12.05 11:43:43 5: Cmd: >define CUL_WS_8 CUL_WS 8<
2018.12.05 11:43:43 5: Loading ./FHEM/14_CUL_WS.pm
2018.12.05 11:43:43 5: Cmd: >attr CUL_WS_8 room CUL_WS<
2018.12.05 11:43:43 5: Cmd: >define FileLog_CUL_WS_8 FileLog ./log/CUL_WS_8-%Y.log CUL_WS_8:T:.*<
2018.12.05 11:43:43 1: define FileLog_CUL_WS_8 FileLog ./log/CUL_WS_8-%Y.log CUL_WS_8:T:.*: Can't open ./log/CUL_WS_8-2018.log: Permission denied
2018.12.05 11:43:43 5: fhem.cfg line 77 returned >Can't open ./log/CUL_WS_8-2018.log: Permission denied<
2018.12.05 11:43:43 5: Cmd: >attr FileLog_CUL_WS_8 logtype temp4hum6:Temp/Hum,text<
2018.12.05 11:43:43 5: Cmd: >attr FileLog_CUL_WS_8 room CUL_WS<
2018.12.05 11:43:43 5: Cmd: >define SVG_CUL_WS_8 SVG FileLog_CUL_WS_8:SVG_CUL_WS_8:CURRENT<
2018.12.05 11:43:43 5: Loading ./FHEM/98_SVG.pm
2018.12.05 11:43:43 5: Cmd: >attr SVG_CUL_WS_8 label "CUL_WS_8 Min $data{min1}, Max $data{max1}, Last $data{currval1}"<
2018.12.05 11:43:43 5: Cmd: >attr SVG_CUL_WS_8 room Plots<
2018.12.05 11:43:43 5: Cmd: >define Garagentor dummy<
2018.12.05 11:43:43 5: Cmd: >attr Garagentor genericDeviceType GarageDoorOpener<
2018.12.05 11:43:43 5: Cmd: >attr Garagentor homebridgeMapping CurrentDoorState=state,values=closed:CLOSED;open:OPEN;closing:CLOSING;opening:OPENING
attr Garagentor icon fts_garage<
2018.12.05 11:43:43 5: Cmd: >attr Garagentor room Unsorted<
2018.12.05 11:43:43 5: Cmd: >attr Garagentor setList open stop closed<
2018.12.05 11:43:43 5: Cmd: >attr Garagentor webCmd Auf:Stop:Zu<
2018.12.05 11:43:43 5: Cmd: >define Carport dummy<
2018.12.05 11:43:43 5: Cmd: >attr Carport devStateIcon auf:fts_garage_door_10@red zu:fts_garage_door_100@green<
2018.12.05 11:43:43 5: Cmd: >attr Carport event-on-change-reading .*<
2018.12.05 11:43:43 5: Cmd: >attr Carport genericDeviceType GarageDoorOpener<
2018.12.05 11:43:43 5: Cmd: >attr Carport homebridgeMapping CurrentDoorState=state,values=closed:CLOSED;open:OPEN;opening:OPENING;closing:CLOSING\ TargetDoorState=state,cmds=OPEN:auf;CLOSED:zu,values=zu:CLOSED;auf:OPEN<
2018.12.05 11:43:43 5: Cmd: >attr Carport room Homekit<
2018.12.05 11:43:43 5: Cmd: >attr Carport setList auf zu<
2018.12.05 11:43:43 5: Cmd: >attr Carport siriName Carport<
2018.12.05 11:43:43 5: Cmd: >attr Carport webCmd auf:zu<
2018.12.05 11:43:43 5: Cmd: >define MQTT2_SERVER MQTT2_SERVER 1883 global<
2018.12.05 11:43:43 5: Loading ./FHEM/00_MQTT2_SERVER.pm
2018.12.05 11:43:43 1: MQTT2_SERVER: Can't open server port at 1883: Address already in use. Exiting.
Raspberry Pi 3 B+
MapleCUN
Shelly1, Shelly2, Shelly4pro, FS20

Beta-User

Interessant ist nur die letzte Meldung.
Ist der Mosquitto runter oder läuft der noch (dann bitte Deinstallieren)? Gibt es mehrere MQTT2-Server-Definitionen in der cfg?
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

miggun

Ist noch drauf, hatte ich aber gestoppt.
Habe jetzt Mosquitto gestoppt.

Ui, das war das Problem. :o
Jetzt muss ich erst mal lesen, wie ich Mosquitto sauber lösche....das ist sonst Mist.
Raspberry Pi 3 B+
MapleCUN
Shelly1, Shelly2, Shelly4pro, FS20

miggun

Zitat von: Beta-User am 05 Dezember 2018, 10:59:44
Kannst du mal folgendes tun:
Die beiden Devices löschen (die Raw-Def hast du ja für Notfälle hier), save&update, dann in /opt/fhem/FHEM/lib/AttrTemplate/mqtt2.template (am Ende) einfügen (z.B. mit mcedit aus dem Paket mc ;) ):
# shelly2 using original firmware.
# NOTE: a second device will be created for the second channel
name:shelly2
filter:TYPE=MQTT2_DEVICE
attr DEVICE setList\
  off:noArg shellies/DEVICE/relay/0/command off
  on:noArg shellies/DEVICE/relay/0/command on
attr DEVICE readingList shellies/DEVICE/relay/0:.* state
attr DEVICE getList shellies/DEVICE/relay/power power
attr DEVICE comment Channel 1 for DEVICE, see also DEVICE_CH2
copy DEVICE DEVICE_CH2
attr DEVICE_CH2 readingList shellies/DEVICE/relay/1:.* state
attr DEVICE_CH2 comment Channel 2 for DEVICE
attr DEVICE_CH2 setList \
  off:noArg shellies/DEVICE/relay/1/command off
  on:noArg shellies/DEVICE/relay/1/command on
deleteattr DEVICE_CH2 getList


Anschließend FHEM neu starten, und dann mal über das Web-Interface am Shelly selbst einen Schaltvorgang auslösen (unterstellt, autocreate am MQTT2-Server ist an).

Es sollte ein MQTT2-DEVICE angelegt werden (mit Namen und der CID shellyswitch-32B268). Auf dieses dann ein set shellyswitch-32B268 attrTemplate shelly2 ausführen...

Danach sollten 2 Devices vorhanden sein, die sich bedienen lassen und dann auch die richtigen settings haben? (Natürlich noch keine Verschönerungen, aber das ist dann nicht Gegenstand des template :) .)

In der DropDown Liste fehlt der Shelly2.

Unknown template_entry_name shelly2
Raspberry Pi 3 B+
MapleCUN
Shelly1, Shelly2, Shelly4pro, FS20

Beta-User

Zitat von: miggun am 05 Dezember 2018, 11:49:32
Jetzt muss ich erst mal lesen, wie ich Mosquitto sauber lösche....das ist sonst Mist.
apt-get uninstall mosquitto sollte mit den richtigen Rechten helfen; schön, dass wir das bei der Gelegenheit gemerkt haben.

Zitat von: miggun am 05 Dezember 2018, 11:57:53
In der DropDown Liste fehlt der Shelly2.
Die Datei hattest du editiert wie beschrieben? (Rechte passen noch?)
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

miggun

Jetzt wieder von der Arbeit mit dem Handy
Die Datei habe ich editiert.
Aber der Sonoff Eintrag, der vorher steht fehlt bei mir auch.
Also ein Rechte-Problem?


Raspberry Pi 3 B+
Raspberry Pi 3 B+
MapleCUN
Shelly1, Shelly2, Shelly4pro, FS20

Beta-User

...wenn im svn "mehr" steht als in deinem FHEM, ist was mit dem update schief gegangen, an ein Rechte-Thema glaube ich in dem Fall nicht (du faßt das ja offensichtlich zum ersten Mal an, und das Editieren macht m.E. erst dann Sinn, wenn sonst alles da ist, andernfalls wird ggf. was überschrieben)...

Das sollte bitte zuerst reibungslos durchlaufen, sonst ist das Risiko groß, dass die Dinge nicht zueinander passen. Laß dir Zeit, die Zusammenhänge zu verstehen ;) . Ist sehr wichtig, sonst stehst du beim nächsten Mal ohne Helfer im Regen.
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

miggun

Mach ich.
Ich fang jetzt erst mal mit Mosquitto an, damit beim nächsten mal kein böses Erwachen hab. Dann weiter mit Updates.


Raspberry Pi 3 B+
Raspberry Pi 3 B+
MapleCUN
Shelly1, Shelly2, Shelly4pro, FS20

miggun

So Mosquitto erstmal mit

sudo apt-get remove --auto-remove mosquitto

deinstalliert
Raspberry Pi 3 B+
MapleCUN
Shelly1, Shelly2, Shelly4pro, FS20

miggun

Zitat von: dkreutz am 05 Dezember 2018, 11:16:28
Das ist meines Wissens nach ein Fehler in der Shelly2-Firmware (bei ShellyPlug funktioniert das sauber)

So, jetzt wo alles wieder läuft....
Danke Dir. Gibt es nicht eine Möglichkeit, dass ich sage:
guck auf den Messwertwenn wenn der Status vom relay0 oder relay1 on ist, sobald der Status vom relay0 und relay1 off ist setze den Meßwert auf 0
Raspberry Pi 3 B+
MapleCUN
Shelly1, Shelly2, Shelly4pro, FS20

Beta-User

notify auf beide Devices ansetzen (Klammer um beide Devicenamen und | dazwischen), dann prüfen, ob beide Value() der Devices auf "off" sind und wenn ja: Readings setzen ;) .

Beispiel für kombiniertes Event:
define n_Button_3_Weihnachtsbaum notify (Schalter_Spuele_Btn_03|Schalter_WZ1_Btn_02):Short.* set Weihnachtsbaum toggle
Hinweise zur Auswertung mehrerer Devices: https://wiki.fhem.de/wiki/Notify#Einfache_UND_Funktion
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

miggun

Dann werde ich den hier mal probieren oder muss ich etwas für Else angeben?

define n_Kueche_Leistung  notify (Kueche_Eckbank|Kueche_Hauptlicht) { my $r1 = Value("Kueche_Eckbank");; my $r2 = Value("Kueche_Hauptlicht");; if ($r1 eq "off" && $r2 eq "off") { fhem("set Kueche_Licht_Leistung 0");; } }
Raspberry Pi 3 B+
MapleCUN
Shelly1, Shelly2, Shelly4pro, FS20