[mythtv] [mythtv-commits] Ticket #1502: DVB API requires usleep after certain calls to get reliable tuning on certain drivers (esp Nova-T).

Manu Abraham abraham.manu at gmail.com
Thu Mar 16 00:13:41 UTC 2006

Doug Scoular wrote:
> Hi Daniel et al,
> Danielk wrote:
>  > I believe the sleep after FE_READ_STATUS in scan is just to give the card
>  > some breathing room. We do the same thing in SignalMonitor::MonitorLoop()
>  > usleep(update_rate * 1000);
>     Ah, okay I'll play with the update_rate.
> Danielk wrote:
>  > The BER and UNC are mostly meaningless the way we read them.
>  > These are cumulative values, so we should throw out the first
>  > read and we should also sum these over a time period and report
>  > errors seen in that period, but we do neither. There is a comment
>  > in DVBSignalMonitor::UpdateValues() about this...
>     Yes, I read that and I really don't care that much
>     about BER/UNC stats... just whether FE_HAS_LOCK is
>     reliable.

It depends on the driver how this averaging is done, so the app should 
probably handle the value that it get's through, but it doesn't hurt to 
average the values either. But there are cards where this is totally 

>     I understand... and as I said it is FE_HAS_LOCK that
>     I really care about too.

For testing whether the tuning has succeded, checking for FE_HAS_LOCK 
should be sufficient.

>     I think the delay is also needed to determine whether
>     the tuner has reliably achieved FE_HAS_LOCK.

Yes. It can be considered as a Factor Of Safety. All applications do 
abide by this except for MythTV. IIRC Marcus Metzler did send a pacth to 
fix this issue, but that patch was thrown away.

>     I'm beginning to think the signal monitoring is fairly
>     meaningless... 

Signal monitoring is meaningless on some cards, since different tuners 
have different values etc, and there is not much of a standardization 
there, but this will change in the future.

>     I might also look over how the DVR project deal with tuning
>     on DVB cards... 

You can take a look at scan, VDR, Mplayer, VLC or anything. All the 
applications out there tune properly except for MythTV. In fact Marcus 
Metzler had sent a patch to fix this issue. Any ideas what happened to it ?


More information about the mythtv-dev mailing list