Hi, I have a Hauppauge PVR-HD which works but creating an h264 ts stream from a set HD component inputs and does quite a nice job of it.
The ts stream is available on /dev/video0 and a simple cat /dev/video0
file.ts will create a watchable high quality dump..
I have got this working with freevo (after a little hacking) but would prefer to get the input into vdr as I can then watch it around the house through streaming.
Using vdr-iptv I can get some of the way, but not all of it.. Playing around with different options I get either jerky video or ffmpeg just stops transcoding after a few seconds, and I'm not sure why...
I can put a 2 minute ts stream somewhere if it would help but I think it will decode a file before decoding from /dev/video0
Hauppuage-test;IPTV:1000:IPTV|S0P0|EXT|hauppauge.sh|951:P:0:256:257:0:0:1000:1:1:0
Then it just freezes...
Any ideas?
On 08/02/10 12:35, Rolf Ahrenberg wrote:
After a little investigation, it looks like it's an issue of ffmpeg reading directly off the /dev/video0 device. It looks like it gets ahead of itself. If I cat /dev/video0 to a file, sleep 5s and then ffmpeg decode the file, it almost works..
I tried to put /dev/video0 as a file but couldn't get anything out of VDR... Saying that I'm pretty sure I removed the h264 VDR patch since coming to the US. I'm running VDR 1.6 instead of 1.7 as I know what I'm doing better with it in Gentoo..
I will record a 5 min clip and put it somewhere..
Would there be a way to watch a file and call a script? That way I can execute an external channel changer depending on parameter and then dump the output to a fifo..
As an aside, xine-vdpau (xineliboutput) didn't want to play the stream (albeit stuttering horribly) full screen - it looked like a 4:3 picture when it should have been 16:9, although xine-xv didn't have a problem..
Hi,
Am 08.02.2010 16:53, schrieb Rob Davis:
Is it a cx18-based card? There a plans to integrate support for the native TS-capability of those cards in the pvrinput-plugin, but it will take some time. If you mind you can send me off-list a sample video (up to 4MB with the cat-method). I'm just working on repacking the program stream of ivtv-based cards with valid PAT, PMT and PCR, a pass through of a valid TS shouldn't be that hard. But I don't promise anything since I haven't such a card. Particulary if its controls are too different from the ivtv-ones.
regards, Lars.
On 08/02/10 12:58, L. Hanisch wrote:
I spoke to Marin a little about this.. In terms of controls.. There are none that need worrying about... It doesn't have a tuner. It would be useful to have a way to control an external channel changer (which Martin nicely put in for my other pvr-500 card (for SD channels off the cable box)..
The linux module is pvrhd. Once loaded, along comes a /dev/video0 device. A cat or mplayer command on this work well.
The ts stream is dependant on what is fed to it. Ie, if your source is 1080i, then you'll get a 1080i stream, if 720p then that's what you get..
There was a quick sample on the internet, but I can also manually record something for you if you want it.. Just not sure where to leave it..
Hi Rob,
Am 08.02.2010 21:28, schrieb Rob Davis:
I see, I helped him with getting it into the plugin.
The linux module is pvrhd. Once loaded, along comes a /dev/video0 device. A cat or mplayer command on this work well.
I did some google search on the PVR-HD and found the module name "hdpvr" in the mythtv-wiki and in my ubuntu modules directory. What says "cat /sys/class/video4linux/video0/name" and "cat /sys/class/video4linux/video0/uevent"?
The ts stream is dependant on what is fed to it. Ie, if your source is 1080i, then you'll get a 1080i stream, if 720p then that's what you get..
Ok, "no controls" is a good thing, if the plugin only has to read from the device and hand the packets over to vdr, we can give it a try.
There was a quick sample on the internet, but I can also manually record something for you if you want it.. Just not sure where to leave it..
I would like to see some small piece of video (about 4MB) to inspect the TS structure (till now I've only dealt with MPEG2-PS/TS), my inbox has no problem with an attachment of such size. Just cat some seconds to a file and send it to me (perhaps you have to truncate it with dd if it's growing to fast but make sure I get the beginning of the file ;-)). At the next weekend I can try to integrate support for it. In particular I'm interested if the PAT and PMT is present or if I have to build them with the cPatPmtGenerator of vdr 1.7.1 and up. Will it be a problem for you to upgrade to 1.7.x (x >= 1)?
regards, Lars.
Hi Rob,
Am 08.02.2010 21:28, schrieb Rob Davis:
There was a quick sample on the internet, but I can also manually record something for you if you want it.. Just not sure where to leave it..
I received your sample and it looks like a valid TS with PAT, PMT and PCR, so the plugin has nothing else to do as to pass it through to the vdr (hopefully). As pvrinput is setting a lot of controls for the cx23415/16 based cards, I'm not sure, which is the best way. Either integrate it in pvrinput (and leave the controls as is if a hdpvr is accessed) or make a new "hdpvrinput"-plugin. In the next days I will study the source as I'm new to the pvrinput-plugin but I'm confident I can make it work.
Please provide the output of
v4l2-ctl --info --list-ctrls-menus --device=/dev/video0
after a fresh load of the module. That should give me the needed parameters/values to distinguish the cards inside the plugin. The next weekend is dedicated to you. ;-)
regards, Lars.
On Tue, 9 Feb 2010, L. Hanisch wrote:
In the meanwhile, one could also try out the IPTV plugin without any ffmpeg hassle by using a script that tunes the device and then simply:
cat /dev/video0 | nc -u -p ${PORT} 127.0.0.1
BR, -- rofa
On Wed, 2010-02-10 at 11:18 +0200, Rolf Ahrenberg wrote:
Most of this is extra debug output, but I've never used the nc command. The port number looks to be the same as ffmpeg would use.. The only thing that may be different is there is no packet size specified..
Getting new URL /dev/video0 Change Channel to 951 on Cable Box starting with node: 1 node 1: vendor_id = 0x000024a0 model_id = 0x0000ea05 AV/C Command: 951 = Op1=0x00487C29 Op2=0x00487C25 Op3=0x00487C21 Streamsvideo.sh PID is 32604 Streamdev Plugin 951 /dev/video0 nc -u -p 4321 127.0.0.1 no port[s] to connect to
On Wed, 2010-02-10 at 11:18 +0200, Rolf Ahrenberg wrote:
Ok, did some reading of the manual..
cat /dev/video0 | nc -vv -u 127.0.0.1 ${PORT} &
Should work..
Now says:
localhost [127.0.0.1] 4321 (rwhois) open sent 573440, rcvd 0
Then gets killed, or nc stops..
Logs say:
Feb 10 09:41:30 oac vdr: [31783] switching to channel 409 Feb 10 09:41:30 oac vdr: [12720] transfer thread ended (pid=31783, tid=12720) Feb 10 09:41:30 oac vdr: [31783] buffer stats: 33652 (1%) used Feb 10 09:41:30 oac vdr: [31783] IPTV: cSidScanner::SetStatus(): 0 Feb 10 09:41:30 oac vdr: [31783] IPTV: cSidScanner::SetChannel(): IPTV| S1P1|EXT|streamsvideo.sh|951 Feb 10 09:41:30 oac vdr: [31783] IPTV: cPidScanner::SetChannel(): IPTV| S1P1|EXT|streamsvideo.sh|951 Feb 10 09:41:30 oac vdr: [31783] IPTV: cSidScanner::SetStatus(): 0 Feb 10 09:41:30 oac vdr: [31783] IPTV: cSidScanner::SetStatus(): 1 Feb 10 09:41:30 oac vdr: [12724] transfer thread started (pid=31783, tid=12724) Feb 10 09:41:30 oac vdr: [12725] receiver on device 10 thread started (pid=31783, tid=12725) Feb 10 09:41:30 oac vdr: [12725] IPTV: cIptvUdpSocket::OpenSocket() Feb 10 09:41:30 oac vdr: [12725] IPTV: cIptvSocket::OpenSocket() Feb 10 09:41:30 oac vdr: [12725] IPTV: cSidScanner::SetStatus(): 1 Feb 10 09:41:30 oac vdr: [31783] [xine..put] Detected HD OSD, size > 752x1072, using setup values 752x647 Feb 10 09:41:30 oac vdr: [12727] IPTV streamer thread started (pid=31783, tid=12727) Feb 10 09:41:30 oac vdr: [12728] EnigmaNG effects thread started (pid=31783, tid=12728) Feb 10 09:41:30 oac vdr: [31783] EnigmaNG: cPluginSkinEnigma::LoadChannelLogo: LOGO "Hauppuage-test.xpm" NOT FOUND in /usr/share/vdr/skinenigmang/[hq]logos Feb 10 09:41:30 oac vdr: [12722] TS buffer on device 1 thread ended (pid=31783, tid=12722) Feb 10 09:41:30 oac vdr: [12721] buffer stats: 32336 (1%) used Feb 10 09:41:30 oac vdr: [12721] receiver on device 1 thread ended (pid=31783, tid=12721) Feb 10 09:41:32 oac vdr: [12725] IPTV: cPidScanner::Process: Found lower Apid: 0x1100 instead of 0xFFFF Feb 10 09:41:32 oac vdr: [31810] IPTV: cSidScanner::Process(): Pid=0 Tid=00 Feb 10 09:41:32 oac vdr: [31810] IPTV: cSidScanner::SetChannel() Feb 10 09:41:32 oac vdr: [31810] IPTV: cSidScanner::SetStatus(): 0 Feb 10 09:41:32 oac vdr: [12725] IPTV: cPidScanner::Process: Found lower Vpid: 0x1011 instead of 0xFFFF Feb 10 09:41:33 oac vdr: [12725] ERROR: Skipped 36 bytes to sync on TS packet Feb 10 09:41:33 oac vdr: [12725] IPTV: cSidScanner::SetStatus(): 0 Feb 10 09:41:33 oac vdr: [12727] IPTV streamer thread ended (pid=31783, tid=12727) Feb 10 09:41:33 oac vdr: [12725] IPTV: cIptvSocket::CloseSocket() Feb 10 09:41:33 oac vdr: [12725] receiver on device 10 thread ended (pid=31783, tid=12725) Feb 10 09:41:35 oac vdr: [12728] EnigmaNG effects thread ended (pid=31783, tid=12728)