Skip to content

about "Could not convert Text-to-speech" #200

@zminde

Description

@zminde

When I used my phone to call the HA-SIP plugin on Home Assistant via the Docker version of Asterisk, I heard the voice prompt "Could not convert Text-to-speech". I suspect this is due to an incorrect TTS service configuration, but unfortunately, I haven't found a solution after checking the documentation and FAQs. Below are the plugin logs and settings screenshots; please point out where the problem lies.

"tts:
engine_id: tts.tts_emma
platform: ""
language: zh-CN-EmmaMultilingualNeural
voice: Emma
debug_print: false
webhook:
id: sip_call_webhook_id"

log:

| 21:59:50.241575 [ ] Webhook response 200 b''
| 21:59:50.255915 [ ] Sensor update sensor.sip_account_1: 200
| 21:59:50.256119 [ ] Calling webhook sip_call_webhook_id with data {'caller': 'sip:1002@192.168.0.230', 'called': 'sip:1010@192.168.0.242;ob', 'parsed_caller': '1002', 'parsed_called': '1010', 'sip_account': 1, 'call_id': 'bf55465b-1f53-46c3-9afa-262c1d2e0e09', 'internal_id': 'sip:1002@192.168.0.230', 'headers': {}, 'event': 'call_established'}
| 21:59:50.265633 [ ] Webhook response 200 b''
| 21:59:50.275388 [ ] Sensor update sensor.sip_account_1: 200
| 21:59:50.275562 [1] Playing message: 请è¾�å�¥å��ä½�å®�å�¨é�²ç��ç �
| 21:59:50.286169 [ ] Error getting tts file 500 b'500: Internal Server Error'
21:59:50.286 pjsua_aud.c Creating file player: /ha-sip/sound/error.wav..
21:59:50.286 wav_player.c .File player '/ha-sip/sound/error.wav' created: samp.rate=24000, ch=1, bufsize=4KB, filesize=132KB
21:59:50.286 conference.c ..Add port 2 (/ha-sip/sound/error.wav) queued
21:59:50.286 pjsua_aud.c .Player created, id=0, slot=2
21:59:50.286 pjsua_aud.c Conf connect: 2 --> 1
21:59:50.286 pjsua_aud.c .Set sound device: capture=-99, playback=-99, mode=0, use_default_settings=0
21:59:50.286 pjsua_aud.c ..Null sound device, mode setting is ignored
21:59:50.286 pjsua_aud.c ..Setting null sound device..
21:59:50.286 pjsua_aud.c ...Opening null sound device..
21:59:50.286 conference.c ..Connect ports 2->1 queued
| 21:59:50.286597 [1] No action supplied
21:59:50.305 conference.c !.Added port 1 (sip:1002@192.168.0.230), port count=2
21:59:50.305 conference.c .Added port 2 (/ha-sip/sound/error.wav), port count=3
21:59:50.305 conference.c .Port 2 (/ha-sip/sound/error.wav) transmitting to port 1 (sip:1002@192.168.0.230)
21:59:50.926 strm0x36ff4bb8 !VAD re-enabled
| 21:59:53.065953 [1] Playback done.
| 21:59:53.066058 [ ] Calling webhook sip_call_webhook_id with data {'caller': 'sip:1002@192.168.0.230', 'called': 'sip:1010@192.168.0.242;ob', 'parsed_caller': '1002', 'parsed_called': '1010', 'sip_account': 1, 'call_id': 'bf55465b-1f53-46c3-9afa-262c1d2e0e09', 'internal_id': 'sip:1002@192.168.0.230', 'headers': {}, 'event': 'playback_done', 'type': 'message', 'message': '请è¾�å�¥å��ä½�å®�å�¨é�²ç��ç �'}
| 21:59:53.075622 [ ] Webhook response 200 b''
21:59:53.075 conference.c .Remove port 2 queued
21:59:53.075 pjsua_aud.c Destroying player 0..
21:59:53.075 conference.c ..Remove port 2 queued
| 21:59:53.081270 [1] Scheduled post action: noop
21:59:53.086 conference.c !.Stop any transmission to port 2 (/ha-sip/sound/error.wav)
21:59:53.086 conference.c .Stop any transmission from port 2 (/ha-sip/sound/error.wav)
21:59:53.086 conference.c .Port 2 (/ha-sip/sound/error.wav) stop transmitting to port 1 (sip:1002@192.168.0.230)
21:59:53.086 conference.c .Removed port 2 (/ha-sip/sound/error.wav), port count=2
21:59:53.086 conference.c .Remove port failed: Invalid value or argument (PJ_EINVAL)
21:59:56.331 pjsua_core.c .RX 443 bytes Request msg BYE/cseq=5027 (rdata0x36fe9ce8) from UDP 192.168.0.230:5060:
BYE sip:1010@192.168.0.242:5060;ob SIP/2.0
Via: SIP/2.0/UDP 192.168.0.230:5060;rport;branch=z9hG4bKPj35c9ef30-ddb9-4a9d-94f9-45aa68e92b0a
From: sip:1002@192.168.0.230;tag=4b1626c1-8fc7-42a2-ab11-689c237cd7d3
To: sip:1010@192.168.0.242;ob;tag=eUG0Ip0bxEZtdQAKhe8Vax1-xR2V-Dso
Call-ID: bf55465b-1f53-46c3-9afa-262c1d2e0e09
CSeq: 5027 BYE
Reason: Q.850;cause=16
Max-Forwards: 70
User-Agent: Asterisk PBX 22.9.0
Content-Length: 0

