esphome / media-players

This repo hosts known, tested devices that can server as media players to Home Assistant.
https://esphome.io/projects/?type=media
52 stars 22 forks source link

Silence when playing TTS mp3 from https:// source #20

Closed radek-kafka closed 1 year ago

radek-kafka commented 1 year ago

Hi.. I'm trying to use m5stack-atom-speaker-kit. When I sent TTS it is recorded in Log: Media URL: https://mypublicip.duckdns.org/api/tts_proxy/5bda927208c510b9f70ee9ab8b8eecb7b14852b4_en_-_google_translate.mp3

but silence .. not playing .. When running other mp3 from some source on the network it is fine: Media URL: http://icecast6.play.cz/cesky-impuls.mp3

Also could not combine with BT proxy in the same box : Image too big .. I have that this one has been reported already ..

Many thanks Radek

radek-kafka commented 1 year ago

Adding there a very-verbose log file: In 1st case it trying to play TTS output from 'https://anyabc.duckdns.org/api/tts_proxy/ea803aefedb3ddd6a0c90ed411863d3755404044_en_-_google_translate.mp3' 2nd case is the same file stored on local dlna server: http://192.168.88.30:8200/MediaItems/508.mp3

1st case is not playing (silence) .. 2nd is ok ...

INFO Reading configuration /config/esphome/m5stack-atom-speaker-kit.yaml... INFO Starting log output from m5stack-atom-speaker-kit.local using esphome API INFO Successfully connected to m5stack-atom-speaker-kit.local [14:46:41][I][app:102]: ESPHome version 2022.10.2 compiled on Nov 13 2022, 13:58:39

[14:46:41][C][wifi:360]: Local MAC: 4C:75:25:D6:75:C8 [14:46:41][C][wifi:361]: SSID: 'jumbas'[redacted] [14:46:41][C][wifi:362]: IP Address: 192.168.88.36 [14:46:41][C][wifi:364]: BSSID: 64:66:B3:FA:27:44[redacted]

