TECH7Fox / sip-hass-card

A SIP client inside home assistant!
MIT License
179 stars 38 forks source link

No Audio at all during calls #110

Open theDontKnowGuy opened 10 months ago

theDontKnowGuy commented 10 months ago

First and foremost, this project is awesome. Thank you for developing and maintaining it. I installed the Asterisk add-on, configured the SSL (whoof), and installed the card addon alongside the integration. Everything works. Calls are being initiated, ring tone sounds, answered on the other end, and hung up as expected, EXCEPT there is no audio whatsoever, neither from the browser (one end) to the comp. App on the other. I did see the permission requests and later, the mic icon on the browser/iPhone during a call, but again no audio.

Not sure it is related but: My setup is that I have a cloudflare integration to support Amazon alexa so my SSL is on their server. The Cloudflare integration installs a small vir. network interface in (probably reverse proxy) in HA. So the certificate was created with a local IP address while the A record points to name with an external IP they hold. That said, the browser trusts their certificate and shows a Secure Connection message.

Log looks clear to me.

Thanks!

Configurations and log attached. ami_password: "1234" auto_add: true auto_add_secret: "1234" video_support: true generate_ssl_cert: false certfile: HAfullchain.pem keyfile: HAprivkey.pem additional_sounds: [] mailbox: false mailbox_port: 12345 mailbox_password: Tutim123HA mailbox_extension: "100" mailbox_google_api_key: "" log_level: info