--end msg--
21:59:56.331 pjsua_core.c .......TX 368 bytes Response msg 200/BYE/cseq=5027 (tdta0x36fd08f0) to UDP 192.168.0.230:5060:
SIP/2.0 200 OK
Via: SIP/2.0/UDP 192.168.0.230:5060;rport=5060;received=192.168.0.230;branch=z9hG4bKPj35c9ef30-ddb9-4a9d-94f9-45aa68e92b0a
Call-ID: bf55465b-1f53-46c3-9afa-262c1d2e0e09
From: sip:1002@192.168.0.230;tag=4b1626c1-8fc7-42a2-ab11-689c237cd7d3
To: sip:1010@192.168.0.242;ob;tag=eUG0Ip0bxEZtdQAKhe8Vax1-xR2V-Dso
CSeq: 5027 BYE
Content-Length: 0

--end msg--
21:59:56.331 pjsua_media.c ......Call 1: deinitializing media..
21:59:56.331 pjsua_media.c .......
[DISCONNECTED] To: sip:1002@192.168.0.230;tag=4b1626c1-8fc7-42a2-ab11-689c237cd7d3
Call time: 00h:00m:07s, 1st res in 44 ms, conn in 48ms
#0 audio PCMU @8khz, sendrecv, peer=192.168.0.230:11492
SRTP status: Not active Crypto-suite:
ICE role: Unknown, state: Candidate Gathering, comp_cnt: 2
RX pt=0, last update:00h:00m:01.525s ago
total 269pkt 43.0KB (53.8KB +IP hdr) @AvG=48.3Kbps/60.4Kbps
pkt loss=0 (0.0%), discrd=0 (0.0%), dup=0 (0.0%), reord=0 (0.0%)
(msec) min avg max last dev
loss period: 0.000 0.000 0.000 0.000 0.000
jitter : 1.250 33.029 59.125 33.125 8.985
TX pt=0, ptime=20, last update:00h:00m:01.023s ago
total 177pkt 28.3KB (35.4KB +IP hdr) @AvG=31.8Kbps/39.7Kbps
pkt loss=0 (0.0%), dup=0 (0.0%), reorder=0 (0.0%)
(msec) min avg max last dev
loss period: 0.000 0.000 0.000 0.000 0.000
jitter : 0.375 0.375 0.375 0.375 0.000
RTT msec : 1.144 1.144 1.144 1.144 0.000
21:59:56.331 conference.c .........Remove port 1 queued
21:59:56.331 strm0x36ff4bb8 ........Stream destroying
21:59:56.331 pjsua_media.c ........Media stream call01:0 is destroyed
21:59:56.331 icetp00 .......Stopping ICE, reason=media stop requested
21:59:56.331 srtp0x36fee340 .......Destroying SRTP transport
21:59:56.331 icetp00 .......Destroying ICE transport
| 21:59:56.331791 [1] Call disconnected
| 21:59:56.331877 [1] Calling additional webhook sip_call_webhook_id for event call_disconnected
| 21:59:56.331940 [ ] Calling webhook sip_call_webhook_id with data {'caller': 'sip:1002@192.168.0.230', 'called': 'sip:1010@192.168.0.242;ob', 'parsed_caller': '1002', 'parsed_called': '1010', 'sip_account': 1, 'call_id': 'bf55465b-1f53-46c3-9afa-262c1d2e0e09', 'internal_id': 'sip:1002@192.168.0.230', 'headers': {}, 'event': 'call_disconnected'}
| 21:59:56.341683 [ ] Webhook response 200 b''
21:59:56.346 conference.c !.Stop any transmission to port 1 (sip:1002@192.168.0.230)
21:59:56.346 conference.c .Stop any transmission from port 1 (sip:1002@192.168.0.230)
21:59:56.346 conference.c .Removed port 1 (sip:1002@192.168.0.230), port count=1
21:59:56.346 ice_session.c .ICE session 0x36fd2818 destroyed
21:59:56.346 icetp00 .ICE stream transport 0x36fd7ca8 destroyed
21:59:56.346 icetp00 .ICE transport destroyed
21:59:56.346 srtp0x36fee340 .SRTP transport destroyed
21:59:56.346 strm0x36ff4bb8 .Stream destroyed
| 21:59:56.354157 [ ] Sensor update sensor.sip_account_1: 200
| 21:59:56.367254 [ ] Sensor update sensor.sip_last_call_1: 200
| 21:59:56.367442 [ ] Calling webhook sip_call_webhook_id with data {'caller': 'sip:1002@192.168.0.230', 'called': 'sip:1010@192.168.0.242;ob', 'parsed_caller': '1002', 'parsed_called': '1010', 'sip_account': 1, 'call_id': 'bf55465b-1f53-46c3-9afa-262c1d2e0e09', 'internal_id': 'sip:1002@192.168.0.230', 'headers': {}, 'event': 'call_disconnected'}
| 21:59:56.381469 [ ] Webhook response 200 b''
| 21:59:56.392320 [ ] Sensor update sensor.sip_account_1: 200
| 21:59:56.404099 [ ] Sensor update sensor.sip_last_call_1: 200
| 21:59:56.404362 [ ] Remove from state: sip:1002@192.168.0.230
21:59:57.331 pjsua_aud.c Closing sound device after idle for 1 second(s)
21:59:57.331 pjsua_aud.c .Closing null sound device..

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions