Record and playback via IEEE 1394 (a.k.a. Firewire) with linux! - AVS Forum
Forum Jump: 
Reply
 
Thread Tools
post #1 of 58 Old 10-09-2006, 03:44 PM - Thread Starter
Member
 
Denbo_33's Avatar
 
Join Date: Nov 2005
Posts: 46
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
UPDATE 02/13/07
Updated software With attached file "avc_hdtv_record_source.zip"
changes include. No need to find your source device node or channel number, using plugreport. Edited dvcont to send "record" and "stop" commands to avc_hdtv_record, it is now possible to schedule a recording using a script to run dvcont. avc_hdtv_record saves the recorded stream to file named with the date you started the recording. as in Feb_12_2007_09_30_16.


Record and playback via IEEE 1394 (a.k.a. Firewire) with linux .
My system a SAMSUNG DLP HLRxx68w and a 5 year old PC.
This should work under any HDTV or settop cable box with an 1394 interface.

Runs under linux Kernel 2.6.16-1.2133,. Setup was is a snap, if I can do it you can too. just follow the Step by step section below.

Runs under command line terminal.
You will need to know a little about linux commands, but it is not rocket science.

I have been able to record and playback local HD broadcasts with an antenna as the source will excellent sound and picture. Record and playback is hit and miss via cablecard, sound and picture are out of sync. I think I know what the problem is but haven't nailed the root cause, yet. Although I can playback with VLC with no sync problems.


I use the Redhat Linux distribution FC5, will kernel version stated above. FC5 can be found at fedora.redhat.com/docs/fedora-install-guide-en/fc5/ The Libraries can be downloaded and installed via yum (as in "yum install libiec61883"), source files can be found at linux1394.org and or Google it.

You can Record and playback (playback with VLC) 5C protected Digital content, at least up to copy once level, I haven't seen a copy never level of 5C yet.
Also have not tried recording a SD source. But who would want too?

I can't take any credit for getting this to work all I did was edit (cough hack) the avc_vcr.c source found it libavc1394 and hacked through the example source files found in libraw1394, libavc1394, and libiec6183 . Thanks goes to Dan Dennedy and linux1394 crew. Thanks Dan!

Minimum PC hardware:

Pentium II 650 MHz
394 Mb ram
IDE ATA-33
ATA-33 Hard Drive greater that 20G
PCI IEEE1394 card
note: I have a Penguin Gear PG-FW-310 Nec chip and 3 External ports.
Specs found at www.byteccusa.com/product/PCI/PG-FW-310.htm
\tCost $15.00 that with a 1394 cable.
\tsee linux1394.org for other Compatible 1394 cards.

