diff options
author | markster <markster@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2005-12-03 00:47:43 +0000 |
---|---|---|
committer | markster <markster@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2005-12-03 00:47:43 +0000 |
commit | 7e199df2459226df742ad5f21959456c52336633 (patch) | |
tree | cf3c5f8a5719d77ba0f7b89ae1039a70fdd1e846 /wctdm24xxp.c | |
parent | 89e60dcfb9a56fe8e0525b3d9090102f8ff942b9 (diff) |
Support fast (25Hz) Ringer
git-svn-id: http://svn.digium.com/svn/zaptel/trunk@845 5390a7c7-147a-4af0-8ec9-7488f05a26cb
Diffstat (limited to 'wctdm24xxp.c')
-rw-r--r-- | wctdm24xxp.c | 38 |
1 files changed, 29 insertions, 9 deletions
diff --git a/wctdm24xxp.c b/wctdm24xxp.c index 4ed81f5..10a6a57 100644 --- a/wctdm24xxp.c +++ b/wctdm24xxp.c @@ -401,6 +401,7 @@ static int robust = 0; static int timingonly = 0; static int lowpower = 0; static int boostringer = 1; +static int fastringer = 0; static int _opermode = 0; static char *opermode = "FCC"; static int fxshonormode = 0; @@ -1992,15 +1993,32 @@ static int wctdm_init_proslic(struct wctdm *wc, int card, int fast, int manual, wctdm_setreg(wc, card, 1, 0x08); #endif - /* Beef up Ringing voltage to 89V */ - if (boostringer) { - if (wctdm_proslic_setreg_indirect(wc, card, 21, 0x1d1)) - return -1; - printk("Boosting ring power on slot %d (89V peak)\n", card + 1); - } else if (lowpower) { - if (wctdm_proslic_setreg_indirect(wc, card, 21, 0x108)) - return -1; - printk("Reducing ring power on slot %d (50V peak)\n", card + 1); + if (fastringer) { + /* Speed up Ringer */ + wctdm_proslic_setreg_indirect(wc, card, 20, 0x7e6d); + wctdm_proslic_setreg_indirect(wc, card, 21, 0x01b9); + /* Beef up Ringing voltage to 89V */ + if (boostringer) { + if (wctdm_proslic_setreg_indirect(wc, card, 21, 0x247)) + return -1; + printk("Boosting fast ringer on slot %d (89V peak)\n", card + 1); + } else if (lowpower) { + if (wctdm_proslic_setreg_indirect(wc, card, 21, 0x14b)) + return -1; + printk("Reducing fast ring power on slot %d (50V peak)\n", card + 1); + } else + printk("Speeding up ringer on slot %d (25Hz)\n", card + 1); + } else { + /* Beef up Ringing voltage to 89V */ + if (boostringer) { + if (wctdm_proslic_setreg_indirect(wc, card, 21, 0x1d1)) + return -1; + printk("Boosting ringer on slot %d (89V peak)\n", card + 1); + } else if (lowpower) { + if (wctdm_proslic_setreg_indirect(wc, card, 21, 0x108)) + return -1; + printk("Reducing ring power on slot %d (50V peak)\n", card + 1); + } } wctdm_setreg(wc, card, 64, 0x01); wc->mods[card].fxs.lasttxhook = 1; @@ -2850,6 +2868,7 @@ module_param(opermode, charp, 0600); module_param(timingonly, int, 0600); module_param(lowpower, int, 0600); module_param(boostringer, int, 0600); +module_param(fastringer, int, 0600); module_param(fxshonormode, int, 0600); module_param(battdebounce, int, 0600); module_param(battthresh, int, 0600); @@ -2869,6 +2888,7 @@ MODULE_PARM(opermode, "s"); MODULE_PARM(timingonly, "i"); MODULE_PARM(lowpower, "i"); MODULE_PARM(boostringer, "i"); +MODULE_PARM(fastringer, "i"); MODULE_PARM(fxshonormode, "i"); MODULE_PARM(battdebounce, "i"); MODULE_PARM(battthresh, "i"); |