[14:46:41][C][wifi:367]: Signal strength: -63 dB ▂▄▆█ [14:46:41][V][wifi:369]: Priority: 0.0 [14:46:41][C][wifi:371]: Channel: 1 [14:46:41][C][wifi:372]: Subnet: 255.255.255.0 [14:46:41][C][wifi:373]: Gateway: 192.168.88.1 [14:46:41][C][wifi:374]: DNS1: 192.168.88.1 [14:46:41][C][wifi:375]: DNS2: 0.0.0.0 [14:46:41][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2759652 (now=2764720) [14:46:41][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:46:41][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:46:41][VV][light.addressable:021]:

[14:46:41][C][logger:276]: Level: VERY_VERBOSE [14:46:41][C][logger:277]: Log Baud Rate: 115200 [14:46:41][C][logger:278]: Hardware UART: UART0 [14:46:41][C][gpio.binary_sensor:015]: GPIO Binary Sensor 'M5Stack Atom Speaker Kit Button' [14:46:41][C][gpio.binary_sensor:016]: Pin: GPIO39 [14:46:41][C][fastled:021]: FastLED light: [14:46:41][C][fastled:022]: Num LEDs: 1 [14:46:41][C][fastled:023]: Max refresh rate: 400

[14:46:41][C][light:106]: Default Transition Length: 1.0s [14:46:41][C][light:107]: Gamma Correct: 2.80 [14:46:41][C][captive_portal:088]: Captive Portal:

[14:46:41][C][mdns:101]: Hostname: m5stack-atom-speaker-kit

[14:46:41][V][mdns:104]: - _esphomelib, _tcp, 6053 [14:46:41][V][mdns:106]: TXT: version = 2022.10.2 [14:46:41][V][mdns:106]: TXT: mac = 4c7525d675c8 [14:46:41][V][mdns:106]: TXT: platform = ESP32 [14:46:41][V][mdns:106]: TXT: board = esp32dev [14:46:41][V][mdns:106]: TXT: network = wifi [14:46:41][V][mdns:106]: TXT: package_import_url = github://esphome/media-players/m5stack-atom-speaker-kit.yaml@main [14:46:41][C][ota:089]: Over-The-Air Updates: [14:46:41][C][ota:090]: Address: m5stack-atom-speaker-kit.local:3232 [14:46:41][C][ota:093]: Using Password. [14:46:41][C][api:138]: API Server: [14:46:41][C][api:139]: Address: m5stack-atom-speaker-kit.local:6053 [14:46:41][C][api:141]: Using noise encryption: YES

[14:46:46][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2764652 (now=2769652) [14:46:46][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:46:46][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:46:46][VV][light.addressable:021]:
[14:46:46][VV][esp-idf:000]: I (2770762) wifi:

[14:46:46][VV][esp-idf:000]:

[14:46:46][VV][api.service:689]: on_media_player_command_request: MediaPlayerCommandRequest { key: 378251292 has_command: NO command: MEDIA_PLAYER_COMMAND_PLAY has_volume: NO volume: 0 has_media_url: YES media_url: 'https://anyabc.duckdns.org/api/tts_proxy/ea803aefedb3ddd6a0c90ed411863d3755404044_en_-_google_translate.mp3' } [14:46:46][D][media_player:059]: 'M5Stack Atom Speaker Kit' - Setting [14:46:46][D][media_player:066]: Media URL: https://anyabc.duckdns.org/api/tts_proxy/ea803aefedb3ddd6a0c90ed411863d3755404044_en_-_google_translate.mp3 [14:46:50][VV][api.service:324]: send_media_player_state_response: MediaPlayerStateResponse { key: 378251292 state: MEDIA_PLAYER_STATE_PLAYING volume: 0.48 muted: NO } [14:46:50][V][component:199]: Component api took a long time for an operation (3.93 s). [14:46:50][V][component:200]: Components should block for at most 20-30ms. [14:46:50][VV][api.service:324]: send_media_player_state_response: MediaPlayerStateResponse { key: 378251292 state: MEDIA_PLAYER_STATE_IDLE volume: 0.48 muted: NO } [14:46:50][VV][api.service:470]: on_ping_request: PingRequest {} [14:46:50][VV][api.service:043]: send_ping_response: PingResponse {} [14:46:51][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2769652 (now=2774652) [14:46:51][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:46:51][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:46:51][VV][light.addressable:021]:
[14:46:55][VV][api.service:689]: on_media_player_command_request: MediaPlayerCommandRequest { key: 378251292 has_command: YES command: MEDIA_PLAYER_COMMAND_PLAY has_volume: NO volume: 0 has_media_url: NO media_url: '' } [14:46:55][D][media_player:059]: 'M5Stack Atom Speaker Kit' - Setting [14:46:55][D][media_player:063]: Command: PLAY [14:46:55][VV][api.service:324]: send_media_player_state_response: MediaPlayerStateResponse { key: 378251292 state: MEDIA_PLAYER_STATE_PLAYING volume: 0.48 muted: NO } [14:46:55][VV][esp-idf:000]: I (2779779) wifi:

[14:46:55][VV][esp-idf:000]:

[14:46:56][VV][api.service:470]: on_ping_request: PingRequest {} [14:46:56][VV][api.service:043]: send_ping_response: PingResponse {} [14:46:56][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2774652 (now=2779666) [14:46:56][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:46:56][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:46:56][VV][light.addressable:021]:
[14:47:01][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2779652 (now=2784656) [14:47:01][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:01][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:01][VV][light.addressable:021]:
[14:47:04][VV][esp-idf:000]: I (2788796) wifi:

[14:47:04][VV][esp-idf:000]:

[14:47:05][VV][api.service:470]: on_ping_request: PingRequest {} [14:47:05][VV][api.service:043]: send_ping_response: PingResponse {} [14:47:06][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2784652 (now=2789658) [14:47:06][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:06][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:06][VV][light.addressable:021]:
[14:47:11][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2789652 (now=2794652) [14:47:11][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:11][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:11][VV][light.addressable:021]:
[14:47:11][VV][api.service:470]: on_ping_request: PingRequest {} [14:47:11][VV][api.service:043]: send_ping_response: PingResponse {} [14:47:13][VV][api.service:689]: on_media_player_command_request: MediaPlayerCommandRequest { key: 378251292 has_command: YES command: MEDIA_PLAYER_COMMAND_PAUSE has_volume: NO volume: 0 has_media_url: NO media_url: '' } [14:47:13][D][media_player:059]: 'M5Stack Atom Speaker Kit' - Setting [14:47:13][D][media_player:063]: Command: PAUSE [14:47:13][VV][api.service:324]: send_media_player_state_response: MediaPlayerStateResponse { key: 378251292 state: MEDIA_PLAYER_STATE_PAUSED volume: 0.48 muted: NO } [14:47:13][VV][esp-idf:000]: I (2797814) wifi:

[14:47:13][VV][esp-idf:000]:

[14:47:15][VV][api.service:689]: on_media_player_command_request: MediaPlayerCommandRequest { key: 378251292 has_command: YES command: MEDIA_PLAYER_COMMAND_PLAY has_volume: NO volume: 0 has_media_url: NO media_url: '' } [14:47:15][D][media_player:059]: 'M5Stack Atom Speaker Kit' - Setting [14:47:15][D][media_player:063]: Command: PLAY [14:47:15][VV][api.service:324]: send_media_player_state_response: MediaPlayerStateResponse { key: 378251292 state: MEDIA_PLAYER_STATE_PLAYING volume: 0.48 muted: NO } [14:47:16][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2794652 (now=2799652) [14:47:16][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:16][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:16][VV][light.addressable:021]:
[14:47:21][VV][api.service:470]: on_ping_request: PingRequest {} [14:47:21][VV][api.service:043]: send_ping_response: PingResponse {} [14:47:21][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2799652 (now=2804666) [14:47:21][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:21][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:21][VV][light.addressable:021]:
[14:47:22][VV][api.service:689]: on_media_player_command_request: MediaPlayerCommandRequest { key: 378251292 has_command: YES command: MEDIA_PLAYER_COMMAND_PAUSE has_volume: NO volume: 0 has_media_url: NO media_url: '' } [14:47:22][D][media_player:059]: 'M5Stack Atom Speaker Kit' - Setting [14:47:22][D][media_player:063]: Command: PAUSE [14:47:22][VV][api.service:324]: send_media_player_state_response: MediaPlayerStateResponse { key: 378251292 state: MEDIA_PLAYER_STATE_PAUSED volume: 0.48 muted: NO } [14:47:22][VV][esp-idf:000]: I (2806832) wifi:

[14:47:22][VV][esp-idf:000]:

[14:47:26][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2804652 (now=2809652) [14:47:26][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:26][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:26][VV][light.addressable:021]:
[14:47:26][VV][api.service:470]: on_ping_request: PingRequest {} [14:47:26][VV][api.service:043]: send_ping_response: PingResponse {} [14:47:31][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2809652 (now=2814654) [14:47:31][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:31][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:31][VV][light.addressable:021]:
[14:47:31][VV][esp-idf:000]: I (2815850) wifi:

[14:47:31][VV][esp-idf:000]:

[14:47:34][VV][scheduler:196]: Running interval '' with interval=60000 last_execution=2757753 (now=2817756) [14:47:35][VV][api.service:689]: on_media_player_command_request: MediaPlayerCommandRequest { key: 378251292 has_command: NO command: MEDIA_PLAYER_COMMAND_PLAY has_volume: NO volume: 0 has_media_url: YES media_url: 'http://192.168.88.30:8200/MediaItems/508.mp3' } [14:47:35][D][media_player:059]: 'M5Stack Atom Speaker Kit' - Setting [14:47:35][D][media_player:066]: Media URL: http://192.168.88.30:8200/MediaItems/508.mp3 [14:47:35][VV][api.service:324]: send_media_player_state_response: MediaPlayerStateResponse { key: 378251292 state: MEDIA_PLAYER_STATE_PLAYING volume: 0.48 muted: NO } [14:47:35][V][component:199]: Component api took a long time for an operation (0.12 s). [14:47:35][V][component:200]: Components should block for at most 20-30ms. [14:47:36][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2814652 (now=2819652) [14:47:36][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:36][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:36][VV][light.addressable:021]:
[14:47:36][VV][api.service:470]: on_ping_request: PingRequest {} [14:47:36][VV][api.service:043]: send_ping_response: PingResponse {} [14:47:40][VV][esp-idf:000]: I (2824868) wifi:

[14:47:40][VV][esp-idf:000]:

[14:47:40][VV][api.service:324]: send_media_player_state_response: MediaPlayerStateResponse { key: 378251292 state: MEDIA_PLAYER_STATE_IDLE volume: 0.48 muted: NO } [14:47:40][V][component:199]: Component i2s_audio.media_player took a long time for an operation (0.05 s). [14:47:40][V][component:200]: Components should block for at most 20-30ms. [14:47:41][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2819652 (now=2824657) [14:47:41][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:41][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:41][VV][light.addressable:021]:
[14:47:41][VV][api.service:470]: on_ping_request: PingRequest {} [14:47:41][VV][api.service:043]: send_ping_response: PingResponse {} [14:47:46][VV][scheduler:196]: Running interval '' with interval=5000 last_execution=2824652 (now=2829658) [14:47:46][VV][light.addressable:015]: Addressable Light 'M5Stack Atom Speaker Kit' (effect_active=NO) [14:47:46][VV][light.addressable:019]: [ 0] Color: R= 0 G= 0 B= 0 W= 0 [14:47:46][VV][light.addressable:021]:

randybb commented 1 year ago

can you play that mp3 from the url by opening another browser and pasting it into it?

radek-kafka commented 1 year ago

can you play that mp3 from the url by opening another browser and pasting it into it?

Yes I can of course .. I do not understand why not playing..

radek-kafka commented 1 year ago

It looks like the version of esphome 2022.12.1 solved it ..