freeswitch / spandsp

SpanDSP is a low-level signal processing library that modulates and demodulates signals commonly used in telephony, such as the "noise" generated by a fax modem or DTMF touchpad.
Other
152 stars 120 forks source link

V.17 fixed point issues #53

Closed lexxer3d closed 11 months ago

lexxer3d commented 1 year ago

Hi!

I've found the following issues while testing V.17 14400 TCF with fax_decode tool when compiled with fixed point support:

  1. v17rx.c is missing SPANDSP_USE_FIXED_POINTx
  2. int32 overflow happens for s->training_error, long training threshold (line 961) and training succeeded threshold (line 1139).

Suggested fix with TCF sample is attached. v17_fixedp.zip

coppice-git commented 1 year ago

I have commited this change. I haven't really been keeping the fixed point stuff up to date, as nobody seemed to care about it. May I ask what platform you are using the fixed point code on? Do you have problems with the other modems? The last time I remember looking at the fixed point stuff I thought there were still multiple scaling issues in the modems.

lexxer3d commented 1 year ago

It's armv7l. Btw, even with the fix it doesn't work fine, so I switched to float point. Tried two different modems.

lexxer3d commented 11 months ago

Fixed in commit 239bf2f6.