Skip to contentSkip to conversation

Hauppauge Win TV HVR-1300: streaming and grabbing fail after a while, changing resolution renders card inoperable

DISCUSSION Friedrich Delgado Friedrichs 1 participant 3 messages Jan 17, 2010 – Jan 26, 2010 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

Hi!

I have a Hauppauge HVR-1300 which I currently intend to use for capturing analog cable tv, because of the hardware mpeg encoder.

There are three problems, which might or might not be related:

1) mpeg stream from hardware encoder breaks off or is corrupted (I can't tell which) after a while

2) screengrabber image gets corrupted after a while

3) changing resolutions causes mpeg encoder stream to become completely inoperable

I've made sure to reproduce all problems with an untainted 2.6.32 kernel (package linux-image-2.6.32-trunk-amd64 version 2.6.32-5 from ubuntu).

1) mpeg stream from hardware encoder breaking:

After setting a channel with

ivtv-tune -d /dev/video1 -t europe-west -c E6

I can play the mpeg stream e.g. with

mplayer -nofs -vo x11 /dev/video1 -cache 8192

but after a while (ranging from a few seconds to several minutes (up to five, I think)) the video stream seems to break off. mplayer shows a freezed frame, there's no sound. Sometimes mplayer will terminate with "end of file".

The same happens when I do

cat /dev/video1 > test.mpg

and play test.mpg with mplayer, however the test.mpg file still grows, so there's some output from the device, mplayer apparently just isn't able to play it. I still get end of file with this file, even though mplayer displays it's 7 minutes or longer, just the first minute will be played.

I've unloaded the modules and reloaded them with

modprobe cx2341x debug=1
modprobe cx88_blackbird debug=1 video_debug=1 mpegbufs=32

in order to get some debug output in dmesg. dmesg output was pastebinned at http://pastebin.com/f60ad5dcc since it's too long for this list.

(In case you're curious about the backtrace in the beginning, I uploaded the start of syslog at http://pastebin.com/f3bac25d7 I'd also like to know if it might indicate problems.)

2) corrupted image from screengrabber:

There are also problems with the framegrabber on /dev/video0. When I watch analog tv directly (with mythtv or tvtime), after a while (again a few seconds up to a few minutes), the picture shrinks to an area in the upper right corner. In the lower parts there are sometimes moving artefacts.

If I run a tail -f on syslog I see nothing, but this time I didn't give any debug options to the modules (also I was using an older kernel, tainted by the fglrx driver. If you want, I can reproduce this with the untainted 2.6.32 again.)

I've uploaded a screenshot from tvtime to
http://dudelab.org/~taupan/tvtime-output-22:45:53.jpg

xawtv display looks very weird... as if every eighth line was shifted by about a 16th of its width or so. Example image at
http://dudelab.org/~taupan/snap-viva-20100117-142327-1.jpeg

(I used roughly the same xawtv configuration with an ancient hauppauge card from 1997 which I used successfully until recently.)

3) broken resolution switching:

When I switch resolutions in mythtv recording profile, but also via e.g.

v4l2-ctl -d /dev/video1 --set-fmt-video=width=720,height=568

I seem to totally break the encoder. There's no stream any more,

~> cat /dev/video1
cat: /dev/video1: Input/output error

And switching the resolution back doesn't help. Unloading the modules doesn't help either, I have to reboot the box.

dmesg output pastebinned at http://pastebin.com/f4e27757a

Tests were done with a 2.6.32 kernel from ubuntu.

Please ask if there's any information you can't easily infer from this mail or the attached logs.

Kind regards
Friedel
--
Friedrich Delgado Friedrichs <[email protected]>
TauPan on Ircnet and Freenode ;)

#1 lore raw

I'm sorry, two of the problems described in my mail have nothing to do with the driver. There's a daemon running that accesses the tuner and vbi (nxtvepg), which causes problems 1 and 2.

I've failed to notice this because nxtvepg can (normally) detect tvtime and xawtv and doesn't interfere with them, so I assumed it might have a general mechanism for detecting if the tv driver is in use by a different app.

The third problem remains:

Quoted 13 lines · Friedel

3) changing resolutions causes mpeg encoder stream to become completely inoperable

When I switch resolutions in mythtv recording profile, but also via e.g.

v4l2-ctl -d /dev/video1 --set-fmt-video=width=720,height=568

I seem to totally break the encoder. There's no stream any more,

~> cat /dev/video1
cat: /dev/video1: Input/output error

Quoted 6 lines

And switching the resolution back doesn't help. Unloading the modules doesn't help either, I have to reboot the box.

dmesg output pastebinned at http://pastebin.com/f4e27757a

Tests were done with a 2.6.32 kernel from ubuntu.

Which I assume is a vanilla kernel. I might be wrong about this, too.

I could test with newer drivers or a newer kernel of course, if you suspect that the problem might not be fixed yet.

Quoted 2 lines

Please ask if there's any information you can't easily infer from this mail or the attached logs.

Signature · 2 lines
        Friedrich Delgado Friedrichs <[email protected]>
                             TauPan on Ircnet and Freenode ;)
#2 lore raw

Reproduced this problem with latest checkout from http://linuxtv.org/hg/v4l-dvb

Quoted 28 lines · Friedel

I'm sorry, two of the problems described in my mail have nothing to do with the driver. There's a daemon running that accesses the tuner and vbi (nxtvepg), which causes problems 1 and 2.

I've failed to notice this because nxtvepg can (normally) detect tvtime and xawtv and doesn't interfere with them, so I assumed it might have a general mechanism for detecting if the tv driver is in use by a different app.

The third problem remains:

Quoted 16 lines · Friedel

3) changing resolutions causes mpeg encoder stream to become completely inoperable

When I switch resolutions in mythtv recording profile, but also via e.g.

v4l2-ctl -d /dev/video1 --set-fmt-video=width=720,height=568

I seem to totally break the encoder. There's no stream any more,

~> cat /dev/video1
cat: /dev/video1: Input/output error

And switching the resolution back doesn't help. Unloading the modules doesn't help either, I have to reboot the box.

Quoted 13 lines
Quoted 3 lines

dmesg output pastebinned at http://pastebin.com/f4e27757a

Tests were done with a 2.6.32 kernel from ubuntu.

Which I assume is a vanilla kernel. I might be wrong about this, too.

I could test with newer drivers or a newer kernel of course, if you suspect that the problem might not be fixed yet.

Quoted 2 lines

Please ask if there's any information you can't easily infer from this mail or the attached logs.

---Zitatende---

Signature · 2 lines
        Friedrich Delgado Friedrichs <[email protected]>
                             TauPan on Ircnet and Freenode ;)