`type: custom:sipjs-card server: home.gideoni.work port: '8089' video: true auto_answer: false hide_me: true state_color: true custom_title: Gphone ringtone: /local/ringtone.mp3 ringbacktone: /local/backtone.mp3 button_size: '62' custom:

[Oct 28 15:36:04] == Endpoint 101 is now Reachable [Oct 28 15:36:05] == WebSocket connection from '192.168.1.46:60126' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] -- Added contact 'sip:lben9q0o@192.168.1.46:60126;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60134' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60133' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60138' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60137' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60135' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60136' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] -- Added contact 'sip:75fiv2fc@192.168.1.46:60134;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60139' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60140' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] -- Added contact 'sip:r6kls4gv@192.168.1.46:60138;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Added contact 'sip:p9qs2heq@192.168.1.46:60133;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Added contact 'sip:h5vf9oir@192.168.1.46:60137;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Added contact 'sip:2afhib1h@192.168.1.46:60135;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:0anb49oq@192.168.1.46:60117;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60144' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == Contact 101/sip:0anb49oq@192.168.1.46:60117;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60142' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60141' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60143' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] -- Added contact 'sip:oqsd1dfc@192.168.1.46:60136;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:h5vf9oir@192.168.1.46:60137;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == Contact 101/sip:h5vf9oir@192.168.1.46:60137;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] == WebSocket connection from '192.168.1.30:54642' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60145' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.30:54643' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] -- Added contact 'sip:r9bt9ugb@192.168.1.30:54642;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0' to AOR '100' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:8eagcpl2@192.168.1.30:54620;transport=ws;x-ast-orig-host=kmsgdpd7gk7i.invalid:0' from AOR '100' due to remove existing [Oct 28 15:36:06] == Contact 100/sip:8eagcpl2@192.168.1.30:54620;transport=ws;x-ast-orig-host=kmsgdpd7gk7i.invalid:0 has been deleted [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60146' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60147' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] == WebSocket connection from '192.168.1.46:60148' for protocol 'sip' accepted using version '13' [Oct 28 15:36:06] -- Added contact 'sip:h25hvleo@192.168.1.46:60139;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:2afhib1h@192.168.1.46:60135;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == Contact 101/sip:2afhib1h@192.168.1.46:60135;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] -- Added contact 'sip:qleeh8hs@192.168.1.30:54643;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0' to AOR '100' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:q0jno2ea@192.168.1.30:54622;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0' from AOR '100' due to remove existing [Oct 28 15:36:06] == Contact 100/sip:q0jno2ea@192.168.1.30:54622;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0 has been deleted [Oct 28 15:36:06] -- Added contact 'sip:7kifmgoe@192.168.1.46:60142;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:r6kls4gv@192.168.1.46:60138;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == Contact 101/sip:r6kls4gv@192.168.1.46:60138;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] -- Added contact 'sip:9jlfp8ts@192.168.1.46:60144;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:lben9q0o@192.168.1.46:60126;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == Contact 101/sip:lben9q0o@192.168.1.46:60126;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] -- Added contact 'sip:g5bic6lq@192.168.1.46:60141;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:9jlfp8ts@192.168.1.46:60144;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == Contact 101/sip:9jlfp8ts@192.168.1.46:60144;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] -- Added contact 'sip:ie1394ol@192.168.1.46:60140;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:g5bic6lq@192.168.1.46:60141;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] -- Added contact 'sip:vu4el1f0@192.168.1.46:60143;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:ie1394ol@192.168.1.46:60140;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == Contact 101/sip:g5bic6lq@192.168.1.46:60141;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] == Contact 101/sip:ie1394ol@192.168.1.46:60140;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] -- Added contact 'sip:v0rproqg@192.168.1.46:60148;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:vu4el1f0@192.168.1.46:60143;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == Contact 101/sip:vu4el1f0@192.168.1.46:60143;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] -- Added contact 'sip:et42akak@192.168.1.46:60145;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:v0rproqg@192.168.1.46:60148;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] -- Added contact 'sip:scp1ufs3@192.168.1.46:60146;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:et42akak@192.168.1.46:60145;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == Contact 101/sip:v0rproqg@192.168.1.46:60148;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] == Contact 101/sip:et42akak@192.168.1.46:60145;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:06] -- Added contact 'sip:9e2cp5pp@192.168.1.46:60147;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' to AOR '101' with expiration of 600 seconds [Oct 28 15:36:06] -- Removed contact 'sip:oqsd1dfc@192.168.1.46:60136;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0' from AOR '101' due to remove existing [Oct 28 15:36:06] == Contact 101/sip:oqsd1dfc@192.168.1.46:60136;transport=ws;x-ast-orig-host=5p6n71cp0bh0.invalid:0 has been deleted [Oct 28 15:36:11] -- Executing [100@default:1] Dial("PJSIP/101-00000000", "PJSIP/100/sip:oe1rs7p2@192.168.1.30:54621;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0&PJSIP/100/sip:dqeap8ed@192.168.1.30:54623;transport=ws;x-ast-orig-host=ie0ijsb4l1ff.invalid:0&PJSIP/100/sip:qleeh8hs@192.168.1.30:54643;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0&PJSIP/100/sip:plakgpjc@192.168.1.30:54638;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0&PJSIP/100/sip:c3oqu637@192.168.1.30:54624;transport=ws;x-ast-orig-host=25bf84j89fqr.invalid:0&PJSIP/100/sip:r9bt9ugb@192.168.1.30:54642;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0") in new stack [Oct 28 15:36:11] -- Called PJSIP/100/sip:oe1rs7p2@192.168.1.30:54621;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0 [Oct 28 15:36:11] -- Called PJSIP/100/sip:dqeap8ed@192.168.1.30:54623;transport=ws;x-ast-orig-host=ie0ijsb4l1ff.invalid:0 [Oct 28 15:36:11] -- Called PJSIP/100/sip:qleeh8hs@192.168.1.30:54643;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0 [Oct 28 15:36:11] -- Called PJSIP/100/sip:plakgpjc@192.168.1.30:54638;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0 [Oct 28 15:36:11] -- Called PJSIP/100/sip:c3oqu637@192.168.1.30:54624;transport=ws;x-ast-orig-host=25bf84j89fqr.invalid:0 [Oct 28 15:36:11] -- Called PJSIP/100/sip:r9bt9ugb@192.168.1.30:54642;transport=ws;x-ast-orig-host=f2mj4ibkaj28.invalid:0 [Oct 28 15:36:11] -- PJSIP/100-00000005 connected line has changed. Saving it until answer for PJSIP/101-00000000 [Oct 28 15:36:11] -- PJSIP/100-00000004 connected line has changed. Saving it until answer for PJSIP/101-00000000 [Oct 28 15:36:11] -- PJSIP/100-00000002 connected line has changed. Saving it until answer for PJSIP/101-00000000 [Oct 28 15:36:11] -- PJSIP/100-00000006 connected line has changed. Saving it until answer for PJSIP/101-00000000 [Oct 28 15:36:11] -- PJSIP/100-00000003 connected line has changed. Saving it until answer for PJSIP/101-00000000 [Oct 28 15:36:11] -- PJSIP/100-00000001 connected line has changed. Saving it until answer for PJSIP/101-00000000 [Oct 28 15:36:11] -- PJSIP/100-00000005 is ringing [Oct 28 15:36:11] -- PJSIP/100-00000002 is ringing [Oct 28 15:36:11] -- PJSIP/100-00000004 is ringing [Oct 28 15:36:11] -- PJSIP/100-00000006 is ringing [Oct 28 15:36:11] -- PJSIP/100-00000003 is ringing [Oct 28 15:36:11] -- PJSIP/100-00000001 is ringing [Oct 28 15:36:15] -- Call on PJSIP/100-00000004 placed on hold [Oct 28 15:36:15] -- Started music on hold, class 'default', on channel 'PJSIP/101-00000000' [Oct 28 15:36:15] -- PJSIP/100-00000004 answered PJSIP/101-00000000 [Oct 28 15:36:15] -- Stopped music on hold on PJSIP/101-00000000 [Oct 28 15:36:15] -- Channel PJSIP/100-00000004 joined 'simple_bridge' basic-bridge <e8963e03-e49c-4a35-b6fe-ff0d80c64e35> [Oct 28 15:36:15] -- Channel PJSIP/101-00000000 joined 'simple_bridge' basic-bridge <e8963e03-e49c-4a35-b6fe-ff0d80c64e35> [Oct 28 15:36:23] -- Channel PJSIP/101-00000000 left 'simple_bridge' basic-bridge <e8963e03-e49c-4a35-b6fe-ff0d80c64e35> [Oct 28 15:36:23] -- Channel PJSIP/100-00000004 left 'simple_bridge' basic-bridge <e8963e03-e49c-4a35-b6fe-ff0d80c64e35> [Oct 28 15:36:23] == Spawn extension (default, 100, 1) exited non-zero on 'PJSIP/101-00000000'

TECH7Fox commented 10 months ago

Hi @theDontKnowGuy,

Can you share the browser logs when making the call?

Also, maybe try pc to pc first. Maybe it's only a problem on your phone.

theDontKnowGuy commented 10 months ago

Thanks for the quick replay. I have been testing in further, iPhone to iPhone worked great. iPhone to browser (ARC) didn’t work (as described) but to Chrome worked well. So, since i am using Arc, which is Mac only, niche browser i had the issue but i don’t think this is something that should be a real issue and we can put it to rest.

in the Arc logs i didn’t see anything fishy.

FRIGATE-HASS-CARD Version 5.2.0 sipjs-card.ts:714 Connecting to wss://home.gideoni.work:8089/ws sipjs-card.ts:748 ICE config: undefined sipjs-card.ts:753 SIP-Card Registered with SIP Server sipjs-card.ts:776 Call: newRTCSession: Originator: remote sipjs-card.ts:843 ICE gathering timeout: 5 seconds sipjs-card.ts:928 Call: peerconnection(incoming) sipjs-card.ts:872 Call: peerconnection: mediatrack event: kind: audio sipjs-card.ts:876 Call: peerconnection: mediatrack event: number of associated streams: 1 - using first stream sipjs-card.ts:872 Call: peerconnection: mediatrack event: kind: video sipjs-card.ts:876 Call: peerconnection: mediatrack event: number of associated streams: 1 - using first stream sipjs-card.ts:861 ICE: gathering state changed: gathering sipjs-card.ts:861 ICE: gathering state changed: complete sipjs-card.ts:864 ICE: candidate gathering complete. Cancelling ICE application timeout timer... sipjs-card.ts:815 Call accepted. Originator: local sipjs-card.ts:801 Call confirmed. Originator: remote

On 29 Oct 2023, at 18:42, Jordy Kuhne @.***> wrote:

Hi @theDontKnowGuy https://github.com/theDontKnowGuy,

Can you share the browser logs when making the call?

Also, maybe try pc to pc first. Maybe it's only a problem on your phone.

— Reply to this email directly, view it on GitHub https://github.com/TECH7Fox/sip-hass-card/issues/110#issuecomment-1784163030, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJW32XNANWKSXORRI22WXH3YBZ2OBAVCNFSM6AAAAAA6UB6CE6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTOOBUGE3DGMBTGA. You are receiving this because you were mentioned.