I believe so, yes. Never use doorpi…
If on the same (android?) phone if you use chrome, does it work?
Yes, in Chrome Browser on my Samsung Phone it works without any Problem.
I’am wonder if it is WebRTC in generell where the Problem is, because the custom WebRTC Camera Plugin for my Cams for example works well on the Android App. But for sure, without audio Support…
@greengolfer, good evening man…
i’m using a forked version of the code shared from @wmaker , in a “custom/generic sip doorphone”, but i’m struggling on WHERE can i put the code to send DTMF codes from the card to the doorphone (it accept DTMF codes during call time to trigger relays)
Can you help me out?
my code is here: doorvivint-card/doorvivint-card.js at 15a5bc3cc41bd31c6b44dd0d181e37e7d82f2666 · augustodinizl/doorvivint-card · GitHub
I know that i can send DTMF codes with sipjs since i’s on documentation of the library (here: JsSIP - JsSIP.RTCSession)
TIA
Sorry, I haven’t got a clue.
As explained, my understanding of javascript is close to nil.
What I think I understand from line 184 in the script you have the various events. I would imagine that there you would need to display something on screen eg. buttons and when pressed sent the dtmf using jssip.
At the moment, the events are sent to HA:
hass.callService('input_boolean', 'turn_off', { entity_id: 'input_boolean.doorphone_ringing' });
I guess it should be something like that.
But as I said, javascript and I are not friends
Sorry!
Thanks for the tip dude, i got it working after some days, i’m working on the “internationalization” of the code and writing the instructions to release it to the public… but it’s working now
@Augusto_Diniz_Lisboa
Did you get this to work?
Can you provide me some information for the whole project? I have some troubles with configuring the Asterisk server…
I want to integrate my 2N SIP intercom with Home Assistant.
Or @greengolfer maybe you can provide some more information?
In the 1st post, you have what is required on asterisk. What are your troubles?
Hi @greengolfer,
i have installed the whole guide, but i run into the issue that the HA does not ring and the asterisk throw 503 unavailable.
Meanwhile simML5 work with both way calling and i can speak both ways. I am using a wildcard SSL cert with proxy Nginx and everything in Dockers.
There is no JavaScript error and the Web-socket connect correctly showing " SIPPhone registered with SIP Server", but when i try to call 503 unavailable.
Can you help?
Maybe… But with so little info, no.
503 unavailable is usually when the extension is not there.
Try putting debug on asterisk to see the PJSIP registration and what happens when you try to call the lovelace card.
So, first of all, allow me to explain my setup. I am using an Rpi4 with ubuntu server. All the services like homeassistant, freepbx(asterisk), turn/stun server, … are installed inside docker containers. Also for networking for the docker containers, i am using macvlan and also a bridge macvlan from host to containers to allow local communication.
Now, onto the freepbx(asterisk) part. This are the logs from pjsip debug. But if i do use sipML5 with stun/turn server it works as intended. See image bellow.
My guess is that the networking setup prevents the doordroid card to register on asterisk. However, I have no experience with this kind of setup (docker, stun server,…) so I might be completely wrong.
You could try making things simpler by eg. running asterisk in “host” mode or directly on the server.
I understand that the screenshot are from SIPML5. You are putting there ICE server, something you can’t do with the doordroid card.
I took a look at your log, it looks like the error SIP 488 Not Acceptable Here
along with the couldn't negotiate stream
has to do with the codec negotiation. However I don’t see any pjsip debug messages with your webrtc client.
I’m getting “no endpoint found for extension x” for the pjsip extension for HA.
I’m also fairly new to Asterisk…
So maybe if you have some documentation or something for this?
Or some ready to use config files?
My understanding is that the doordroid card doesn’t register. So extension x exists, but, no sip phone there.
Again, my assumption is that your network setup prevents the card to register properly. Any way to try a simpler setup?
Through freepbx you can configure (almost) everything. The extensions config on post #1 are copied from pjsip.endpoint.conf but you shouldn’t change them by end. So difficult to really share that.
Hi Greengolfer,
My setup is working now, but it’s only working for about 10-15 minutes.
After this the webgui becomes unavailable and the 8089/ws page is also not responding.
Ping is also not working.
The cli via console keeps working and is responsive.
My freepbx is running on vmware.
Do you have any idea for this?
Thanks
Not sure what the webgui here is…
When loosing connection to the tablet, usually, it is because your android tablet/phone is disabling the wifi to save battery. So, no wifi, no connection… I don’t know which browser you use on the tablet. Fully kiosk is quite good at keeping the wifi on. You could for example request the API every 5 minutes to prevent the tablet to fall asleep.
Sorry for my bad explaination.
I mean the webgui of freepbx.
My freepbx becomes unavailable after some time, sometimes it works 15mins after reboot, sometimes only 3 minutes…
I’m running this on vmware, and there the console stays responsive, but the webgui and ws page + ping are down.
Again… not sure what is ws page!!
freepbx/asterisk are two very reliable software. So, there is something “wrong” in your configuration/environment. No clue what it can be…
Hi Greengolfer,
Thanks for helping me out.
Everything is working right now!
Just one more thing, the cameraview is not refreshing.
I only see a snapshot of the camera.
Is this normal?
No. It should stream the live view…