Hi,
So, my building has a Dahua VTO (VTO6521K-S2) that acts as the SIP server for ~60 apartments. They're pushing their Dahua VTHs and the Dahua remote app, which the intercom installer is used to, sets up in seconds with Dahua's proprietary protocols.
However, I have my smart home (Home Assistant), my own Crestron TSW-1060 panels, and my own ecosystem that I'd like to integrate their intercom into. And I don't want another mobile app or 1-function screen.
My end goal: Have a SIP client endpoint on my home server that registers to the building's VTO, and then from that local SIP client be able to forward the call to my Home Assistant app, the Crestron panels, etc.
I know people have gotten Asterisk to work as the SIP server connecting different Dahua VTOs and VTHs, but I can't find anything about connecting to the VTO (server) from an Asterisk client.
I bought a Dahua VTO to test things out and see if I can set it up (to then run the building guys through what I need). What I've tried:
What should I be looking at? How would you debug the problem? If there's a "simpler" test setup (eg. Asterisk as standalone, not as HA add-on), I could try that too. I'm happy to share logs and mess around with the system
Thanks so much! I've been banging my head against the wall for 2 weeks trying to figure this out. Searched everywhere, can't seem to find a solution that works. Hopefully this learned and experienced community can point out some obvious mistake I'm making
custom/pjsip_custom.conf:
custom/extensions_custom.conf:
So, my building has a Dahua VTO (VTO6521K-S2) that acts as the SIP server for ~60 apartments. They're pushing their Dahua VTHs and the Dahua remote app, which the intercom installer is used to, sets up in seconds with Dahua's proprietary protocols.
However, I have my smart home (Home Assistant), my own Crestron TSW-1060 panels, and my own ecosystem that I'd like to integrate their intercom into. And I don't want another mobile app or 1-function screen.
My end goal: Have a SIP client endpoint on my home server that registers to the building's VTO, and then from that local SIP client be able to forward the call to my Home Assistant app, the Crestron panels, etc.
I know people have gotten Asterisk to work as the SIP server connecting different Dahua VTOs and VTHs, but I can't find anything about connecting to the VTO (server) from an Asterisk client.
I bought a Dahua VTO to test things out and see if I can set it up (to then run the building guys through what I need). What I've tried:
- All internal networking, bridges, firewall rules, etc. for VMs set up
- Asterisk (HA add-on via SIP-HASS) installed and running
- Apartment created in VTO (type VTH, room 9901, Public registration, user/pass)
- Set up pjsip configs and extensions. These are successfully loaded (checked), and I included them below.
- When I pjsip send register vto-trunk-reg, it registers successfully (200 OK) and stays registered (from Asterisk's viewpoint)
What should I be looking at? How would you debug the problem? If there's a "simpler" test setup (eg. Asterisk as standalone, not as HA add-on), I could try that too. I'm happy to share logs and mess around with the system
Thanks so much! I've been banging my head against the wall for 2 weeks trying to figure this out. Searched everywhere, can't seem to find a solution that works. Hopefully this learned and experienced community can point out some obvious mistake I'm making
custom/pjsip_custom.conf:
YAML:
; ─── Outbound registration to the VTO acting as SIP server ──────────────
[vto-trunk-reg]
type = registration
outbound_auth = vto-trunk-auth
server_uri = sip:192.168.33.211
client_uri = sip:9901@192.168.33.211
retry_interval = 60
forbidden_retry_interval = 30
expiration = 300
[vto-trunk-auth]
type = auth
auth_type = userpass
username = 9901
password = <VTO_PASS>
; ─── AOR — where to send outbound INVITEs on this trunk ─────────────────
[vto-trunk]
type = aor
contact = sip:192.168.33.211
; ─── Endpoint — defines codecs + which dialplan context inbound calls
; from the VTO land in ────────────────────────────────────────────────
[vto-trunk]
type = endpoint
context = from-vto
disallow = all
allow = ulaw
allow = alaw
allow = h264
outbound_auth = vto-trunk-auth
aors = vto-trunk
direct_media = no
rtp_symmetric = yes
force_rport = yes
rewrite_contact = yes
dtmf_mode = rfc4733
; ─── Identify inbound traffic from the VTO IP as this endpoint ──────────
[vto-trunk]
type = identify
endpoint = vto-trunk
match = 192.168.33.211
custom/extensions_custom.conf:
YAML:
; Inbound calls from the VTO trunk land here. The VTO will send INVITE to
; 9901 (the apartment number). For now, ring a single hardcoded local
; extension — Phase 3 will replace this with multi-endpoint forking.
[from-vto]
exten => 9901,1,NoOp(Incoming call from VTO to apartment 9901)
same => n,Dial(PJSIP/100,30)
same => n,Hangup()
; Fallback — catch any other inbound dial number from the trunk
exten => _X.,1,NoOp(Unhandled VTO inbound: ${EXTEN})
same => n,Hangup()