diff options
author | markster <markster@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2004-06-21 21:54:15 +0000 |
---|---|---|
committer | markster <markster@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2004-06-21 21:54:15 +0000 |
commit | 8ad434c95444cf438845f57b2c63ba4114ee1e5e (patch) | |
tree | 42b146e72e6d1744374adad33a4d746b2821a708 /wctdm.c | |
parent | 80df834f1ee899277641d62f50e3ab3b10808f13 (diff) |
Add special check for R19 calibration
git-svn-id: http://svn.digium.com/svn/zaptel/trunk@417 5390a7c7-147a-4af0-8ec9-7488f05a26cb
Diffstat (limited to 'wctdm.c')
-rwxr-xr-x | wctdm.c | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -810,6 +810,7 @@ static int wcfxs_proslic_powerleak_test(struct wcfxs *wc, int card) static int wcfxs_powerup_proslic(struct wcfxs *wc, int card, int fast) { unsigned char vbat; + unsigned char r19; unsigned long origjiffies; /* Set period of DC-DC converter to 1/64 khz */ @@ -845,6 +846,13 @@ static int wcfxs_powerup_proslic(struct wcfxs *wc, int card, int fast) /* Engage DC-DC converter */ wcfxs_setreg(wc, card, 93, 0x99 /* was 0x19 */); + r19 = wcfxs_getreg(wc, card, 107); + if ((r19 < 0x2) || (r19 > 0xd)) { + if (debug) + printk("DC-DC cal has a surprising direct 107 of 0x%02x!\n", r19); + wcfxs_setreg(wc, card, 107, 0x8); + } + #if 0 origjiffies = jiffies; while(0x80 & wcfxs_getreg(wc, card, 93)) { |