binderth
(Thomas Binder)
November 9, 2022, 4:32pm
1
I just wondered how you could achieve something like that:
Someone leaves the house
Leaving a note via Alexa: “I’m at the groceries, back in 30”
Someone opens the front door
Alexa repeats the note
How can I use Alexa to update a string item with some random text?
We have an echo in our entrance and OH knows, when (and even who) opened the front door already.
Wolfgang_S
(Wolfgang_S)
November 10, 2022, 6:25pm
2
Shouldn’t that be doable with the last voice command
?
Trigger a rule on changes of last voice command
content
first part of the text of last voice command would contain the trigger to set the message
second part is the message itself ( your rule needs to split the sring )
set a variable ( item ) with the content
when the front door is opened trigger a rule to speak the message part of your stored command
binderth
(Thomas Binder)
November 10, 2022, 6:34pm
3
that would be my backup, because it’s actually an error!
But of course, it would work: “Alexa, tell my family, that I’m out shopping and I’m back at 6”.
The trigger on “last voice command” could then look, for “Alexa, tell my family, that” - and can write the rest in an item, which will then be TTS’ed on opening the front door.
binderth
(Thomas Binder)
November 11, 2022, 8:17am
4
I played around a bit and what i think works best is:
use the “tell everyone…” option with Alexa
so, before you leave, you say “Alexa, tell everyone I’m at the groceries, back at 6”
this will trigger an announcement on all Alexas for the ones at home to be informed
a rule will listen to the “lastCommand”-channel coming from the Alexa in the entrance
the rule will cut the “Alexa, tell everyone” from the “lastCommand” and write it in a “readGreetingText”-String item and a “readGreeting”-Switch item
another rule triggered after either “door open” or “detected fingerprint from person XY”
the “readGreetingText” will TTS’ed from the Alexa in the entrance
I could add a switch-item for everyone in the house, so that one after another gets the message
after xx time or on another trigger the “readGreeting”-Switch item goes OFF.
1 Like