When I open my echo dot from the Overview pane and asked it to speak ‘hello’ Alexa responds that I must use the alexa tts service. A popup shows up saying it called google_tts. When I open media_player.alexa_tts from services and specify the entity_id for my dot, it works.
So I modified my configuration.yaml and added
tts:
- platform: google
- platform: alexa
(as if I knew what I was doing…) and the configuration check says
Platform not found: tts.alexa
I checked alexa.py and it says VERSION 0.9.6. I got this from the “testers needed” forum discussion.
My questions are 1) how do I get alexa to use the correct tts platform and 2) can I have both Google Home and Alexa platforms at the same time?
This is by no means the answer, but I also have a similar related post on here at the moment.
I have been able to get a message spoken on Alexa by going to the Service button in the DEv Tools and manually typing the service and service data manually, as described in the KEaton Taylor post.
ALthough I have not been able to successfully message to alex from an action in my automations.yaml file, or to be able to TTS from the media player in the overview tab.
@jimpower Are you saying there is no way to assign the alexa entities the media_player.alexa_tts service? I’ve been looking through all the yaml files to see how that might be done.
Unfortunately Yes. Thanks to jimpower and BigRob, I find I can only address the Alexa through automations. I tested one with device_tracker that welcomes me home in automations.yaml:
- id: ‘123547476435’
alias: Bart Home
initial_state: True
trigger:
- entity_id: device_tracker.00_ae_fa_ez_xa_ya
from: not_home
platform: state
to: home
condition: []
action:
- data:
entity_id: media_player.bob_s_dot
message: Hello Bart, glad you are home
service: media_player.alexa_tts
unfortunately I can’t just type in this code - have to use the configuration tab then automations which is kind of clunky. I tried to type in the same thing but hassio would not recognize it. I’m guessing the id needs to be generated, not made-up. It could be that I’m doing something else wrong but this works. Sorry if the indentations aren’t exact. When I do a copy of the yaml code and paste here using preformatted text, it messes up the indents so I tried to fix it.
Many thanks.
to get the code to look right just put 4 spaces before each line.
I have corrected the spelling. That was causing my issue the other day too lol…
You could set up a card with softswitches configured to activate “Canned messages” ones that are pre made in automations.yaml until the TTS for alexa is available in the media player frontend.
Good for me at the moment I only want TTS for automations.
Thanks Jim. If I understand you correctly, I paste it first, then highlight what I pasted, then hit the </> symbol.
I will give that a try next time I post some code.
I do have speech working using alexa_tts using an automation and device_tracker. Sadly, my Galaxy Note 5 seems to be turning off wifi every so often scaring the bejeezus out of my wife and daughter. I’ll try using the ping tracker platform next and see if that fixes the false “Home” / “Away” recognition.
I think you will find ping is the same as your phone turns off wifi when it goes to sleep. I can recommend using the GPSlogger component for accurate presence detection. Accurate presence detection is the purple unicorn of home automation feel free to have a read of my repo for tips on using a multi pronged attack in regards to presence detection.
Many thanks Jim.
Your whole setup is very impressive and the presence detection is amazing. It is so comprehensive it borders on stalking - but as DrzZ says: “if it’s family, it’s not stalking…”
I could learn a lot from your work, but right now I have to crawl before I walk. I have the Alexa announcing my presence, but the on-off-sleep cycle of the wifi on the phone will need to be addressed. I’ll read up on the gpslogger component to see how that works. I’m also having trouble using the HADashboard as it can’t find my entities. Weird, but something to do with duckdns maybe.
Bart