Opened 8 years ago

Last modified 45 hours ago

#11018 assigned Patch - Bug Fix

Distortion of Recordings/LiveTV if EIT-Scan is processing on another capturecard

Reported by: Shinck@… Owned by: Klaas de Waal
Priority: minor Milestone: needs_triage
Component: MythTV - General Version: 0.25-fixes
Severity: medium Keywords: EIT
Cc: Ticket locked: no


After upgrading from MythTV 0.21 / Mythbuntu 08.10 to MythTV 0.24 / Mythbuntu 10.04 I detected distortions and artefacts in video/audio in recordings/LiveTV of my BT878/BTTV based DVB-S capturecard. After further investigations I saw that this was caused by an active EIT-Scan on my other DIBcom-3000mc based DVB-T card. If both two cards are active I saw lots of this lines in backend-log:

  E DVBRead mpeg/pespacket.cpp:79 (AddTSPacket) AddTSPacket: Out of sync!!! Need to wait for next payloadStart PID: 0x12, continuity counter: 6 (expected 5).

So I decided to switch of EIT-Scanning of the DVB-T card and the distortions were gone (But as DVB-T and DVB-S in my setup don't based on the same Video-Source I lost EPG-Information of DVB-T and had to record or look LiveTV on the DVB-T channels to update the information). I don't know If this was caused by mythtv or the LinuxTV-v4l/DVB driver framework but I hoped that updating to 0.25 makes things better. As the problem wasn't gone with 0.25 I decided to write a patch that switches of the EIT-Scanning at all capture-cards if a program records or I look liveTV. After the last record finishes the timer eitCrawlIdleStart is set again on all cards. With this attempt I also resolve another problem: I've setup my system to shutdown(hibernate) if it's idle and ACPI-wakeup before new recordings, but it never shutdown after a recording because a EIT-Scan on another card than the recording-card was running after the recording.

So now I provide the patch. Perhaps it could be helpful for some other people.

Attachments (4)

0002-libmythtv-EIT-ActiveScan-Control-optimized.patch (15.8 KB) - added by Shinck@… 8 years ago.
Stop EIT-Scan on all capture cards if record or liveTV is ongoing and start again afterwards
version-linux.txt (865 bytes) - added by Shinck@… 8 years ago.
Version information
0003-libmythtv-EIT-ActiveScan-Control-optimized-026.commit (9.0 KB) - added by Shinck@… 8 years ago.
Patch for master / 0.26-rc
version026-linux.txt (876 bytes) - added by Shinck@… 8 years ago.
Version information

Download all attachments as: .zip

Change History (14)

Changed 8 years ago by Shinck@…

Stop EIT-Scan on all capture cards if record or liveTV is ongoing and start again afterwards

Changed 8 years ago by Shinck@…

Attachment: version-linux.txt added

Version information

comment:1 Changed 8 years ago by Raymond Wagner

Are these all PCI devices? Is it possible you are simply putting too much traffic on the bus, and starving your framegrabbers of bandwidth to their frame buffers?

comment:2 Changed 8 years ago by Shinck@…

I don't think so. I've 3 capture-cards. And all stays on different busses. One Bt878-Bttv based DVB-S card on the PCI-Bus, It is for SD-Content only and worked flawlessly at Mythbuntu/Ubuntu? 08.10 with one USB1.1-DVB-T card (Dibcom-3000mc-based) with an hardware PID filter (table count: 16). The third an newest one (but the problem was also before) is an SAA716x_TBS/TBS6928fe based DVB-S2 card on the PCI-express-bus for the DVB-S HD-Content.

comment:3 Changed 8 years ago by Shinck@…

Annotation: None of my cards is an analog framegrabber, all cards are digital DVB-cards.

comment:4 Changed 8 years ago by Shinck@…

Annotation2: And the distortion and discontinuities of video/audio are on the DVB-S card which resides on the PCI bus not the USB1.1 device (it has no problems).

comment:5 Changed 8 years ago by Shinck@…

Recently I switched from fixes/0.25 to master. After some adaptions the patch also works here fine. So I will attach it here.

Changed 8 years ago by Shinck@…

Patch for master / 0.26-rc

Changed 8 years ago by Shinck@…

Attachment: version026-linux.txt added

Version information

comment:6 Changed 8 years ago by stuartm

What level of logging are you using? Extremely verbose logging (i.e.non standard levels) can have an effect on performance e.g. high disk I/O that has been known to cause problems on some systems. During normal operation the defaults for verbosity/level should be used and greater verbosity only turned on when debugging an issue.

comment:7 Changed 8 years ago by Shinck@…

At daily use I leave the Standard levels (verbose: general and LogLevel?: info). With these levels the distortions were existent. For debugging purposes sometimes I change verbose to idle,eit,record,dvbcam but leave LogLevel? at info.

But since I've switched of EIT-Scanning during recording or LiveTV with the patch the error is gone. So it works now for me.

comment:8 Changed 4 months ago by Klaas de Waal

This might be useful for low-end devices such as the RPI when used as a backend. Let's keep this one open for now.

comment:9 Changed 4 months ago by Stuart Auchterlonie

Owner: set to Klaas de Waal
Status: newassigned

comment:10 Changed 45 hours ago by Stuart Auchterlonie

Milestone: unknownneeds_triage
Note: See TracTickets for help on using tickets.