After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 586097 - GStreamer DVB tuning too quick for some devices
GStreamer DVB tuning too quick for some devices
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
0.10.12
Other All
: Normal normal
: 0.10.14
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2009-06-17 08:44 UTC by Austin Lund
Modified: 2009-07-16 19:09 UTC
See Also:
GNOME target: ---
GNOME version: 2.25/2.26


Attachments
Patch to fix (1.17 KB, patch)
2009-06-19 10:21 UTC, Austin Lund
committed Details | Review

Description Austin Lund 2009-06-17 08:44:08 UTC
Please describe the problem:
The dvb source in gstreamer-plugins-bad goes from the FE_SET_FRONTEND ioctl to the FE_READ_STATUS ioctls too quickly.  My device (Afatech AF9013 DVB-T) takes about 1 second to tune to a channel.  The way gstdvbsrc.c is coded at the moment in gst_dvbsrc_tune() it only allows for about 500ms before it gives up.  

By increasing the length of time waited at the FE_READ_STATUS cycle, things are slower but at least my device does eventually tune.  I've noted that other players use a poll() to perform this step instead of a fixed length of time to tune.

Steps to reproduce:
1. Get a DVB device that takes > 500ms to tune.
2. Run: gst-launch playbin 'uri=dvb://BLAH'


Actual results:
Gives up trying to tune very quickly and returns.

Expected results:
Tunes to selected station

Does this happen every time?
Yes

Other information:
Comment 1 Austin Lund 2009-06-19 10:21:20 UTC
Created attachment 136986 [details] [review]
Patch to fix

Increase the time to wait for tuning to 5 sec.  Also check for status and jump out of loop when success is detected.

(I formatted this against commit 29aa30d9. SORRY!)
Comment 2 Sebastian Dröge (slomo) 2009-07-16 19:09:05 UTC
commit b9890a2bf724cafb561c47df2ff48cc3ae4f0e89
Author: Austin Lund <austin.lund@gmail.com>
Date:   Fri Jun 19 20:13:53 2009 +1000

    Increased the length of time for tuning in gstdvbsrc.c.
    
    Some devices take a while to tune and 500ms was too short to detect
    successful tuning.  As well as waiting for 5 seconds each 100ms the
    status is checked and the loop is broken out of when tuning has suceeded.