rtl dongle output a 8bit unsigned interger for both I/Q signals.
To convert it to float man must remove the zero value.
A signed 8bit is normally between -128 and 127 so the convertion must be something like : I=(float)rtlinbuff[i++]-128.0; /* with rtlinbuff the input 8bit unsigned buffer */
Q=(float)rtlinbuff[i++]-128.0; /* and I/Q float values */

But, I try to find that 0 level by a very simple low pass filter. something like :
 IM=0.99999*IM+0.00001*(double)rtlinbuff[i++];
  QM=0.99999*QM+0.00001*(double)rtlinbuff[i++];

and after a few seconds of running with antenna disconnected , I find a value around 127.35 for a first dongle and 127.4 for a second.
I do some  differents runs and these values seem consistant.

So,
1)  is it something true with other dongles ?
2) Is it documented somewhere and I just discover what everybody knows ?
3) It will be interesting to modify rtl_test to show this value if it vary from one dongle to another.


Reply via email to