On Tue, 2012-04-24 at 23:07 -0400, Brian J. Murrell wrote:
> On 12-04-24 06:42 PM, Andy Walls wrote:

> > Run 'femon' on the cx18's dvb frontend when you have a live QAM capture
> > ongoing.
> 
> OK.  Ran it all evening during the evening capture window.  Started it
> at 20:30, sharp to coincide with the evening's recording from that card
> also starting at 20:30 sharp.  Here's where it found anomalies:
> 
> $ nl /var/tmp/femon.out | grep -v "| ber 00000000 | unc 00000000 |"

grepping out the 0 lines doesn't let one see the trends in Signal to
Noise Ratio (SNR) before and after the uncorrectable (unc) block counts.

> So you can see, since femon prints an output line each second, the
> number on the left is the seconds since 20:30 and we are looking
> for any line showing a ber or unc that is non-zero:

Cool.

First. note the following about the s5h1409 driver for the CX24227 (aka
S5H109) QAM/8VSB demodulator:

a. the Bit Eror Rate (BER) as returned by the driver is bogus; ignore
it.  It is just a copy of the uncorrectable block count.

b. The "signal" level is a software computed value based on the SNR
value. Ignore "signal" as redundant information.

c. The Signal to Noise Ratio (SNR) should be a hexadecimal value with
units of 1/10th of a deciBel (0.1 dB)  (centiBels?).
E.g. 0x13a => 314 => 31.4 dB
I believe Steven calibrated this value to SNR at the RF input of the
HVR-1600. (Steven or Devin, correct me if I am wrong.)

