I believe the two folders need to be separate You can’t combine them into one. One should be a temporary folder and then the other one should be your output folder
No luck
This is my setup which works fine
Heres my setup which works fine:
And I have this for my public folders in my configuration file:
homeassistant:
allowlist_external_dirs:
- "/config/www/tmp"
- "/media"
- "/config/www/chime_tts"
Hi Michael, sorry you’ve been having this issue.
Using the chime_tts.say_url
service with notify.alexa_media
should work, but since v1.0.0 you can simply use chime_tts.say
and specify your Alexa media_player, which should simplify your script.
It’s not clear which service is throwing the Message malformed: extra keys not allowed @ data['sequence']
error. It would be helpful to see the debug logs to determine where this error occurs.
To debug the problem I suggest you call chime_tts.say
via the Services
tab in the Developer tools
page, that way you will be able to tell if the issue is related to Chime TTS. If not, it’s likely an issue with your scipt.
Either way: the debug logs are the best way for me to understand what the issue might be.
Hi Steffen, sorry to hear you’re experiencing this issue.
Thank you for the debug logs. Unfortunately they don’t reveal any clues, as they indicate that the correct steps were taken by Chime TTS.
My best guess as to what is causing the issue, is that after fading out and pausing the playing music, the Chime TTS audio announcement replaces the paused music, so there isn’t anything to resume.
Could you try setting the announce
parameter to true
? I am curious if that might fix the issue. Eg:
service: chime_tts.say
data:
chime_path: ding_dong
offset: 450
final_delay: 100
message: Hallo dies ist ein Test
tts_platform: edge_tts
volume_level: 0.6
fade_audio: true
announce: true
target:
entity_id: media_player.sonos_buero
Hi Dave, this issue looks like it might be related to Steffen’s post.
Could you please review my response and also try to see if setting announce
to true
addresses the issue?
Hi @Desert_AIP, I think the issue you’re having of the blank audio from Amazon Polly is due to an incorrect/missing configuration for the Amazon Polly platform in your Home Assistant instance, as these errors indicate that Chime TTS wasn’t able to find it in the list of installed TTS platforms.
Have you been able to successfully use the Amazon Polly TTS platform outside of Chime TTS, i,e with the tts.amazon_polly_say
service?
Hi Robert, sorry to hear you’re unable to join the speakers together.
I don’t see any issues with your YAML. Can you please provide me with the debug log messages so that I might be able to see where the issue might be?
Hi @stormshaker, thank you for your kind words, I appreciate the support!
- Cache doesn’t work for me, it throws an Unknown Error. I’m using a rPi4 with HASSOS.
I suggest you try installing the latest beta version (v1.1.0-beta4) and see if it addresses the issue.
If you still expereince the issue on the beta then please provide me with your debug log messages so that I might be able to see what the issue is.
- …music continues playing 100% for another 1 second, then music volume returns to 15%.
For this issue I would again ask you to send me your debug log messages as it’s difficult to tell what could be causing the issue without any additionhal information.
Hi Chrisandsally, you’re the first to report this issue as far as I know - and it’s always a good idea to provide debug logs
It’s hard to understand what might be causing the issue, so please send me the debug logs and i’ll try to see what might be the cause.
Hi Coolie, I agree with @ColtonYYZ that the issue for your missing playback is related to the folder path you have defined for temporary TTS audio files. You are trying to play audio files from a folder that is not inside your media
direcotry (/config/tts
).
Try changing this path to /media/tts
(or any subfolder inside of the /media
folder).
Is it mandatory that it be in the media folder?
I believe so. Try changing the path and see if it makes a difference.
Weird because I have been using /config/tts for years
How have you been using it?
Thanks for getting back to me. I setup a script with the following YAML;
alias: Chime TTS Test
sequence:
- service: logger.set_level
data:
custom_components.chime_tts: debug
- service: chime_tts.say
target:
entity_id:
- media_player.breakfast_sonos
- media_player.kitchen_sonos
- media_player.livingroom_sonos
- media_player.roam_sl_sonos
- media_player.workshop_sonos
data:
chime_path: fanfare
message: This is a test
tts_platform: tts.google_en_com
join_players: true
unjoin_players: true
mode: single
Monitoring execution of the script in the SONOS application, I see an audio file received and played by the breakfast_sonos speaker. None of the other speakers are joined together prior to the message being played. I tried running the script a couple of times.
Log entries follow;
2024-05-07 17:35:31.214 WARNING (SyncWorker_2) [homeassistant.loader] We found a custom integration chime_tts which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-05-07 17:46:58.882 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Called. Version v1.1.0-beta4 -----
2024-05-07 17:46:58.882 DEBUG (MainThread) [custom_components.chime_tts.queue_manager] Adding service call to queue
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] ----- General Parameters -----
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * entity_ids:
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 0: media_player.roam_sl_sonos
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 1: media_player.workshop_sonos
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 2: media_player.kitchen_sonos
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 3: media_player.livingroom_sonos
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 4: media_player.breakfast_sonos
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * chime_path = fanfare
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * cache = False
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * offset = 450.0
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * final_delay = 0.0
2024-05-07 17:46:58.890 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * media_players_array:
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 0: {'entity_id': 'media_player.roam_sl_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 1: {'entity_id': 'media_player.workshop_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 2: {'entity_id': 'media_player.kitchen_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 3: {'entity_id': 'media_player.livingroom_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 4: {'entity_id': 'media_player.breakfast_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * message = This is a test
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * tts_platform = tts.google_en_com
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * tts_speed = 100.0
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * tts_pitch = 0
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * announce = False
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * fade_audio = False
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * volume_level = -1
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * join_players = True
2024-05-07 17:46:58.891 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * unjoin_players = True
2024-05-07 17:46:58.892 DEBUG (MainThread) [custom_components.chime_tts] - Retrieving audio from path: "custom_components/chime_tts/mp3s/fanfare.mp3"...
2024-05-07 17:46:59.581 DEBUG (MainThread) [custom_components.chime_tts] ...audio retrieved. Duration: 3.515s
2024-05-07 17:46:59.582 DEBUG (MainThread) [custom_components.chime_tts] - Generating new TTS audio with parameters:
2024-05-07 17:46:59.582 DEBUG (MainThread) [custom_components.chime_tts] * tts_platform = 'tts.google_en_com'
2024-05-07 17:46:59.582 DEBUG (MainThread) [custom_components.chime_tts] * message = 'This is a test'
2024-05-07 17:46:59.583 DEBUG (MainThread) [custom_components.chime_tts] * cache = False
2024-05-07 17:46:59.583 DEBUG (MainThread) [custom_components.chime_tts] * language = None
2024-05-07 17:46:59.583 DEBUG (MainThread) [custom_components.chime_tts] * options = {}
2024-05-07 17:47:00.452 DEBUG (MainThread) [custom_components.chime_tts] ...TTS audio generated in 870.0ms
2024-05-07 17:47:00.460 DEBUG (MainThread) [custom_components.chime_tts] - Saving mp3 file to folder: /media/sounds/temp/chime_tts/...
2024-05-07 17:47:00.751 DEBUG (MainThread) [custom_components.chime_tts.helpers.filesystem] - File saved to path: /media/sounds/temp/chime_tts/6ipc12at.mp3
2024-05-07 17:47:00.982 DEBUG (MainThread) [custom_components.chime_tts] - Chime TTS audio generated:
2024-05-07 17:47:00.983 DEBUG (MainThread) [custom_components.chime_tts] - audio_duration = 5.357
2024-05-07 17:47:00.983 DEBUG (MainThread) [custom_components.chime_tts] - local_path = "/media/sounds/temp/chime_tts/6ipc12at.mp3"
2024-05-07 17:47:00.983 DEBUG (MainThread) [custom_components.chime_tts] - public_path = None
2024-05-07 17:47:00.983 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id = "media-source://media_source/local/sounds/temp/chime_tts/6ipc12at.mp3"
2024-05-07 17:47:00.983 DEBUG (MainThread) [custom_components.chime_tts] *** Pre-Playback Actions ***
2024-05-07 17:47:00.983 WARNING (MainThread) [custom_components.chime_tts] Unable to join speakers. 0 supported media_players found (minimum is 2).
2024-05-07 17:47:00.983 DEBUG (MainThread) [custom_components.chime_tts] *** Chime TTS playback ***
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] 5 Sonos media players detected:
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] - media_player.roam_sl_sonos
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.roam_sl_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] - media_player.workshop_sonos
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.workshop_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] - media_player.kitchen_sonos
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.kitchen_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] - media_player.livingroom_sonos
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.livingroom_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] - media_player.breakfast_sonos
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.breakfast_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:47:00.984 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:47:00.985 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:47:00.985 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/6ipc12at.mp3
2024-05-07 17:47:00.985 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:47:00.987 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:47:00.987 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:47:00.987 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/6ipc12at.mp3
2024-05-07 17:47:00.987 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:47:00.988 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:47:00.989 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:47:00.989 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/6ipc12at.mp3
2024-05-07 17:47:00.989 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:47:00.990 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:47:01.004 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:47:01.004 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/6ipc12at.mp3
2024-05-07 17:47:01.004 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:47:01.017 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:47:01.017 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:47:01.017 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/6ipc12at.mp3
2024-05-07 17:47:01.017 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:47:01.029 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:47:01.029 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:47:01.029 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/6ipc12at.mp3
2024-05-07 17:47:01.029 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:47:01.034 DEBUG (MainThread) [custom_components.chime_tts] - Waiting 5.357s for audio playback to complete...
2024-05-07 17:47:06.396 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] - Waiting until 5 media_players aren't playing...
2024-05-07 17:47:06.396 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.roam_sl_sonos
2024-05-07 17:47:06.396 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.kitchen_sonos
2024-05-07 17:47:06.597 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.workshop_sonos
2024-05-07 17:47:06.799 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.livingroom_sonos
2024-05-07 17:47:07.000 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.breakfast_sonos
2024-05-07 17:47:07.001 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Completed in 8.11 s -----
2024-05-07 17:48:03.803 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Called. Version v1.1.0-beta4 -----
2024-05-07 17:48:03.803 DEBUG (MainThread) [custom_components.chime_tts.queue_manager] Adding service call to queue
2024-05-07 17:48:03.807 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] ----- General Parameters -----
2024-05-07 17:48:03.807 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * entity_ids:
2024-05-07 17:48:03.807 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 0: media_player.roam_sl_sonos
2024-05-07 17:48:03.807 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 1: media_player.workshop_sonos
2024-05-07 17:48:03.807 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 2: media_player.kitchen_sonos
2024-05-07 17:48:03.807 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 3: media_player.livingroom_sonos
2024-05-07 17:48:03.807 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 4: media_player.breakfast_sonos
2024-05-07 17:48:03.807 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * chime_path = fanfare
2024-05-07 17:48:03.807 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * cache = False
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * offset = 450.0
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * final_delay = 0.0
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * media_players_array:
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 0: {'entity_id': 'media_player.roam_sl_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 1: {'entity_id': 'media_player.workshop_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 2: {'entity_id': 'media_player.kitchen_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 3: {'entity_id': 'media_player.livingroom_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] - 4: {'entity_id': 'media_player.breakfast_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * message = This is a test
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * tts_platform = tts.google_en_com
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * tts_speed = 100.0
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * tts_pitch = 0
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * announce = False
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * fade_audio = False
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * volume_level = -1
2024-05-07 17:48:03.808 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * join_players = True
2024-05-07 17:48:03.809 DEBUG (MainThread) [custom_components.chime_tts.helpers.helpers] * unjoin_players = True
2024-05-07 17:48:03.809 DEBUG (MainThread) [custom_components.chime_tts] - Retrieving audio from path: "custom_components/chime_tts/mp3s/fanfare.mp3"...
2024-05-07 17:48:04.059 DEBUG (MainThread) [custom_components.chime_tts] ...audio retrieved. Duration: 3.515s
2024-05-07 17:48:04.061 DEBUG (MainThread) [custom_components.chime_tts] - Generating new TTS audio with parameters:
2024-05-07 17:48:04.061 DEBUG (MainThread) [custom_components.chime_tts] * tts_platform = 'tts.google_en_com'
2024-05-07 17:48:04.061 DEBUG (MainThread) [custom_components.chime_tts] * message = 'This is a test'
2024-05-07 17:48:04.061 DEBUG (MainThread) [custom_components.chime_tts] * cache = False
2024-05-07 17:48:04.061 DEBUG (MainThread) [custom_components.chime_tts] * language = None
2024-05-07 17:48:04.062 DEBUG (MainThread) [custom_components.chime_tts] * options = {}
2024-05-07 17:48:04.280 DEBUG (MainThread) [custom_components.chime_tts] ...TTS audio generated in 220.0ms
2024-05-07 17:48:04.288 DEBUG (MainThread) [custom_components.chime_tts] - Saving mp3 file to folder: /media/sounds/temp/chime_tts/...
2024-05-07 17:48:04.583 DEBUG (MainThread) [custom_components.chime_tts.helpers.filesystem] - File saved to path: /media/sounds/temp/chime_tts/s2lkndde.mp3
2024-05-07 17:48:04.832 DEBUG (MainThread) [custom_components.chime_tts] - Chime TTS audio generated:
2024-05-07 17:48:04.833 DEBUG (MainThread) [custom_components.chime_tts] - audio_duration = 5.357
2024-05-07 17:48:04.833 DEBUG (MainThread) [custom_components.chime_tts] - local_path = "/media/sounds/temp/chime_tts/s2lkndde.mp3"
2024-05-07 17:48:04.833 DEBUG (MainThread) [custom_components.chime_tts] - public_path = None
2024-05-07 17:48:04.833 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id = "media-source://media_source/local/sounds/temp/chime_tts/s2lkndde.mp3"
2024-05-07 17:48:04.833 DEBUG (MainThread) [custom_components.chime_tts] *** Pre-Playback Actions ***
2024-05-07 17:48:04.833 WARNING (MainThread) [custom_components.chime_tts] Unable to join speakers. 0 supported media_players found (minimum is 2).
2024-05-07 17:48:04.834 DEBUG (MainThread) [custom_components.chime_tts] *** Chime TTS playback ***
2024-05-07 17:48:04.835 DEBUG (MainThread) [custom_components.chime_tts] 5 Sonos media players detected:
2024-05-07 17:48:04.835 DEBUG (MainThread) [custom_components.chime_tts] - media_player.roam_sl_sonos
2024-05-07 17:48:04.836 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.roam_sl_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:04.836 DEBUG (MainThread) [custom_components.chime_tts] - media_player.workshop_sonos
2024-05-07 17:48:04.836 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.workshop_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:04.836 DEBUG (MainThread) [custom_components.chime_tts] - media_player.kitchen_sonos
2024-05-07 17:48:04.836 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.kitchen_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:04.836 DEBUG (MainThread) [custom_components.chime_tts] - media_player.livingroom_sonos
2024-05-07 17:48:04.837 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.livingroom_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:04.837 DEBUG (MainThread) [custom_components.chime_tts] - media_player.breakfast_sonos
2024-05-07 17:48:04.837 DEBUG (MainThread) [custom_components.chime_tts] sonos_media_player_dict = {'entity_id': 'media_player.breakfast_sonos', 'platform': 'sonos', 'should_change_volume': False, 'initial_volume_level': 0.01, 'playback_volume_level': -1, 'group_members_supported': True, 'announce_supported': True, 'is_playing': False}
2024-05-07 17:48:04.837 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:48:04.837 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:48:04.837 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/s2lkndde.mp3
2024-05-07 17:48:04.838 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:48:04.846 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:48:04.846 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:48:04.846 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/s2lkndde.mp3
2024-05-07 17:48:04.846 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:48:04.848 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:48:04.848 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:48:04.848 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/s2lkndde.mp3
2024-05-07 17:48:04.848 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:48:04.851 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:48:04.852 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:48:04.852 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/s2lkndde.mp3
2024-05-07 17:48:04.852 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:48:04.853 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:48:04.853 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:48:04.853 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/s2lkndde.mp3
2024-05-07 17:48:04.853 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:48:04.855 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media with data:
2024-05-07 17:48:04.855 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2024-05-07 17:48:04.855 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/s2lkndde.mp3
2024-05-07 17:48:04.855 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: ['media_player.breakfast_sonos']
2024-05-07 17:48:04.871 DEBUG (MainThread) [custom_components.chime_tts] - Waiting 5.357s for audio playback to complete...
2024-05-07 17:48:10.243 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] - Waiting until 5 media_players aren't playing...
2024-05-07 17:48:10.243 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.roam_sl_sonos
2024-05-07 17:48:10.243 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.kitchen_sonos
2024-05-07 17:48:10.444 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.workshop_sonos
2024-05-07 17:48:10.646 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.livingroom_sonos
2024-05-07 17:48:10.848 DEBUG (MainThread) [custom_components.chime_tts.helpers.media_player] ✔ media_player.breakfast_sonos
2024-05-07 17:48:10.849 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Completed in 7.04 s -----
Here’s an image of the SONOS App prior to running the script.
Here’s an image of the SONOS App after running the script.
You can see that Breakfast SONOS played the chime and the message however no other SONOS speakes were joined with it.
Via a script with multiple automations.
You may want to review how the media source works in Home Assistant
If you want to use the folder /config/tts
you will need to ensure that this path is included in media_source
in your configuration.yaml file.
I just released a new beta release, v1.1.0-beta 5 with the following:
Improvements:
- Converted included chime paths to absolute file paths
Bugfixes:
- Fix for incorrect label for the 4th custom chime in the dropdown UI
- Fix for downloading chime audio files
- Fixes for joined media_players (eg: Sonos)
- Fix to prevent original chime files from being overwritten by
audio_conversion
To install the new beta version:
- Open the Chime TTS repository in HACS
- Click on the
⋮
button in the top right - Select the
↻ Redownload
option - Enable the
Show beta versions
option (it may take a moment to update the list) - Select version
v1.1.0-beta5
from the updated version drop-down list - Restart Home Assistant