Minimum OS:
Redhat FC5 (http://fedora.redhat.com)
Kernel = 2.6.16-1.2133_FC5 (updated via software updater.)
a root password
and user account


Libraries Requirements :
Use yum to install as in "yum install libraw1394-devel"

libraw1394 ver 1.2.1
libraw1394-devel ver 1.2.1
libiec61883 ver 1.0.0.0
libiec61883-utils
libavc1394 ver 0.5.3
libavc1394-devel


Source code Requirements :
found at linux1394.org and or sourceforge.net
tar files

libiec61883-1.0.0

libavc1394-0.5.3



Hacked Source code:
avc_vcr_hdtv.c
mpg1394grab.c
test-mpeg2.c


Setup Install:

1.Install FC5

update kernel to 2.6.16-1.2133
via package updater




2. Download Source code Requirements files and configure and build but do not install.

Make a directory under your user account call it ieee_project.
mkdir /home/(your user accont)/ieee_project
Copy all Source code Requirements files to this directory.
Extract using desktop folder thingy.

Open a terminal window

login as root on terminal window
su
then password



3 Change directory to /home/(user account)/ieee_project/ libiec61883-1.0.0
"cd /home/(user account)/ieee_project/ libiec61883-1.0.0"
configure make files
"./configure"
build code
"make"

4. Change directory to cd /home/(user account)/ieee_project/ libiec61883-1.0.0/examples
"cd /home/(user account)/ieee_project/ libiec61883-1.0.0/examples"

Copy mpg1394grab.c into this directory.

cp mpg1393grab.c /home/(user account)/ieee_project/ libiec61883-1.0.0/examples/

Build mpg1394grab.c

gcc -lraw1394 /usr/lib/libiec61883.so.0 -o mpg1394grab mpg1394grab.c -D_FILE_OFFSET_BITS=64

Copy test-mpeg2.c into this directory.

cp test-mpeg2.c /home/(user account)/ieee_project/ libiec61883-1.0.0/examples/

answer yes to overwrite

To build test-mpeg2.c remove test-mpeg2.o

"rm /home/(user account)/ieee_project/ libiec61883-1.0.0/examples/ test-mpeg2.o

then
"make"





5 Change directory to /home/(user account)/ieee_project/ libavc13940-0.5.3
"cd /home/(user account)/ieee_project/ libavc13940-0.5.3"

"./configure"

"make"

\tChange directory to /home/(user account)/ieee_project/ libavc13940-0.5.3
"cd /home/(user account)/ieee_project/ libavc13940-0.5.3/test"


Copy avc_vcr_hdtv.c into this directory.
"cp avc_vcr_hdtv.c /home/(user account)/ieee_project/ libavc13940-0.5.3/test/"

Copy build_avc_vcr_hdtv.sh into this directory.
"cp build_avc_vcr_hdtv.sh /home/(user account)/ieee_project/ libavc13940-0.5.3/test/"

Build avc_vcr_hdtv.c


Run the scrpt file

"sh build_avc_vcr_hdtv.sh"



output = "creating avc_vcr_hdtv"


Configure 1394 card:
1 Run setrom
"./setrom"
\tThis utility configures the csr rom of the 1394 card so it appears as an avc device.
\t

2. Run avc_vcr_hdtv

"./avc_vcr_hdtv"

output = Starting AV/C target; press Ctrl+C to quit...

3 Connect ieee1394 cable between ieee1394 cards first port and the HDTV.

4. Open a terminal window
Change to the directory of source code libavc1394-0.5.3/test

cd /home/(user account)/ieee_project/ libavc13940-0.5.3/test "



5. Run romtest
"./romtest"

output similar to

Librom1394 Test Report
=================================================

Node 0:
-------------------------------------------------
bus info block length = 4
bus id = 0x31333934
bus options:
isochronous resource manager capable: 1
cycle master capable : 1
isochronous capable : 1
bus manager capable : 0
cycle master clock accuracy : 100 ppm
maximum asynchronous record size : 2048 bytes
GUID: 0x00004c0100003f1f
directory:
node capabilities : 0x000083c0
vendor id : 0x0000004c
unit spec id : 0x0000a02d
unit software version: 0x00010001
model id : 0x00ae1f08
textual leaves : Kino Rocks!

Node 1:
-------------------------------------------------
bus info block length = 4
bus id = 0x31333934
bus options:
isochronous resource manager capable: 1
cycle master capable : 1
isochronous capable : 1
bus manager capable : 1
cycle master clock accuracy : 100 ppm
maximum asynchronous record size : 2048 bytes
GUID: 0x0000f01000013ad4
directory:
node capabilities : 0x000083c0
vendor id : 0x000000f0
unit spec id : 0x00000989
unit software version: 0x00000100
model id : 0x00010001
textual leaves : SAMSUNG HL-R5067W VL_LIN_Apr282005 16:19:58



Note the node number of the HDTV, node 1 in this example
The node number may change every time you the reset (power down, and or disconnect the cable) on a 1394 device.

6. Run plugreport
plugreport


output similar to

Host Adapter 0
==============

Node 0 GUID 0x00004c0100003f1f
------------------------------
oMPR n_plugs=1, data_rate=0, bcast_channel=0
oPCR[0] online=1, bcast_connection=0, n_p2p_connections=0
channel=1, data_rate=2, overhead_id=15, payload=146
iMPR n_plugs=1, data_rate=0
iPCR[0] online=1, bcast_connection=0, n_p2p_connections=0
channel=0

Node 1 GUID 0x0000f01000013ad4
------------------------------
oMPR n_plugs=1, data_rate=2, bcast_channel=0
oPCR[0] online=1, bcast_connection=0, n_p2p_connections=0
channel=0, data_rate=0, overhead_id=0, payload=146
iMPR n_plugs=1, data_rate=2
iPCR[0] online=1, bcast_connection=0, n_p2p_connections=0
channel=1


Note the channel number of the HDTV node 1 iPCR[0] plug, channel=1 in this example.



Recording:

1. Tune to a local HD channel with an antenna as the source.

2. Run avc_vcr_hdtv in a terminal window if not already

3. Open a terminal window

4.. cd to libiec61883-1.0.0/examples/

cd /home/(user account)/ieee_project/ libiec61883-1.0.0/examples/

3. run mpg1394grab

./mpg1394grab n (node of HDTV) > (a file name)


Record for at least five minutes.
Quit mpg1394grab

Ctrl + c



4. List files and check length
ls l
the file length should be greater than zero

To Playback:

1.\tsetup HDTV to select the PC ieee1394 device (Kino Rocks) for playback.
2.\tRun avc_vcr_hdtv in a terminal window if not already.

3.Run test-mpeg2
./test-mpeg2 -t (node of HDTV) c (Channel number (iPCR[0]) of the destination device) (file name)


Notes:



If file length is zero:
1. Try another port on pc 1394 card

2. Run plugreport while recording note the n_p2p_connections
On source ( oPCR[0] ) and destinsion (iPCR[0] ) plugs should = 1.

3.If file length is greater than zero but file cannot be played back via VLC or HDTV. Get a hex editor or viewer installed and have a look at the file. The first offset should equal 0x47XXXXXX (X is dont care) if it is not then the source device is encrypting the stream, you then may want to remove power on all devices, and try again. Else?

You can try to record with test-mpeg2
./test-mpeg2 r (node of source) > (file name)

I have found this is not as reliable as mpg1394grab. Check it out as it might work on your system.

You should have only two devices on the 1394, as the code may cough if it sees more than two devices.


Enjoy!


10/20/06 EDIT

1. Corrected wrong file name avc_hdtv to avc_vcr_hdtv
2. Added a script file to build avc_vcr_hdtv.c build_avc_vcr_hdtv.sh
3. Corrected typos

11/02/06
1. Corrected typos in file bulid_avc_vcr_hdtv.sh
2. Corrected build of test-mpeg2.c

02/12/07

1. Added avc_hdtv_record_source.zip to file list.
2. avc_hdtv_record finds the node and channel of the source device no need to run plugreport. Also saves the ts stream file named with the date you started to record. How to included in zip. edited dvcont to send "record" and "stop" commands to avc_hdtv_record. It is now possible to schedule a recording using a script to run dvcont.

 

avc_source.zip 8.197265625k . file

 

build_avc_vcr_hdtv.zip 0.3623046875k . file

 

avc_hdtv_record_source.zip 13.033203125k . file
Denbo_33 is offline  
Sponsored Links
Advertisement
 
post #2 of 58 Old 10-09-2006, 04:53 PM
AVS Special Member
 
timecop's Avatar
 
Join Date: Jul 2003
Location: Japan
Posts: 1,135
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
That's pretty cool, but I stopped reading after
"You can Record and playback (playback with VLC) 5C protected Digital content, at least up to copy once level, I haven't seen a copy never level of 5C yet."
timecop is offline  
post #3 of 58 Old 10-09-2006, 06:01 PM
 
HDTVFanAtic's Avatar
 
Join Date: Mar 2004
Location: 3rd Rock from the Sun
Posts: 8,143
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Huh? Linux is not going to decrypt 5c copy once content. What is that guy smoking?
HDTVFanAtic is offline  
post #4 of 58 Old 10-10-2006, 06:54 PM - Thread Starter
Member
 
Denbo_33's Avatar
 
Join Date: Nov 2005
Posts: 46
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
The 1394 stream from the source (Samsung HDTV) is NOT Encrypted, so Decryption is not needed. At first I thought this might be a Samsung software bug. But the more I think about it most likely it is not. Avc uses a protocol call Function Control (FCP), FCP issues commands ,responses, and status between the 1394 devices. the unit and subunit INFO command which has a number of responses, Video monitor, disc recorder/playe,tape recorder/player, Tuner, Video camera , all of these devices or units (but the monitor and tuner) have the ability to record. Avc_vcr.c ( Libavc1394 source example, which I hacked and renamed to avc_hdtv.c) responded as a tape recorder/player, which worked fine for 5C copy free content, but transmitted garbage (encrypted) streams with 5C copy once content. I then change the response to this info command to Video monitor, unit and subunit types and bingo 5C copy once content was not encrypted. Sweet! Video monitors are pretty much dumb devices on any interface.
Denbo_33 is offline  
post #5 of 58 Old 10-10-2006, 10:07 PM
Member
 
ddennedy's Avatar
 
Join Date: Feb 2002
Location: Cincinnati, OH
Posts: 47
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
you're welcome!
ddennedy is offline  
post #6 of 58 Old 10-11-2006, 04:51 PM
 
HDTVFanAtic's Avatar
 
Join Date: Mar 2004
Location: 3rd Rock from the Sun
Posts: 8,143
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by Denbo_33 View Post

The 1394 stream from the source (Samsung HDTV) is NOT Encrypted, so Decryption is not needed. At first I thought this might be a Samsung software bug. But the more I think about it most likely it is not. Avc uses a protocol call Function Control (FCP), FCP issues commands ,responses, and status between the 1394 devices. the unit and subunit INFO command which has a number of responses, Video monitor, disc recorder/playe,tape recorder/player, Tuner, Video camera , all of these devices or units (but the monitor and tuner) have the ability to record. Avc_vcr.c ( Libavc1394 source example, which I hacked and renamed to avc_hdtv.c) responded as a tape recorder/player, which worked fine for 5C copy free content, but transmitted garbage (encrypted) streams with 5C copy once content. I then change the response to this info command to Video monitor, unit and subunit types and bingo 5C copy once content was not encrypted. Sweet! Video monitors are pretty much dumb devices on any interface.

For the second time, if its not encrypted, its not copy once - its copy freely and about any o/s can capture it.

If its copy once, IT IS 5C ENCRYPTED, and linux, mac or windows isn't going to decode it.
HDTVFanAtic is offline  
post #7 of 58 Old 10-11-2006, 05:12 PM
AVS Special Member
 
timecop's Avatar
 
Join Date: Jul 2003
Location: Japan
Posts: 1,135
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:


I have been able to record and playback local HD broadcasts with an antenna as the source will excellent sound and picture. Record and playback is hit and miss via cablecard, sound and picture are out of sync.

In the remote chance that Samsung firmware IS wrong and does not enforce 5C when connected to AV/C Monitor, it would result in quick revocation of their DTLA license. But from your comment above, I'm just going to go with "yay, he can record OTA HD using a $3000 TV when I could do the same thing with a USB ATSC tuner box that cost $80 using Windows XP Professional".
timecop is offline  
post #8 of 58 Old 10-11-2006, 07:32 PM
 
HDTVFanAtic's Avatar
 
Join Date: Mar 2004
Location: 3rd Rock from the Sun
Posts: 8,143
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
If the Samsung had a bug and ignored 5c codes, it would ignore all 5c codes - not copy once and obey copy never.
HDTVFanAtic is offline  
post #9 of 58 Old 10-12-2006, 09:49 AM
AVS Addicted Member
 
DaveFi's Avatar
 
Join Date: Nov 2002
Location: Natick MA
Posts: 17,174
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 26
How stable is the recording? PC Firewire to DVHS over XP is notoriously glitchy.

Hmm, nevermind. I see this isn't PC to DVHS at all.

XBOX Live: Wagmman
PSN: Wagg
BFBC2: Wagman
Steam: Wag

My Second Life character looks and acts exactly like me except he can fly.
DaveFi is offline  
post #10 of 58 Old 10-12-2006, 12:59 PM
 
HDTVFanAtic's Avatar
 
Join Date: Mar 2004
Location: 3rd Rock from the Sun
Posts: 8,143
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
considering stb to mac is very stable, one would think linux COULD be very stable depending on the drives. We all know the XP IEEE1394 drivers are not very good.
HDTVFanAtic is offline  
post #11 of 58 Old 10-16-2006, 04:31 PM - Thread Starter
Member
 
Denbo_33's Avatar
 
Join Date: Nov 2005
Posts: 46
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by DaveFi View Post

How stable is the recording? PC Firewire to DVHS over XP is notoriously glitchy.

Hmm, nevermind. I see this isn't PC to DVHS at all.

Should work with any Audio/Video Control (av/c) device. Settop box, DVHS, Monitor, Tuner, At least for 5C copy free content.
I connected the Linux machine to a XP machine, Xp found the Linux machine as a Tape recorder, and I was able to capture with CapDVHS.exe 0..3.6, CapDVHS crashed after about 2 minutes, I hear that happens quite often with CapDVHS. Had a look at the received file and looked ok( sync byte and time stamp ).
While testing and debugging I referred to the JVC 1394 Interface Implementation Guideline for D-VHS Version 1.00.
What is your DVHS make and model number? I'll try to help.
Denbo_33 is offline  
post #12 of 58 Old 10-21-2006, 01:52 PM
Member
 
thurstonw's Avatar
 
Join Date: May 2004
Posts: 83
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by Denbo_33 View Post

Should work with any Audio/Video Control (av/c) device. Settop box, DVHS, Monitor, Tuner.

I've been able to compile and run your avc_hdtv tool. (yeah, I caught the _den name issue). I've been using the mac FWSDK20 tools to control it. I noticed the type returned is type 0 (monitor). Whereas Virtual DVHS returns type 4 (VCR). How to I change setrom to set the type to 4? My LG3410A doesn't seem to recognize avc_hdtv as a DVHS deck. I believe it is because the type is wrong.

TW
thurstonw is offline  
post #13 of 58 Old 10-21-2006, 02:43 PM - Thread Starter
Member
 
Denbo_33's Avatar
 
Join Date: Nov 2005
Posts: 46
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by thurstonw View Post

I've been able to compile and run your avc_hdtv tool. (yeah, I caught the _den name issue). I've been using the mac FWSDK20 tools to control it. I noticed the type returned is type 0 (monitor). Whereas Virtual DVHS returns type 4 (VCR). How to I change setrom to set the type to 4? My LG3410A doesn't seem to recognize avc_hdtv as a DVHS deck. I believe it is because the type is wrong.

TW

Change two lines in avc_vcr_hdtv.c AVC1394_SUBUNIT_VIDEO_MONITOR << 3 ; to AVC1394_SUBUNIT_TAPE_RECORDER << 3 ;
Denbo_33 is offline  
post #14 of 58 Old 10-22-2006, 12:55 PM
Member
 
curtvm's Avatar
 
Join Date: Mar 2004
Posts: 93
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by Denbo_33 View Post

..My system a SAMSUNG DLP HLRxx68w and a 5 year old PC.

..Also have not tried recording a SD source. But who would want too?

I have an HLR5678w, I've been trying various things for firewire playback- virtual d-vhs,firebus dtv- now I have one more thing to try.

You probably know this already, but the hlr will not put out the sd channels via firewire (I think Toshiba and Mitsubishi tv's do- they must have an encoder built-in).

Couple questions, if I may-

1. Have you been able to get the tv guide interface on the hlr to schedule a recording of a digital channel?

2. Is there any way to get linux to act like a avhdd? I'm mainly interested in playback of r5000 recordings, and with an avhdd type setup, I can use the tv interface to select recordings to watch, instead of having to first 'load' the recording in a d-vhs type setup.

Thanks!
curtvm is offline  
post #15 of 58 Old 10-24-2006, 08:19 AM
Member
 
curtvm's Avatar
 
Join Date: Mar 2004
Posts: 93
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
and question #3-

Any other distribution besides fc5 work as described? The key I assume is a recent kernel and development tools. (looking for a smaller download- something like a minimal slackware install- only what's needed.)

Probably the smart thing to do would be to just get rid of my firewire cables- or put epoxy in all my firewire ports- so I just forget about it and move on to other equally unimportant things. (Maybe I could develop a special firewire connector with 2-part epoxy inside- plug in, squeeze, wait, all firewire problems go away. "Five-minute-Firewire-Fix" (tm) in 6-pin and 4-pin versions)
curtvm is offline  
post #16 of 58 Old 10-26-2006, 05:39 PM - Thread Starter
Member
 
Denbo_33's Avatar
 
Join Date: Nov 2005
Posts: 46
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by curtvm View Post

I have an HLR5678w, I've been trying various things for firewire playback- virtual d-vhs,firebus dtv- now I have one more thing to try.

You probably know this already, but the hlr will not put out the sd channels via firewire (I think Toshiba and Mitsubishi tv's do- they must have an encoder built-in).

Couple questions, if I may-

1. Have you been able to get the tv guide interface on the hlr to schedule a recording of a digital channel?

2. Is there any way to get linux to act like a avhdd? I'm mainly interested in playback of r5000 recordings, and with an avhdd type setup, I can use the tv interface to select recordings to watch, instead of having to first 'load' the recording in a d-vhs type setup.

Thanks!

1. No TV guide did not recognize the 1394 vcr device, I am still having problems with an analog vcr.
There is an example code in libavc1394, panelctl, which controls a Motorola DCT 6200/6400 series settop box. as in navigating through the menu, I have too have a look at the code this weekend.
2. I am sure there is a way, but I don't have the spec for avhdd :-(
3. You are correct sir.
Denbo_33 is offline  
post #17 of 58 Old 10-27-2006, 06:55 PM
AVS Special Member
 
timecop's Avatar
 
Join Date: Jul 2003
Location: Japan
Posts: 1,135
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
I have all 1394-related specs, contact me if you need them, however I have doubts of you ever coming up with anything that hasnt been done already.
timecop is offline  
post #18 of 58 Old 11-02-2006, 03:35 AM
Member
 
curtvm's Avatar
 
Join Date: Mar 2004
Posts: 93
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Well, I tried it even though I don't know what I'm doing. Got Ubuntu 6.10. Installed to hard drive. Installed g++. Got libraw/libiec61883/libavc. Compiled these 3 (don't know if there is easier way for ubuntu). Then followed above instructions. File download- bulid_avc_vcr_hdtv.sh - rename to build_avc_vcr_hdtv.sh (build mispelled). Also "Build test-mpeg2.c" "make" did nothing, so I used same instruction/command as "Build mpg1394grab.c" "gcc ....."

I can capture/playback ok from/to tv. But am unable to play any of my previous ts captures. I get "couldn't find a PCR within 20000 packets; giving up". Tried playing these streams with vlc on same ubuntu pc, but would not play with vlc either. (stream captured from tv wouldn't play with vlc either, so maybe vlc is screwed up in my ubuntu).

If I could get a simple way to play ts streams through firewire, that would be nice (don't care about recording). A stripped down linux with just enough to make it work would be ideal- maybe run in a virtual machine on my xp laptop using vmware or something (would that work?)- then I could use my laptop to record from R5000, and also playback to tv using same laptop.
curtvm is offline  
post #19 of 58 Old 11-02-2006, 05:45 AM
AVS Special Member
 
timecop's Avatar
 
Join Date: Jul 2003
Location: Japan
Posts: 1,135
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
im guessing if you got streams that are crap after recording those channels are 5C'd.
timecop is offline  
post #20 of 58 Old 11-02-2006, 07:33 AM
Member
 
curtvm's Avatar
 
Join Date: Mar 2004
Posts: 93
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by timecop View Post

im guessing if you got streams that are crap after recording those channels are 5C'd.

Well, these streams are recorded from the R5000 (5C not involved), they play fine on my laptop with WinXP, they just don't want to go out through firewire with the ubuntu setup. They also stream out ok via an imac mini using Virtual-dvhs. So its just a matter of a broken firewire setup on the ubuntu (did I mention I don't know what I'm doing in linux, sort of). The stream I recorded from tv (also no 5C) with ubuntu streamed back out to tv ok, but vlc didn't like it either.
curtvm is offline  
post #21 of 58 Old 11-02-2006, 09:45 AM - Thread Starter
Member
 
Denbo_33's Avatar
 
Join Date: Nov 2005
Posts: 46
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by curtvm View Post

Well, I tried it even though I don't know what I'm doing. Got Ubuntu 6.10. Installed to hard drive. Installed g++. Got libraw/libiec61883/libavc. Compiled these 3 (don't know if there is easier way for ubuntu). Then followed above instructions. File download- bulid_avc_vcr_hdtv.sh - rename to build_avc_vcr_hdtv.sh (build mispelled). Also "Build test-mpeg2.c" "make" did nothing, so I used same instruction/command as "Build mpg1394grab.c" "gcc ....."

I can capture/playback ok from/to tv. But am unable to play any of my previous ts captures. I get "couldn't find a PCR within 20000 packets; giving up". Tried playing these streams with vlc on same ubuntu pc, but would not play with vlc either. (stream captured from tv wouldn't play with vlc either, so maybe vlc is screwed up in my ubuntu).

If I could get a simple way to play ts streams through firewire, that would be nice (don't care about recording). A stripped down linux with just enough to make it work would be ideal- maybe run in a virtual machine on my xp laptop using vmware or something (would that work?)- then I could use my laptop to record from R5000, and also playback to tv using same laptop.

Damn I wish I could find my eye glasses! I'll correct the typos later.

test-mpeg2 complains with "couldn't find a PCR within 20000 packets; giving up" when a Program Clock Reference (PCR) packet , not to be confused with Plug Control Register, is not found within the ts stream file , a PCR packet is used to sync the receiver to the transmitter clock.

Not that it should matter, which RD5000 interface are you using to capture USB or 1394? .

I have downloaded the HD transport stream sample files from RD5000 website (http://www.nextcomwireless.com/r5000/samples.htm) and had no problems with playback to the Samsung HLR.

Use TSReader Lite, there is a link to this free tool on nextcomwireless.com website), to determine what or if there is a PCR packet within your previous ts captures. It will be listed under the "PAT PID" and should have the same value as the video PID.

If there is a PCR packet then you could try reducing PCR_SMOOTH_INTERVAL or increase MAX_PCR_LOOKAHEAD, let me know via pm and I'll help you out.

If there is not a PCR packet then RD5000 might be stripping it out?

Playback via VLC on linux had a lot of jitter but I had no problems with VLC playback on windoz XP.

To build test-mpeg2.c remove test-mpeg2.o as in

"rm /home/(user account)/ieee_project/ libiec61883-1.0.0/examples/ test-mpeg2.o

then
"make"
Denbo_33 is offline  
post #22 of 58 Old 11-02-2006, 11:28 PM
Member
 
curtvm's Avatar
 
Join Date: Mar 2004
Posts: 93
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Tried again. Now it won't even playback my captures from the tv- same PCR problem as with my other ts streams. (Unable to find PCR_SMOOTH_INTERVAL or MAX_PCR_LOOKAHEAD- I suspect changing these won't help anyway)

My previous streams have PCR packet, and play fine through anything that will handle ts streams- vlc on winxp,wmp w/purevideo decoder,imac virtual d-vhs via firewire,etc- so its not a problem with my files, but with my linux setup.

I probably just need to get FC5 and then follow your instructions. I suspect my Ubuntu setup is different somewhere -causing problems.

Even if I could get this to work, its not convenient enough (for me) yet- need to get node numbers first, a couple terminal windows open, etc. (I'm sure this could be automated by someone smart, but I don't think I could do it).

I need to get out of the deep end of the pool, stay in the shallow water where its safe.


by the way- I just got a HDHomeRun unit (dual hdtv tuner- stream over ip/udp). This is what tv manufacturers should be doing instead of firewire (since hardly anybody puts firewire on tv anymore) - put a network jack on tv to receive streams over udp. Plenty of hardware engineers/programmers can handle ethernet (I'm guessing only a few dozen in the world that can do firewire stuff properly). HDTV's already have mpeg decoders built in- just need an incoming stream from somewhere- internal tuner/dvd player/computer/remote tuner/etc.

Just a thought.
curtvm is offline  
post #23 of 58 Old 11-03-2006, 12:19 AM
AVS Special Member
 
timecop's Avatar
 
Join Date: Jul 2003
Location: Japan
Posts: 1,135
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Name one TV with built in MPEG2 decoder and no firewire.
Oh, right.
timecop is offline  
post #24 of 58 Old 11-03-2006, 01:51 AM
Member
 
curtvm's Avatar
 
Join Date: Mar 2004
Posts: 93
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by timecop View Post

Name one TV with built in MPEG2 decoder and no firewire.
Oh, right.

How about every tv with a atsc tuner built-in?

Maybe I'm incorrect (it happens alot), but every HDTV with built-in hd tuner must have one. How does the mpeg2 hd streams from the tuner get to the screen?

atsc (8vsb or qam) tuner -> ts -> demux? -> mpeg2 stream -> mpeg2 decoder -> super-duper video/audio chips -> screen/speakers ??

So if they would put a "ethernet board" in the tv, which just decodes udp packets and makes a ts stream, and inserts the stream where the tuner "outputs", it should be the same digital "signal".
curtvm is offline  
post #25 of 58 Old 11-05-2006, 07:03 AM - Thread Starter
Member
 
Denbo_33's Avatar
 
Join Date: Nov 2005
Posts: 46
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
>>playback my captures from the tv-
You will need to capture at least 100MB file.
>> My previous streams have PCR packet
Would you sent me a captured stream so I can try to play back on my Samsung?


>>Even if I could get this to work,

I agree, I have often recorded a zero length file by entering the wrong node number. But if we can prove that this works on enough systems (set tops, D-vhs, HDTV, etc) it would then generate interest from the Linux folks to help with the code development.

>> need to get out of the deep end of the pool

I don't think you are giving yourself enough credit, you got this working!! Well almost.
Denbo_33 is offline  
post #26 of 58 Old 11-07-2006, 04:39 AM
Member
 
curtvm's Avatar
 
Join Date: Mar 2004
Posts: 93
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by Denbo_33 View Post

Would you sent me a captured stream so I can try to play back on my Samsung?

I'm not sure how to get a large file to you.

Quote:
Originally Posted by Denbo_33 View Post

..if we can prove that this works on enough systems (set tops, D-vhs, HDTV, etc) it would then generate interest from the Linux folks to help with the code development.

I think its just you and me. I just ordered a Zensonic Z500. Now its just you

Looking at the new tv's, it looks like Samsung is the only one making sets with firewire that I can tell. Although if you get one, what exactly are you supposed to buy to take advantage of these ports? A new d-vhs? An AVHDD? Who makes or sells these (new)? Samsung doesn't. I doesn't look like firewire will be seen on tv's anymore.

I have a schematic for my hlr5678w, and it looks like it would be easier to hack together something to just send out a ts stream through the parallel port of the pc, tapping into one of the ts stream locations on the tv digital board. I'm only half kidding. A ts stream out of (each) tuner-1 data byte, 3 control bits. Actually, I don't think a parallel port would be fast enough, but usb 2.0 would work. Ethernet would work.

A neat thing I did when I had the imac sending ts streams through firewire- put in a dvd movie, play with vlc, stream to a file using mpeg-ts encapsulation, open same file using virtual-dvhs, play to tv. I thought that was pretty cool- streaming a dvd over firewire in real-time. If I knew how to use 'mkpipe' or mkfifo', then I could have just piped from vlc to virtual d-vhs without a real file.
curtvm is offline  
post #27 of 58 Old 11-07-2006, 08:13 AM
AVS Special Member
 
timecop's Avatar
 
Join Date: Jul 2003
Location: Japan
Posts: 1,135
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:


and it looks like it would be easier to hack together something to just send out a ts stream through the parallel port of the pc, tapping into one of the ts stream locations on the tv digital board.

You're going to be about 28mbit short on parallel port bandwidth there buddy.
Also enjoy it when the feds will tap on your door with a DMCA warrant
timecop is offline  
post #28 of 58 Old 11-07-2006, 10:01 AM
Member
 
curtvm's Avatar
 
Join Date: Mar 2004
Posts: 93
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Quote:
Originally Posted by timecop View Post

You're going to be about 28mbit short on parallel port bandwidth there buddy.
Also enjoy it when the feds will tap on your door with a DMCA warrant

Yes, parallel was just a tongue-in-cheek expression to show how easy it would be compared to figuring out firewire programming. I should have said serial port to make it more obvious. I don't know exactly how fast a parallel port can move data, but 19.2 megabits-per-second is alot of bits moving in a hurry. 19.2/8= 2.4 megabytes-per-second?

I know zero about dmca, except I know what the letters stand for. I'm not worried about anybody coming after me for fiddling with my own tv. I'd probably get electrocuted before I could make my project work anyway (or die of old age). Also, I'm not trying to bypass anything, I would just be moving bits from my pc to my tv- one way - and bits that are 'legal' bits. Just another input using the ts decoding power of the tv. No different than making an 'atsc modulator' and plugging it into the antenna jack (another idea - a channel 3.1 modulator so we can hook up our HD pong video game ).

If my Z500 works good, I can forget all about shoving transport streams up and down tiny wires anyway. (ok, they would still be moving over wires, but no complex thought on my part will be needed.)
curtvm is offline  
post #29 of 58 Old 11-08-2006, 12:42 PM
AVS Special Member
 
v1rtu0s1ty's Avatar
 
Join Date: Feb 2005
Location: n0rth3rn 1ll1n01s
Posts: 3,237
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
Do you think guys this will work with the connections I'm planning to implement? Below is the connection I've tried before with MythTV but didn't capture anything. I didn't modify any .c codes before though.

HDTV<----rgbhvcable<----FC3LINUX<----IEEE1394cable<----DCT6200
v1rtu0s1ty is offline  
post #30 of 58 Old 11-08-2006, 09:45 PM
AVS Special Member
 
v1rtu0s1ty's Avatar
 
Join Date: Feb 2005
Location: n0rth3rn 1ll1n01s
Posts: 3,237
Mentioned: 0 Post(s)
Tagged: 0 Thread(s)
Quoted: 0 Post(s)
Liked: 10
I tried this guys and I can only record and watch local high def channels such as NBC-5, CBS, FOX, WGN, etc.

I tried recording a 5c content channel, and YES, file size wasn't zero but mplayer DID NOT understand the file, neither VLC can play it too.
v1rtu0s1ty is offline  
Reply Firewire 1394 Trade Association Q&A

User Tag List

Thread Tools
Show Printable Version Show Printable Version
Email this Page Email this Page


Forum Jump: 

Posting Rules  
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off