>      1        FE: Samsung S5H1409 QAM/8VSB Frontend (ATSC)
>     67        status SCVYL | signal 013a | snr 013a | ber 00000198 | unc 
> 00000198 | FE_HAS_LOCK
>    313        status SCVYL | signal 013c | snr 013c | ber 0000026b | unc 
> 0000026b | FE_HAS_LOCK
>    457        status SCVYL | signal 013a | snr 013a | ber 0000026e | unc 
> 0000026e | FE_HAS_LOCK
>    802        status SCVYL | signal 013c | snr 013c | ber 00000265 | unc 
> 00000265 | FE_HAS_LOCK
>   1093        status SCVYL | signal 013a | snr 013a | ber 0000014b | unc 
> 0000014b | FE_HAS_LOCK
>   1184        status SCVYL | signal 013a | snr 013a | ber 000001ca | unc 
> 000001ca | FE_HAS_LOCK
>   1192        status SCVYL | signal 013a | snr 013a | ber 00000267 | unc 
> 00000267 | FE_HAS_LOCK
>   1385        status SCVYL | signal 013c | snr 013c | ber 0000025d | unc 
> 0000025d | FE_HAS_LOCK
>   1435        status SCVYL | signal 013c | snr 013c | ber 00000268 | unc 
> 00000268 | FE_HAS_LOCK
>   1511        status SCVYL | signal 013c | snr 013c | ber 0000026c | unc 
> 0000026c | FE_HAS_LOCK
>   1657        status SCVYL | signal 013a | snr 013a | ber 0000026a | unc 
> 0000026a | FE_HAS_LOCK
>   1693        status SCVYL | signal 013a | snr 013c | ber 0000026f | unc 
> 0000026f | FE_HAS_LOCK
>   1749        status SCVYL | signal 013c | snr 013c | ber 00000184 | unc 
> 00000184 | FE_HAS_LOCK
>   1796        status SCVYL | signal 013a | snr 013a | ber 00001a8b | unc 
> 00001a8b | FE_HAS_LOCK
>   1814        status SCVYL | signal 013c | snr 013c | ber 0000026d | unc 
> 0000026d | FE_HAS_LOCK
>   2028        status SCVYL | signal 013c | snr 013c | ber 00000275 | unc 
> 00000275 | FE_HAS_LOCK
>   2081        status SCVYL | signal 013c | snr 013c | ber 0000023a | unc 
> 0000023a | FE_HAS_LOCK
>   2261        status SCVYL | signal 013c | snr 013c | ber 00000264 | unc 
> 00000264 | FE_HAS_LOCK
>   2307        status SCVYL | signal 013c | snr 013c | ber 00000279 | unc 
> 00000279 | FE_HAS_LOCK
>   2318        status SCVYL | signal 013c | snr 013c | ber 0000026b | unc 
> 0000026b | FE_HAS_LOCK
>   2474        status SCVYL | signal 013a | snr 013a | ber 0000026f | unc 
> 0000026f | FE_HAS_LOCK
>   2533        status SCVYL | signal 013c | snr 013c | ber 00000098 | unc 
> 00000098 | FE_HAS_LOCK
>   2612        status SCVYL | signal 013a | snr 013a | ber 0000026a | unc 
> 0000026a | FE_HAS_LOCK
>   2627        status SCVYL | signal 013c | snr 013c | ber 00000108 | unc 
> 00000108 | FE_HAS_LOCK
>   2671        status SCVYL | signal 013c | snr 013c | ber 00000196 | unc 
> 00000196 | FE_HAS_LOCK
>   2870        status SCVYL | signal 013c | snr 013c | ber 00000264 | unc 
> 00000264 | FE_HAS_LOCK
>   3084        status SCVYL | signal 013c | snr 013c | ber 00000274 | unc 
> 00000274 | FE_HAS_LOCK
>   3220        status SCVYL | signal 013c | snr 013c | ber 00000275 | unc 
> 00000275 | FE_HAS_LOCK
>   3323        status SCVYL | signal 013c | snr 013c | ber 0000026b | unc 
> 0000026b | FE_HAS_LOCK
>   3406        status SCVYL | signal 013c | snr 013c | ber 0000024f | unc 
> 0000024f | FE_HAS_LOCK
>   3433        status SCVYL | signal 013c | snr 013a | ber 0000022a | unc 
> 0000022a | FE_HAS_LOCK
>   3946        status SCVYL | signal 013c | snr 013c | ber 00000270 | unc 
> 00000270 | FE_HAS_LOCK
>   4129        status SCVYL | signal 013c | snr 013c | ber 0000026d | unc 
> 0000026d | FE_HAS_LOCK
>   4275        status SCVYL | signal 013c | snr 013c | ber 00000273 | unc 
> 00000273 | FE_HAS_LOCK
>   4284        status SCVYL | signal 013c | snr 013c | ber 00000267 | unc 
> 00000267 | FE_HAS_LOCK
>   4411        status SCVYL | signal 013c | snr 013c | ber 00000270 | unc 
> 00000270 | FE_HAS_LOCK
>   4718        status SCVYL | signal 013c | snr 013c | ber 00000204 | unc 
> 00000204 | FE_HAS_LOCK
>   4779        status SCVYL | signal 013c | snr 013c | ber 00000181 | unc 
> 00000181 | FE_HAS_LOCK
>   4927        status SCVYL | signal 013c | snr 013c | ber 0000025e | unc 
> 0000025e | FE_HAS_LOCK
>   4973        status SCVYL | signal 013c | snr 013c | ber 00000157 | unc 
> 00000157 | FE_HAS_LOCK
>   5024        status SCVYL | signal 013c | snr 013c | ber 0000024c | unc 
> 0000024c | FE_HAS_LOCK
>   5310        status SCVYL | signal 013c | snr 013c | ber 00000190 | unc 
> 00000190 | FE_HAS_LOCK
>   5328        status SCVYL | signal 013c | snr 013c | ber 00000277 | unc 
> 00000277 | FE_HAS_LOCK
>   5439        status SCVYL | signal 013a | snr 013a | ber 0000026a | unc 
> 0000026a | FE_HAS_LOCK
>   5441        status SCVYL | signal 0138 | snr 0138 | ber 0000024f | unc 
> 0000024f | FE_HAS_LOCK
>   5447        status SCVYL | signal 0138 | snr 0138 | ber 00000266 | unc 
> 00000266 | FE_HAS_LOCK
>   5885        status SCVYL | signal 013a | snr 013a | ber 000000b3 | unc 
> 000000b3 | FE_HAS_LOCK
>   5928        status SCVYL | signal 013a | snr 013a | ber 0000020b | unc 
> 0000020b | FE_HAS_LOCK
>   5942        status SCVYL | signal 013a | snr 013a | ber 0000026b | unc 
> 0000026b | FE_HAS_LOCK
>   5966        status SCVYL | signal 013a | snr 013a | ber 000004d4 | unc 
> 000004d4 | FE_HAS_LOCK
>   6178        status SCVYL | signal 013a | snr 013a | ber 0000026c | unc 
> 0000026c | FE_HAS_LOCK
>   6657        status SCVYL | signal 0138 | snr 013a | ber 0000026e | unc 
> 0000026e | FE_HAS_LOCK
>   6761        status SCVYL | signal 013a | snr 013a | ber 00000268 | unc 
> 00000268 | FE_HAS_LOCK
>   6769        status SCVYL | signal 013a | snr 013a | ber 00000276 | unc 
> 00000276 | FE_HAS_LOCK
>   6777        status SCVYL | signal 013a | snr 013a | ber 00000277 | unc 
> 00000277 | FE_HAS_LOCK
>   6814        status SCVYL | signal 013a | snr 013a | ber 00000267 | unc 
> 00000267 | FE_HAS_LOCK
>   6868        status SCVYL | signal 0138 | snr 0138 | ber 00000171 | unc 
> 00000171 | FE_HAS_LOCK
>   6881        status SCVYL | signal 0138 | snr 0138 | ber 00000198 | unc 
> 00000198 | FE_HAS_LOCK
>   6891        status SCVYL | signal 0136 | snr 0138 | ber 00000249 | unc 
> 00000249 | FE_HAS_LOCK
>   6924        status SCVYL | signal 0138 | snr 0138 | ber 0000026b | unc 
> 0000026b | FE_HAS_LOCK
>   7116        status SCVYL | signal 0138 | snr 0138 | ber 00000150 | unc 
> 00000150 | FE_HAS_LOCK
>   7119        status SCVYL | signal 0138 | snr 0138 | ber 00000197 | unc 
> 00000197 | FE_HAS_LOCK
>   7140        status SCVYL | signal 0138 | snr 0138 | ber 00000270 | unc 
> 00000270 | FE_HAS_LOCK
>   7602        status SCVYL | signal 0138 | snr 0138 | ber 00000264 | unc 
> 00000264 | FE_HAS_LOCK
>   7716        status SCVYL | signal 0138 | snr 0138 | ber 00000194 | unc 
> 00000194 | FE_HAS_LOCK
>   7732        status SCVYL | signal 0138 | snr 0138 | ber 00000272 | unc 
> 00000272 | FE_HAS_LOCK
>   7751        status SCVYL | signal 013a | snr 0138 | ber 00000181 | unc 
> 00000181 | FE_HAS_LOCK
>   7770        status SCVYL | signal 013a | snr 013a | ber 00000270 | unc 
> 00000270 | FE_HAS_LOCK
>   7781        status SCVYL | signal 0138 | snr 0138 | ber 0000026f | unc 
> 0000026f | FE_HAS_LOCK
>   7796        status SCVYL | signal 0138 | snr 0138 | ber 00000275 | unc 
> 00000275 | FE_HAS_LOCK
>   7808        status SCVYL | signal 0138 | snr 0138 | ber 0000022f | unc 
> 0000022f | FE_HAS_LOCK
>   7816        status SCVYL | signal 013a | snr 0138 | ber 0000024e | unc 
> 0000024e | FE_HAS_LOCK
>   7822        status SCVYL | signal 013a | snr 013a | ber 00000270 | unc 
> 00000270 | FE_HAS_LOCK
>   7956        status SCVYL | signal 0138 | snr 0138 | ber 00000268 | unc 
> 00000268 | FE_HAS_LOCK
>   8008        status SCVYL | signal 0138 | snr 0138 | ber 0000026d | unc 
> 0000026d | FE_HAS_LOCK
>   8011        status SCVYL | signal 0138 | snr 0138 | ber 00000260 | unc 
> 00000260 | FE_HAS_LOCK
>   8232        status SCVYL | signal 013a | snr 013a | ber 0000024b | unc 
> 0000024b | FE_HAS_LOCK
>   8235        status SCVYL | signal 013a | snr 013a | ber 00000073 | unc 
> 00000073 | FE_HAS_LOCK
>   8255        status SCVYL | signal 0138 | snr 0138 | ber 00000254 | unc 
> 00000254 | FE_HAS_LOCK
>   8274        status SCVYL | signal 0138 | snr 0138 | ber 0000024e | unc 
> 0000024e | FE_HAS_LOCK
>   8303        status SCVYL | signal 0138 | snr 0138 | ber 0000017f | unc 
> 0000017f | FE_HAS_LOCK
>   8305        status SCVYL | signal 0138 | snr 0138 | ber 00000184 | unc 
> 00000184 | FE_HAS_LOCK
>   8354        status SCVYL | signal 013a | snr 0138 | ber 00000270 | unc 
> 00000270 | FE_HAS_LOCK
>   8442        status SCVYL | signal 0138 | snr 0138 | ber 0000024b | unc 
> 0000024b | FE_HAS_LOCK
>   8473        status SCVYL | signal 0138 | snr 0138 | ber 0000014b | unc 
> 0000014b | FE_HAS_LOCK
>   8510        status SCVYL | signal 0138 | snr 0138 | ber 00000253 | unc 
> 00000253 | FE_HAS_LOCK
>   8557        status SCVYL | signal 013a | snr 013a | ber 00000260 | unc 
> 00000260 | FE_HAS_LOCK
>   8578        status SCVYL | signal 013a | snr 013a | ber 00000259 | unc 
> 00000259 | FE_HAS_LOCK
>   8639        status SCVYL | signal 0138 | snr 0138 | ber 00000151 | unc 
> 00000151 | FE_HAS_LOCK
>   8742        status SCVYL | signal 013a | snr 0138 | ber 0000018c | unc 
> 0000018c | FE_HAS_LOCK
>   8820        status SCVYL | signal 0138 | snr 0138 | ber 00000265 | unc 
> 00000265 | FE_HAS_LOCK

