[linux-dvb] [PATCH] cx24123 (NOVA S plus) signal strengh reporting
romain.degez at smartjog.com
Thu Jan 12 12:12:04 CET 2006
Sigmund Augdal Helberg wrote:
>>Moreover I do not understand the need of a signed value in our case (AGC accumulator).
>>A negative value should be nonsense and the precision of the positive value is /2 compared
>>to an unsigned one.
> I do not understand this either. It is possible that the register only
> handles 8 bit signed values and the manufaturers decided that the
> interval [-127 127] was better than having only [0 127]. This would also
> make sense considering the comment stating larger is better, but not
> saying anything about the absolute origin of the value.
>>>*signal_strength = (cx24123_readreg(state, 0x3b)+0x80) << 8; /* larger =
>>>This would turn the number into an unsigned.
>>Wow. Are you sure of this ?
>>By doing this you add 1000000 to the return value (say 0x23 so 00100011).
>>So now we have 10100011. Look like a negative value in 2's complement format ?
>>I'm lost here :-)
> at this point we are working in maching native ints ie. 32 or 64 bit. So
> 10100011 is actually 00000000000000000000000010100011, so a positive
> value in 2's complement format.
You are right I forget this point.
>>Anyway by doing this, I have:
>>FE: Hauppauge Nova-S-Plus CX24123/CX24109 (SAT)
>>signal%: 63| snr%: 00
>>status 1f| signal a300| snr 0000| ber 003fffff| unc 003fffff| FE_HAS_LOCK
>>The signal value (63%) is still very different from what I should have (~70%).
> But much closer than what you had, right? Anyway, could you try these
> three methods (original way, your change and my change) under different
> signal conditions. That would be interresting to see the dynamics of
> things. For instance try to find these values when the cable is
I'll try differents things (our 3 methods, cable plugged or not and maybe a longer cable to
obtain a small decrease in the signal strength).
Moreover maybe the register (3A) that set the value we should obtain by reading the 3B register
is not set correctly but by reading the specs, everythings seems OK to me (but i'm very far to
be an expert in DVB internals...)
I'll try this right now and keep you posted.
>>I wasn't aware of such things (1's and 2's complement format) until yesterday
>>so anyway I learnt something here :-)
> I learnt this at school some years back, but you know school teachings,
> doesn't really stick.
Romain DEGEZ, System and Network Administrator
16 Place de la République, 75010 Paris, FRANCE
Phone : +22.214.171.124.63.19
Fax : +126.96.36.199.64.05
Mobile : +188.8.131.52.65.21
romain.degez at smartjog.com
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 189 bytes
Desc: OpenPGP digital signature
Url : http://www.linuxtv.org/pipermail/linux-dvb/attachments/20060112/2f775b90/signature.pgp
More information about the linux-dvb