Hello,<br><br><div class="gmail_quote">On Mon, Feb 1, 2010 at 9:34 PM, Dan Amarandei <span dir="ltr">&lt;<a href="mailto:dan.amarandei@gmail.com">dan.amarandei@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I am trying to force an fxs dahdi channel to slin. I see that<br>
DAHDI_SETLINEAR sets the DAHDI_FLAG_LINEAR in chan-&gt;flags in<br>
dahdi-base.c but I am not sure how to force chan_dandi.conf or<br>
dahdi/system.conf to switch to it, </blockquote><div><br>Cannot be done through system.conf or chan_dahdi.conf settings, it&#39;s most a programming decision depending on the situation (each time dahdi_write is called with a linear frame or the rawreadformat is changed to linear by Asterisk).<br>
<br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">and secondly if that was done I don&#39;t<br>
see how DAHDI_FLAG_LINEAR affects anything in the existing DAHDI drivers<br>
for TDM400P (the driver I am working on is based on the same chipset). I<br>
know that the fax apps somehow force DAHDI to slin so I hope this is<br>
possible. meetme seems to do it for the pseudo channel which probably<br>
won&#39;t help.<br></blockquote><br>Look into dahdi-base.c, you can see how DAHDI_FLAG_LINEAR will cause transcoding from ulaw/alaw to slinear before returning a read buffer to user space (dahdi_chan_read) and before pushing down buffers to hardware (dahdi_chan_write).<br>
<br>It&#39;s probably better for you to describe why is that you want to set the read/write format in the dahdi channel to linear in order to get some help.<br></div><br>-- <br>Moises Silva<br>Senior Software Engineer<br>
Sangoma Technologies Inc. | 50 McIntosh Drive, Suite 120, Markham ON L3R 9T3 Canada<br>t. 1 905 474 1990 x 128 | e. <a href="mailto:moy@sangoma.com">moy@sangoma.com</a><br>