Hang up detection for incoming call

Hi all,
I have dial plan as below
exten => s,1,Answer
exten => s,2,Playtones(ring)
exten => s,3,NVFaxDetect(5)
exten => s,4,Macro(internalexten,1000,${HPHONE})

if incoming call is not fax, it dials my cordless phone, connected to fxs port. The problem I have is caller might have hang up before extension phone pick up the call. But asterisk will call the extension phone until it answer the call. How can i make asterisk to detect the hang up signal? So my dial plan will be while incoming call is active, call the extension number, otherwise hang up.

Thanks

what you need is disconnect supervision, this is provided by the company that provides you with dialtone.

voip-info.org/wiki-Asterisk+ … upervision

Also I have upgraded to the latest version of asterisk and zaptel and my setup seems to be handling disconnect supervision much better. Before I did not get it at all, now it is working, and my provider says they only put disconnect supervision on business lines(which I dont have)

Zaptel version = 1.4.10
Asterisk version =1.4.19