FHEM Forum

FHEM - Hausautomations-Systeme => MQTT => Thema gestartet von: JoWiemann am 06 November 2025, 10:02:23

Titel: zu Dumm für Fhem und ioBroker per MQTT
Beitrag von: JoWiemann am 06 November 2025, 10:02:23
Hallo,

da das Fhem Modul echodevice aktuell nicht läuft habe ich mir den Adapter Alexa2 im ioBroker installiert. Die Daten vom Alexa2 Adapter bekomme ich auch über den ioBroker Adapter "MQTT Broker/Client" problemlos über das Fhem Modul MQTT2_SERVER nach Fhem.

Und nun kommt mein scheitern. Ich möchte gerne von Fhem auf alexa2.0.Echo-Devices.G091GG07116504MT.Commands.speak publishen und scheitere kläglich.

speak ist in den Objektdaten im ioBroker als r/w parametriert.

Über Tipps würde ich mich freuen. Vielen Dank.

Grüße Jörg
Titel: Aw: zu Dumm für Fhem und ioBroker per MQTT
Beitrag von: TomLee am 06 November 2025, 10:15:49
Moin,

und wo ist das list von dem Device ?  :P
Titel: Aw: zu Dumm für Fhem und ioBroker per MQTT
Beitrag von: JoWiemann am 06 November 2025, 10:27:12
define Amazon_ECHO MQTT2_DEVICE Amazon_ECHO
attr Amazon_ECHO alias Familien Echo
attr Amazon_ECHO autocreate 0
attr Amazon_ECHO readingList Amazon_ECHO:info/connection:.* connection\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/announcement:.* announcement\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/calendarNext:.* calendarNext\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/calendarToday:.* calendarToday\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/calendarTomorrow:.* calendarTomorrow\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/cleanup:.* cleanup\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/curatedtts:.* curatedtts\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/deviceStop:.* deviceStop\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/doNotDisturb:.* doNotDisturb\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/flashbriefing:.* flashbriefing\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/funfact:.* funfact\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/goodmorning:.* goodmorning\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/joke:.* joke\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/notification:.* notification\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/singasong:.* singasong\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/skill:.* skill\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/skillYours:.* skillYours\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/sound:.* sound\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/speak:.* speak\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/speak-volume:.* speak_volume\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/ssml:.* ssml\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/tellstory:.* tellstory\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/textCommand:.* textCommand\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/traffic:.* traffic\
Amazon_ECHO:alexa2/0/Echo-Devices/G091GG07116504MT/Commands/weather:.* weather
attr Amazon_ECHO room Amazon,MQTT
attr Amazon_ECHO setList speak Amazon_ECHO/alexa2/0/Echo-Devices/G091GG07116504MT/Commands/speak/set\
speak-volume Amazon_ECHO/alexa2/0/Echo-Devices/G091GG07116504MT/Commands/speak-volume/set
#   CFGFN     
#   CID        Amazon_ECHO
#   DEF        Amazon_ECHO
#   FUUID      690b3ba2-f33f-0b39-3471-4c3bb83b35a49e82
#   IODev      MQTT2_FHEM_Server
#   LASTInputDev MQTT2_FHEM_Server
#   MQTT2_FHEM_Server_CONN MQTT2_FHEM_Server_192.168.0.234_57284
#   MQTT2_FHEM_Server_MSGCNT 952
#   MQTT2_FHEM_Server_TIME 2025-11-06 09:31:06
#   MSGCNT     952
#   NAME       Amazon_ECHO
#   NR         1490
#   STATE      speak-volume
#   TYPE       MQTT2_DEVICE
#   eventCount 1644
#   OLDREADINGS:
#   READINGS:
#     2025-11-06 09:31:06   announcement   
#     2025-11-06 09:31:06   calendarNext    false
#     2025-11-06 09:31:06   calendarToday   false
#     2025-11-06 09:31:06   calendarTomorrow false
#     2025-11-06 09:31:06   cleanup         false
#     2025-11-06 09:30:57   connection      true
#     2025-11-06 09:31:06   curatedtts     
#     2025-11-06 09:31:06   deviceStop      false
#     2025-11-06 09:31:06   doNotDisturb    false
#     2025-11-06 09:31:06   flashbriefing   false
#     2025-11-06 09:31:06   funfact         false
#     2025-11-06 09:31:06   goodmorning     false
#     2025-11-06 09:31:06   joke            false
#     2025-11-06 09:31:06   notification   
#     2025-11-06 09:31:06   singasong       false
#     2025-11-06 09:31:06   skill           
#     2025-11-06 09:31:06   skillYours     
#     2025-11-06 09:31:06   sound           
#     2025-11-06 09:31:06   speak           noch test
#     2025-11-06 09:31:06   speak_volume    50
#     2025-11-06 09:31:06   ssml           
#     2025-11-05 16:04:20   state           speak-volume
#     2025-11-05 17:00:36   subscriptions   Amazon_ECHO/#
#     2025-11-06 09:31:06   tellstory       false
#     2025-11-06 09:31:06   textCommand     
#     2025-11-06 09:31:06   traffic         false
#     2025-11-06 09:31:06   weather         false
#   hmccu:
#
setstate Amazon_ECHO speak-volume
setstate Amazon_ECHO 2025-11-06 09:31:06 announcement
setstate Amazon_ECHO 2025-11-06 09:31:06 calendarNext false
setstate Amazon_ECHO 2025-11-06 09:31:06 calendarToday false
setstate Amazon_ECHO 2025-11-06 09:31:06 calendarTomorrow false
setstate Amazon_ECHO 2025-11-06 09:31:06 cleanup false
setstate Amazon_ECHO 2025-11-06 09:30:57 connection true
setstate Amazon_ECHO 2025-11-06 09:31:06 curatedtts
setstate Amazon_ECHO 2025-11-06 09:31:06 deviceStop false
setstate Amazon_ECHO 2025-11-06 09:31:06 doNotDisturb false
setstate Amazon_ECHO 2025-11-06 09:31:06 flashbriefing false
setstate Amazon_ECHO 2025-11-06 09:31:06 funfact false
setstate Amazon_ECHO 2025-11-06 09:31:06 goodmorning false
setstate Amazon_ECHO 2025-11-06 09:31:06 joke false
setstate Amazon_ECHO 2025-11-06 09:31:06 notification
setstate Amazon_ECHO 2025-11-06 09:31:06 singasong false
setstate Amazon_ECHO 2025-11-06 09:31:06 skill
setstate Amazon_ECHO 2025-11-06 09:31:06 skillYours
setstate Amazon_ECHO 2025-11-06 09:31:06 sound
setstate Amazon_ECHO 2025-11-06 09:31:06 speak noch test
setstate Amazon_ECHO 2025-11-06 09:31:06 speak_volume 50
setstate Amazon_ECHO 2025-11-06 09:31:06 ssml
setstate Amazon_ECHO 2025-11-05 16:04:20 state speak-volume
setstate Amazon_ECHO 2025-11-05 17:00:36 subscriptions Amazon_ECHO/#
setstate Amazon_ECHO 2025-11-06 09:31:06 tellstory false
setstate Amazon_ECHO 2025-11-06 09:31:06 textCommand
setstate Amazon_ECHO 2025-11-06 09:31:06 traffic false
setstate Amazon_ECHO 2025-11-06 09:31:06 weather false
Titel: Aw: zu Dumm für Fhem und ioBroker per MQTT
Beitrag von: Beta-User am 06 November 2025, 10:41:38
Die "subscriptions" sehen für sich genommen komisch aus.

