[asterisk-dev] [Code Review] Invalid test for rxisoffhook in FXO channels

Tilghman Lesher tlesher at digium.com
Wed Jul 21 01:37:06 CDT 2010


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/699/#review2438
-----------------------------------------------------------

Ship it!


Looks good here.

- Tilghman


On 2010-06-10 10:15:04, Tzafrir Cohen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/699/
> -----------------------------------------------------------
> 
> (Updated 2010-06-10 10:15:04)
> 
> 
> Review request for Asterisk Developers.
> 
> 
> Summary
> -------
> 
> One bit passed in the DAHDI ioctl DAHDI_GET_PARAMS is rxisoffhook. Originally only intended to tell if a channel is or isn't off-hook. But it is (ab?)used to provide some more information: it should also be set for an analog FXO port that gets no battery current from its remote CO. Newer analog FXO drivers provide that specific information through a red channel alarm. Which prevents an outgoing call anyway.
> 
> An FXS device may be off-hook and still not accept calls - when you pick up the phone to dial, you don't want to allow another call to be generated from that line.
> 
> I'm not really sure why some of the FXO channels (KS and GS, but not LS) check rxisoffhook. I tried to schedule a call right at the end of an existing call but so far failed. The rationale above, that "off hook" stands in some cases for "has no battery" seems odd, as it applies just the same to LS.
> 
> Thus the suggested change is to behave in FXO Kewl-Start the same as in the case of FXO Loop-start (unless the user #define-d DAHDI_CHECK_HOOKSTATE in the code. I leave this as a #define rather than a run-time definition as I have not yet heard of someone who actually uses it.
> 
> I have used the 1.6.2 variant of this (see bug report) for quite some time (in Debian and Elastix packages) and they seem to work well.
> 
> 
> This addresses bug 14577.
>     https://issues.asterisk.org/view.php?id=14577
> 
> 
> Diffs
> -----
> 
>   /trunk/channels/chan_dahdi.c 269271 
>   /trunk/channels/sig_analog.c 269271 
> 
> Diff: https://reviewboard.asterisk.org/r/699/diff
> 
> 
> Testing
> -------
> 
> Lightly tested with soem analog devices in trunk. More thoroughly tested (in some real-world uses) in the 1.6.2 variant.
> 
> 
> Thanks,
> 
> Tzafrir
> 
>




More information about the asterisk-dev mailing list