DAHDI Hangup Detection Delay

Ive been trying to figure this out on my own but I can find a solution. I have a TDM1600 configured and my calls come in and out perfectly. Yet if someone calls and I dont answer it in time and they hangup prior to getting my voicemail my extention continues to ring for about 2 seconds. I find this really annoying. Any help would be great! Below is my log of a call I made. The call I placed was less then 5 seconds. Then I disconnected the call. As you can see it took asterisk longer to figure out it was disconnected. Any help would be great.
[2013-04-30 23:02:47] VERBOSE[4434] pbx.c: – Executing [[email protected]:37] GotoIf(“DAHDI/1-1”, “0?usegoto,1”) in new stack
[2013-04-30 23:02:47] VERBOSE[4434] pbx.c: – Executing [[email protected]:38] GotoIf(“DAHDI/1-1”, “1?godial”) in new stack
[2013-04-30 23:02:47] VERBOSE[4434] pbx.c: – Executing [[email protected]al-one:38] GotoIf(“DAHDI/1-1”, “1?godial”) in new stack
[2013-04-30 23:02:47] VERBOSE[4434] pbx.c: – Goto (macro-dial-one,s,42)
[2013-04-30 23:02:47] VERBOSE[4434] pbx.c: – Goto (macro-dial-one,s,42)
[2013-04-30 23:02:47] VERBOSE[4434] pbx.c: – Executing [[email protected]:42] Dial(“DAHDI/1-1”, “SIP/124,100,tr”) in new stack
[2013-04-30 23:02:47] VERBOSE[4434] pbx.c: – Executing [[email protected]:42] Dial(“DAHDI/1-1”, “SIP/124,100,tr”) in new stack
[2013-04-30 23:02:47] VERBOSE[4434] netsock2.c: == Using SIP RTP TOS bits 184
[2013-04-30 23:02:47] VERBOSE[4434] netsock2.c: == Using SIP RTP TOS bits 184
[2013-04-30 23:02:47] VERBOSE[4434] netsock2.c: == Using SIP RTP CoS mark 5
[2013-04-30 23:02:47] VERBOSE[4434] netsock2.c: == Using SIP RTP CoS mark 5
[2013-04-30 23:02:47] VERBOSE[4434] app_dial.c: – Called SIP/124
[2013-04-30 23:02:47] VERBOSE[4434] app_dial.c: – Called SIP/124
[2013-04-30 23:02:47] VERBOSE[4434] app_dial.c: – SIP/124-00000002 is ringing
[2013-04-30 23:02:47] VERBOSE[4434] app_dial.c: – SIP/124-00000002 is ringing
[2013-04-30 23:03:00] VERBOSE[4434] app_macro.c: == Spawn extension (macro-dial-one, s, 42) exited non-zero on ‘DAHDI/1-1’ in macro ‘dial-one’
[2013-04-30 23:03:00] VERBOSE[4434] app_macro.c: == Spawn extension (macro-dial-one, s, 42) exited non-zero on ‘DAHDI/1-1’ in macro ‘dial-one’
[2013-04-30 23:03:00] VERBOSE[4434] app_macro.c: == Spawn extension (macro-exten-vm, s, 14) exited non-zero on ‘DAHDI/1-1’ in macro ‘exten-vm’
[2013-04-30 23:03:00] VERBOSE[4434] app_macro.c: == Spawn extension (macro-exten-vm, s, 14) exited non-zero on ‘DAHDI/1-1’ in macro ‘exten-vm’
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: == Spawn extension (from-did-direct, 124, 2) exited non-zero on ‘DAHDI/1-1’
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: == Spawn extension (from-did-direct, 124, 2) exited non-zero on ‘DAHDI/1-1’
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Executing [[email protected]:1] Macro(“DAHDI/1-1”, “hangupcall,”) in new stack
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Executing [[email protected]:1] Macro(“DAHDI/1-1”, “hangupcall,”) in new stack
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Executing [[email protected]:1] GotoIf(“DAHDI/1-1”, “1?theend”) in new stack
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Executing [[email protected]:1] GotoIf(“DAHDI/1-1”, “1?theend”) in new stack
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Goto (macro-hangupcall,s,3)
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Goto (macro-hangupcall,s,3)
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Executing [[email protected]:3] ExecIf(“DAHDI/1-1”, “0?Set(CDR(recordingfile)=)”) in new stack
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Executing [[email protected]:3] ExecIf(“DAHDI/1-1”, “0?Set(CDR(recordingfile)=)”) in new stack
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Executing [[email protected]:4] Hangup(“DAHDI/1-1”, “”) in new stack
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: – Executing [[email protected]:4] Hangup(“DAHDI/1-1”, “”) in new stack
[2013-04-30 23:03:00] VERBOSE[4434] app_macro.c: == Spawn extension (macro-hangupcall, s, 4) exited non-zero on ‘DAHDI/1-1’ in macro ‘hangupcall’
[2013-04-30 23:03:00] VERBOSE[4434] app_macro.c: == Spawn extension (macro-hangupcall, s, 4) exited non-zero on ‘DAHDI/1-1’ in macro ‘hangupcall’
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: == Spawn extension (from-did-direct, h, 1) exited non-zero on ‘DAHDI/1-1’
[2013-04-30 23:03:00] VERBOSE[4434] pbx.c: == Spawn extension (from-did-direct, h, 1) exited non-zero on ‘DAHDI/1-1’
[2013-04-30 23:03:00] VERBOSE[4434] sig_analog.c: – Hanging up on ‘DAHDI/1-1’
[2013-04-30 23:03:00] VERBOSE[4434] sig_analog.c: – Hanging up on ‘DAHDI/1-1’
[2013-04-30 23:03:00] VERBOSE[4434] chan_dahdi.c: – Hungup ‘DAHDI/1-1’
[2013-04-30 23:03:00] VERBOSE[4434] chan_dahdi.c: – Hungup ‘DAHDI/1-1’

Analog and digital don’t mix well. This may be about the best you are going to get.

I doubt telco sends supervision that quickly once ring stops. DAHDI probably only detects the leading edge of the ring then samples.

You can look up DAHDI terms “answer supervision” and “disconnect supervision” and you will find some variables you can tweak that may help.

Asterisk has absolutely no part in hanging up a dahdi call, it is all the dahdi channel driver that does that, there are several hundred posts out there as to how BEST set up dahdi to catch a remote hangup on a PSTN line and it depends on your provider and your locale as some providers supply it in a timely fashion and some just don’t, further there are several ways of signaling on-hook from the far end, some are timely, some not so much, your’s apparently is in the “not so much” category or you have not yet optimized it yet to match that signaling. Ask your provider EXACTLY what “far end disconnect supervision” they provide then match in the best fashion your dahdi channels.