So I see SNR values from 0x138 to 0x13c ( 31.2 dB to 31.6 dB ) when you
have problems.  For 256-QAM cable signals, I think that is considered
marginal.  

(Can someone else with 256-QAM North American cable please confirm? I
only have OTA)

When you have no errors, what is the SNR?  I'm guessing there are no
large swings.


> First recording of the evening shows "glitches" at the following
> intervals:
> 
> 4
> 130
> 157
> 396
> 742
> 790
> 1035
> 1035
> 1035
> 1071
> 1134
> 1146
> 1203
> 1256
> 1328
> 1338
> 1378
> 1602
> 1638
> 1694
> 
> Not sure if that's a close enough correlation or not.

Hard to tell, given that one of the other digital sub-channels may have
been effected and not visible on the channel you were recording.

I normally watch DTV live with mplayer, and also have femon open in
another window, when performing this sort of test.  A video or audio
glitch, 1 or 2 seconds after a non-zero uncorrectable block count, is
usually a good indicator of correlation.

>   Not even sure
> what those ber and unc values even mean.
>  
> > Watch for the BER or UNCorrectable block count to increase at about the
> > same time you view a glitch in the video.  If this is the case, there is
> > something about the signal the HVR-1600 is having trouble with.  (The
> > older models don't have the best digital tuner and digital demod
> > combination out there.)
> 
> So just sucky hardware in general?