Zur setList: muss da nicht ein Oayload mit übergeben werden mit dem Text?
Gibt es irgendwo eine Projekt-Seite, aus der mehr Details abgelesen werden können?
Titel: Aw: zu Dumm für Fhem und ioBroker per MQTT
Beitrag von: TomLee am 06 November 2025, 10:55:17
speak:textField {my @a=split / /,$EVENT;shift @a;$EVENT = join ' ', @a;return qq(alexa2/0/Echo-Devices/G091GG07116504MT/Commands/speak/set $EVENT)}
?
Titel: Aw: zu Dumm für Fhem und ioBroker per MQTT
Beitrag von: Beta-User am 06 November 2025, 11:12:17
Zitat von: TomLee am 06 November 2025, 10:55:17speak:textField {my @a=split / /,$EVENT;shift @a;$EVENT = join ' ', @a;return qq(alexa2/0/Echo-Devices/G091GG07116504MT/Commands/speak/set $EVENT)}
?
OT: warum splitten wir in solchen Fällen nicht gleich nur in zwei Teile?
Titel: Aw: zu Dumm für Fhem und ioBroker per MQTT
Beitrag von: TomLee am 06 November 2025, 11:24:59
In erster Linie gings mir um die Funktionalität!

So ?

speak:textField {(undef, $EVENT) = split / /, $EVENT, 2;return qq(alexa2/0/Echo-Devices/G091GG07116504MT/Commands/speak/set $EVENT)}