Can't get tts to work. (new user)

In the config file named entity_registry.yaml, the installation created the following entry:

media_player.d_office_speaker:
  name:
  platform: cast
  unique_id: 23c75b47-0aaf-feab-00d9-596fa0f0d52c

There is no other reference to it. The speaker is a Google Home Mini and not attached to anything other than the wifi network.

google cast audio and video will not show or display on frontend if it is off (not connected to network).

To get the best result of the media player if you can put ip address in the configuration. also put discovery: in configuration.

media_player:
  - platform: cast
    host: 192.168.1.10 <-- optional

Once you have set up media player and also discovery in configuration. Try put # in front of every line of old media_player.d_office_speaker. Then restart your HA.

Name of the cast device can be done in customize later.

Once Restart, with your cast device also has to be turn on. You would be able to check this media player for entity_id.

If you media player doesn’t show up on front end. put it in group so it can be seen on frontend.

Thanks, I will try. But I have question…

When I click the “ON” button on the frontend media_player entry for this Google Home (D Office speaker), I immediately hear a chirp from the Home and it displays its state as Idle. It appears from your explanation that this would not happen if it was not being correctly discovered. Am I correct?

It is normal that it show idle as it connected to network. So your media player display on frontend. Click on that media player it will pop up another window. On this popup window there is an input text that you can type anything for this media player to speak out.

Click where on the media player? On the Play button? I have clicked on all buttons, menus and sub-menus on the media player and the only item with an input field asks me to rename the item.

Please indicate exactly which and where to click to get to the “text so say” field. Thanks!

You see the three dot on your media player?

Look at this post. there is picture. Article 4.1

Yes I see. I have tried that (the “menu”) and this is what I get:

X                                *
D Office Speaker               Idle
2 min ago    Default Media Receiver

The * is the Gear Icon. When I click that I get:

<-  D Office speaker           SAVE
   Name
  __________________________

Which I have assumed is asking for a new Name for the speaker.

Please advise…

For the name you can give your speaker name. To test the tts is here

I see, but the dialog box titled “Bluetooth Speaker” and the input field titled “Text to speak” DOES NOT SHOW UP. Only the “Name Speaker” field I described.

Just the picture to show you. That picture default speaker name is bluetooth speaker.

So did you have tts in your configuration

tts:
  - platform: google
    cache: true
    cache_dir: /tmp/tts
    time_memory: 300

Yes, I have

# Text to speech
tts:
  - platform: google
    cache: true
    cache_dir: /tmp/tts

I am missing time_memory as the default is fine.

Since you have both google home mini as well. Can you test to check tts to google mini? Click on google mini on ha frontend to check if you can use tts.

The “D Office speaker” device IS the Google Home Mini. That is the device I am referring to from the beginning. I.e., there is no “both”. The Google Home Mini is named “D Office”. It is discovered as a media player speaker by HA.

I see. I thought it is chromecast audio. not the google home mini.

on HA side. Delete your old config also from entity_registry file. Put new one as follow;

http:
  base_url: http://ha-ipaddress:8123 <=== with ha port
  api_password: YOUR_PASSWORD

media_player:
  - platform: cast
    name: D Office Speaker <== once you put this, the entity_id of this media player will be media_player.d_office_speaker
    host: 192.168.1.10 <== put your google home mini ip address here.

discovery:

tts:
  - platform: google
    cache: true
    cache_dir: /tmp/tts
    time_memory: 300

Once you have put this Check your config from configuration menu and restart you HA with your google home mini turn on (connected to same network)

Once restart, Your new found media player also will be in known_devices.yaml file Change to match the name and also put the mac address of your google home mini.

In known_devices.yaml

00044bxxxxxx:  <== mac address of new device found
  hide_if_away: false
  mac: 00:04:4B:xx:xx:xx  <== put google mini mac address
  name: 00044bxxxxxx  <== give it a name
  picture:
  track: true
  vendor: 

On front end. You will see media player. You can test tts again follow the picture aboved.

Also in your router you have to port forward to 8123

Wow, that’s a lot of reconfig, especially since I have 5 Google Home devices and 6 other speaker devices. All of them have the same issue (by-the-way). None of them work with tts (2 chromecast audio, two shield tv’s). I actually suspect something more basis is wrong, but will let you know the results.

Is it a bug that HA does not configure them correctly in the first place?

I will set it up according to your instructions later tonight. Thanks so much for all your help!

If you config wrongly, it won’t work. So use the default config. HA knows google mini by entity_id, mac address and ip address. If you cannot fix ip address for you google mini then move away the host. HA will learn from entity_id for each devices instead.
So when you use media player component example

media_player:
  - platform: cast
    name: D Office Speaker <== once you put this, the entity_id of this media player will be media_player.d_office_speaker
    host: 192.168.1.10 <== put your google home mini ip address here.

  - platform: cast
    name: name2 <== once you put this, the entity_id of this media player will be media_player.name2
    host: 192.168.1.11 <== put your google home mini ip address here.

  - platform: cast
    name: name3 <== once you put this, the entity_id of this media player will be media_player.name3
    host: 192.168.1.12 <== put your google home mini ip address here.

in known_devices.yaml will be display by mac address of each devices.

I am saying I DID use the default config. I did nothing else but add caching to the tts entry. HA did the rest. Why doesn’t HA configure Google Home’s correctly on initial activation? Or not configure them at all?

Does everybody with a Google Home have to go through this to use HA with GHome and tts?

  1. If you put discovery: and enable device_tracker especially nmap tracker (local network). Any device connect to the same network will be discover and put in known_devices.yaml

  2. known_devices.yaml disocovered devices from mac address but not the name so you have to change it accrodingly. This is good to track family member and devices you want to track the status.

  3. For your privacy. You don’t want anything to be discovered in your network just #discovery:

  4. Even you don’t put any setting for cast component. But you have nmap tracker and discovery: All devices will be found in known_devices.yaml but of course not as media player.

If you put discovery: and enable device_tracker especially nmap tracker (local network). Any device connect to the same network will be discover and put in known_devices.yaml

My discovery: is not commented out.  I did not uncomment it.  It came uncommented.

known_devices.yaml disocovered devices from mac address but not the name so you have to change it accrodingly. This is good to track family member and devices you want to track the status.

There was/is no known_devices.yaml file in my config directory (I just discovered).
 Don't know why?

For your privacy. You don’t want anything to be discovered in your network just #discovery:

 My network is local and behind a firewall.

Even you don’t put any setting for cast component. But you have nmap tracker and discovery: All devices will be found in known_devices.yaml but of course not as media player.




No known_devices.yaml because you didn’t use nmap

devices discovery from nmap will be in known_devices.yaml