Well, not the best performer from what I hear.  But certainly works just
fine for many people in many contexts.


> > If the signal shown in femon is at a relatively high level most of the
> > time, then the cable signal probably has an instantaneous signal that
> > sometimes overdrives the frontend.  An inline attenuator might make the
> > problem go away.
> > If the signal is at a low level, it may drop below threshold
> > occasionally.  An in line amplifier, installed as close to where the
> > signal comes into you home as possible, might help.
> 
> Not sure if those signal and snr values represent normal, low or high
> levels.  The values displayed above are fairly representative of the
> rest of the samples for the period in terms of signal and snr.

OK.  There are two ways to go here:

1. We assume your signal is marginal.  Take a look here for things to
check and fix if needed:

http://ivtvdriver.org/index.php/Howto:Improve_signal_quality

As a test, you you might also want to temporarily change your coax
wiring setup to reduce the number of splits and connectors before the
signal goes into the HVR-1600, and see if things are better.  Every
2-way splitter will drop 3-5 dB of signal.


2. We assume your signal is too strong, and that it is overdriving the
MXL5005s digital tuner of the HVR-1600, causing problems for the CX24227
demodulator.

Your corrective action here would be to attenuate the incoming RF signal
with either an inline attenuator, or with additional, properly
terminated, splitters.

An in line attenuator is pretty cheap (~US$2) from on-line sources:
http://www.google.com/search?hl=en&tbm=shop&q=75+ohm+in+line+attenuator

If you have some resistors lying around, you can make your own bridged-T
inline attenuator for testing purposes:

http://www.mail-archive.com/linux-media@vger.kernel.org/msg08735.html


Regards,
Andy


--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to