[Asterisk-Dev] [patch] Choppy dial tone on Linksys routers / FPU usage in indications.c

Mike Taht mike.taht at gmail.com
Sun Oct 2 19:50:08 MST 2005


On 10/2/05, Andreas Klöckner <lists at informa.tiker.net> wrote:
>
> Hi there,
>
> here's a patch that switches tone generation in indications.c over from
> using
> actual floating point code to using a pregenerated sine table. This patch
> allows my poor FPU-less Linksys router to successfully play a dialtone
> with
> almost zero CPU usage.
>
> (If you care about the details: Generating the 8000-entry sine table at
> startup takes a bit more than a second on that machine, which is a MIPS
> using
> an FPU emulator. Since each sample out of playtones_generator() takes two
> sine evaluations and we're sampling at 8000Hz, the Linksys is too slow by
> about a factor of two.)
>
> This might even save some cycles on bigger setups. The patch applies
> cleanly
> and works on 1.0.x with x>=7, on 1.2.x it needs to be told where
> asterisk.h
> is, but otherwise seems to work fine.


Applause!

Dialtone generation is also a problem on even a 500 Mhz Xscale (which is
also fpu-less)

Andreas
>
>
> _______________________________________________
> Asterisk-Dev mailing list
> Asterisk-Dev at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-dev
> To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-dev
>
>
>


--
Mike Taht
PostCards From the Bleeding Edge
http://the-edge.blogspot.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-dev/attachments/20051002/acb0188b/attachment.htm


More information about the asterisk-dev mailing list