[Asterisk-Users] RX/TXgain on bristuff/zaptel ?

Pisac pisacc at gmail.com
Wed Jan 18 19:15:11 MST 2006


I compiled it, and it's WORKING. 
Thanks.

But, I would realy realy realy like that somebody explain to me how is exactly that bug hidden in those two segments? Where is difference? 
Anybody?

1)
if (!IS_DIGITAL(ast->transfercapability)) {
set_actual_gain(p->subs[SUB_REAL].zfd, 0, p->rxgain, p->txgain, p->law); 
} else { 
set_actual_gain(p->subs[SUB_REAL].zfd, 0, 0, 0, p->law); }   

2)
if (IS_DIGITAL(ast->transfercapability)) {
set_actual_gain(p->subs[SUB_REAL].zfd, 0, 0, 0, p->law); 
} else {
set_actual_gain(p->subs[SUB_REAL].zfd, 0, p->rxgain, p->txgain, p->law); }   







----- Original Message ----- 
From: "Koopmann, Jan-Peter" <Jan-Peter.Koopmann at seceidos.de>

> You are right, only outgoing calls!
> I found lines that you mentioned, but I do not understand where is
> difference? In current chan_zap.c I read: 
> 
> if (!IS_DIGITAL(ast->transfercapability)) {
> set_actual_gain(p->subs[SUB_REAL].zfd, 0, p->rxgain, p->txgain,
> p->law); } else { set_actual_gain(p->subs[SUB_REAL].zfd, 0, 0, 0,
> p->law); }   
> 
> And your suggestion is:
> 
> if (IS_DIGITAL(ast->transfercapability)) {
> set_actual_gain(p->subs[SUB_REAL].zfd, 0, 0, 0, p->law); } else {
> set_actual_gain(p->subs[SUB_REAL].zfd, 0, p->rxgain, p->txgain,
> p->law); }   
> 
> Which is the same thing but invertedly written. I'm not a programmer,
> so I may be wrong (maybe IS_DIGITAL could be NULL), but I would like
> to understand difference in those two segments.  

I know. It sounds crazy. Trust me though. Somehow the original does not work. This fix is from the bristuff developer himself and it does work.

Regards,
  JP
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060118/43b4bcc1/attachment.htm


More information about the asterisk-users mailing list