Hello. I'm trying to transfer calls from an analog phone (Zap/1, TDM400P card) to some other terminal connected to my Asterisk PBX. If I make a flash hook pressing the phone hangup button quickly it works as expected, I get a new dialtone and the other side is put on hold. But I would like to use my phone's "R" key instead for some different reasons (it's quite easier to use in some of the phones we have here), and I can't get it to work properly. The problem: with the default values in zapata.conf, when I press the "R" key nothing happens. The other side of the communication hears a "click" but everything stays the same. I have found by trial and error (and in some docs after that) that the standard flash hook timing for my country (Spain) phone systems is 100ms. So, if I put rxflash=100 in Zap/1 channel configuration in zapata.conf (actually any value below 104) Asterisk detects when I press the "R" key, but instead of interpreting it as a flash hook it's interpreted as if I hung up the phone. I get a new dialtone but the other side gets disconnected, not on hold. It's just the same as if I hung up the phone for, say, 10 seconds. All values for rxflash above 104 cause de "R" key presses to be ignored, and below 104 it's the same as if I hung up the phone. I think I must increase the hang up detection time value (?) somewhere so that 100ms hang ups are actually interpreted as flash hooks, but I haven't been able to find out how to do it. I have tried with 3 different analog phones and it happens the same thing with all of them. Last thing: when rxflash is <= 104 and I press "R" so that the call is hung up, I'm getting the following message in the logs: WARNING[26002]: chan_zap.c:1418 zt_set_hook: zt hook failed: Device or resource busy Can anyone help me with this, please? Thanks a lot. Best regards, Fernando Sanchez
> All values for rxflash above 104 cause de "R" key presses to be ignored, and > below 104 it's the same as if I hung up the phone. I think I must increase > the hang up detection time value (?) somewhere so that 100ms hang ups are > actually interpreted as flash hooks, but I haven't been able to find out how > to do it.You should have found my post with the exact same problem over a year ago...> I have tried with 3 different analog phones and it happens the same > thing with all of them. Last thing: when rxflash is <= 104 and I press "R" > so that the call is hung up, I'm getting the following message in the logs:Yep, same thing for me...> WARNING[26002]: chan_zap.c:1418 zt_set_hook: zt hook failed: Device or resource busy > > Can anyone help me with this, please? Thanks a lot.Apply this patch: diff -ur zaptel/zaptel.h zaptel.mine/zaptel.h --- zaptel/zaptel.h Tue Sep 28 05:50:03 2004 +++ zaptel.mine/zaptel.h Fri Mar 11 13:29:00 2005 @@ -849,7 +849,7 @@ #define ZT_DEFAULT_PULSEAFTERTIME 750 /* 750ms between dial pulse digits */ #define ZT_MINPULSETIME (15 * 8) /* 15 ms minimum */ -#define ZT_MAXPULSETIME (150 * 8) /* 150 ms maximum */ +#define ZT_MAXPULSETIME (75 * 8) /* 75 ms maximum */ #define ZT_PULSETIMEOUT ((ZT_MAXPULSETIME / 8) + 50) #define ZT_RINGTRAILER (50 * 8) /* Don't consider a ring "over" until it's been gone at least this Watch out for the line wraps, might be best to apply it manually.... Then make clean, make install, and rmmod/insmod your kernel modules. It has worked fine for me ever since. Regards, Adam Adam Goryachev Website Managers Ph: +61 2 8304 0000 adam@websitemanagers.com.au Fax: +61 2 9345 4396 www.websitemanagers.com.au
> You should have found my post with the exact same problem over a year > ago...Oops. I think I found it but I thought "this patch is some months old; the problem must have been solved in upstream versions long ago". My fault.> Apply this patch: > diff -ur zaptel/zaptel.h zaptel.mine/zaptel.hI had to lower it from 200 to 50 instead of from 150 to 75, but it works fine now. Thanks a lot for your help. Best regards, Fernando Sanchez