NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public Hardware v
« Previous 1 … 144 145 146 147 148 … 263 Next »
Idea for QAM recording / live TV using External Recording Plugin and TVPI

 
  • 0 Vote(s) - 0 Average
Idea for QAM recording / live TV using External Recording Plugin and TVPI
sarcasm
Offline

Junior Member

Posts: 6
Threads: 3
Joined: Feb 2007
#1
2007-02-04, 05:47 PM
The Fusion HDTV software can respond to imported TVPI files (see http://en.wikipedia.org/wiki/TVPI). When a recording command is imported, the Fusion software stays minimized and the recorded .mpg or .tp is placed in the recordings directory. The recording can be stopped by closing the Fusion application (which can also be automated in various ways).

It should not be very difficult to use these features to enable QAM recording in GBPVR with the Fusion cards, and I intend to do this, but there is one problem. When FusionHDTV records an analog channel, the resulting MPG file is readable by GBPVR during recording, and the length of the recording even updates in real time as the show records, just like any other GBPVR recording, which is great. But, this does not work for digital recordings, and GBPVR is unable to read the output .mpg file until the recording stops in Fusion.

The error log shows this:
12:35:32.703 INFO DirectShowPlayerBase::playVideoFile(C:\DVR-RECORDINGS\2007-02-04(Sun)PM1235-CHD112.mpg)
12:35:32.703 VERBOSE File already in use - probably still recording
12:35:32.703 VERBOSE waited: 0 (0 - 1170610532) filesize: 0
.....
12:35:43.968 VERBOSE waited: 11 (0 - 1170610543) filesize: 0
12:35:44.062 ERROR DirectShowHelperVMR9::playFile() - Waited ten seconds, and file size is still zero!!!

So it appears that the Fusion app opens digital recording files for exclusive access but not analog ones. And apparently Windows Media Player and Media Player Classic also use exclusive access because they can't read the .mpg's for Fusion's analog recordings while GBPVR can.

Anyone have any ideas around this? I'm going to try editing the fusion binary to change the parameters of all CreateFile calls to allow shared file access, but first I gotta find the right tools to even do that. If anyone already has a good disassembler/re-assembler, maybe give that a shot?
sub
Online

Administrator

NextPVR HQ, New Zealand
Posts: 106,789
Threads: 769
Joined: Nov 2003
#2
2007-02-04, 06:25 PM
Yeah, I'm guessing youre probably correct and the fusion app is opening the file with exclusive access, no sharing allowed when recording digital.
sarcasm
Offline

Junior Member

Posts: 6
Threads: 3
Joined: Feb 2007
#3
2007-02-04, 11:14 PM
Got it! And it only took 3 hours of debugging. I can now record a QAM digital/HD channel with FusionHDTV 3.50.01 minimized and view the file while it is recording with GBPVR.

It took a while to find the spot that actually opens the file because it isn't in FusionHDTV.exe or any of its declared imports, it's actually in ZuluPsDump.Ax which is dynamically loaded. Only 2 bytes need to be changed:
0x15B9: change 00 to 01
0x2673: change 00 to 01

I doubt I can legally post the altered binary but I can post a patch that will make the changes if anyone wants that.

Next up is to do the actual GBPVR integration. The hooks/actions should be something like:
When LiveTV is started for some channel:
1) Create a tvpi file that says to record that channel starting immediately and for some very long amount of time and launch fusionhdtv with that file as its argument.
2) Make GBPVR start playing the resulting .mpg file.
When LiveTV is stopped
1) Kill FusionHDTV by sending it the WM_CLOSE message, it exits cleanly.
2) Delete the output file.
For recording the start/stop actions are the same except for deleting the output file, and maybe instead move it somewhere else or rename it or do whatever it takes to make it show up in the Recordings list in GBPVR.

Hopefully all of this is possible and it runs stably.
sarcasm
Offline

Junior Member

Posts: 6
Threads: 3
Joined: Feb 2007
#4
2007-02-12, 01:16 AM
If anyone is interested, I got FusionHDTV automation working. I can now record QAM channels and watch live TV (in timeshift mode) in GBPVR.

The integration is *almost* seamless, the fusionhdtv splash screen is seen briefly when it starts. When Live TV is started, it shows the "Entering Timeshift mode" for 11 seconds before the video starts. This is a long time but not likely to be improved as that is how long it takes fusionhdtv to start up and begin recording. Fusionhdtv.exe uses 2% cpu on my core2duo 2.4ghz machine while recording, as expected, the important thing is that it does not load the GUI at all so it does not wastefully decode the mpeg2 in the background.

The requirements for this are the External Recording plugin, Perl, and PsKill from Sysinternals, all of which are free of course.
oneonefive
Offline

Junior Member

Posts: 11
Threads: 0
Joined: Apr 2007
#5
2007-04-11, 02:12 AM
I have been trying to do this ever since I bought the fusion cards. Please send me details on how and what to do exactly to get this to work.
carpeVideo
Offline

Posting Freak

Posts: 824
Threads: 23
Joined: Dec 2006
#6
2007-04-11, 04:29 AM
I do this with my graphRecorder/TVPI plugin - although it doesn't work for live (it may with your modded binary)

You may want to check it out you don't need perl, etc. Although you may still need taskkill for changing channels if you do while watching live TV.

DVICO has told me they have BDA Qam drivers in the works, but not when the release date is.
whurlston
Offline

Posting Freak

Posts: 7,885
Threads: 102
Joined: Nov 2006
#7
2007-04-11, 07:11 AM
I did something similar to this with the HDHomeRun before they released the BDA drivers. I ended up rewriting most External Recorder code so that it launched the hdhomerun_config.exe to tune the channel, filter the program then start the stream. It also killed the exe when the recording/viewing session was finished via Thread.Process.

Not sure if I still have my C# project source code (hard drive crash), but I can pretty much remember it all if you are interested in integrating it this way. It would eliminate the Perl and PSKill requirements.
oneonefive
Offline

Junior Member

Posts: 11
Threads: 0
Joined: Apr 2007
#8
2007-04-12, 01:48 AM
I write code (c#) for living yet I am ashamed to say I do not understand how to get started. Are we talking about accessing guide data from somewhere (ex. xmltv or zap2it) and creating a .tvpi file that will cause dvico software to begin recording? What is the best way to map the qam channels? Do I store the data in a xml file? What tool will allow me to later view/search guide data?

As you can see I need a beginner's guide for this. I have been reading a lot of forums but still no clue I would really appreciate the help. BTW, I should mention I have two other friends on the same boat; so you will be helping all of us.
carpeVideo
Offline

Posting Freak

Posts: 824
Threads: 23
Joined: Dec 2006
#9
2007-04-12, 01:55 AM
If you use my plugin all you need to do is put the translations in the table and it will register the tvpi for you just before the recording should start. As I mentioned it works for recording but not timeshifting due to the issue above, but it looks like if you mod the driver it may work for both,
oneonefive
Offline

Junior Member

Posts: 11
Threads: 0
Joined: Apr 2007
#10
2007-04-13, 01:18 AM (This post was last modified: 2007-04-13, 10:26 PM by oneonefive.)
I am working on a graph that stops at the Fusion HDTV WDM Capture. What I cannot figure out how to write the .tp file from this box to my hard drive. I assume I have a .tp file at this point and I want to write it as is. I do not want to encode because of system resources but just want to write the .tp file. One other thing that I don't understand is where do the input box (that has the file name) come from in all the sample graphs?
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)

Pages (2): 1 2 Next »


Possibly Related Threads…
Thread Author Replies Views Last Post
  Is this reasonable CPU usage for recording without transcode ngeunit1 3 470 2025-04-01, 12:18 AM
Last Post: mvallevand
  External HDMI capture device? mattyb 22 14,581 2019-03-06, 04:44 PM
Last Post: sub
  WD Green for Recording Drive? Lao Pan 3 2,895 2018-03-05, 10:27 AM
Last Post: Lao Pan
  Recording HDD advice Jaggy 21 9,048 2015-10-30, 08:16 PM
Last Post: liteswap
  Anyway to stop a phantom live TV session caused by Kodi client crash? snorkel01 3 2,306 2015-04-17, 03:45 PM
Last Post: johnsonx42
  NextPVR and HD PVR 2 Issues - No Picture and No Sound on Live TV keithyv 5 4,550 2014-09-30, 03:09 PM
Last Post: keithyv
  laptop end external PCI closure via USB/expresscard - anyone used it? will it work? jasjol 10 4,797 2014-03-16, 02:41 AM
Last Post: jasjol
  Shaw Satellite and recording from HDMI port SFX Group 2 2,579 2013-11-06, 04:41 AM
Last Post: SFX Group
  Remote recording via Raspberry Pi??? SFX Group 2 2,469 2013-10-23, 12:42 AM
Last Post: SFX Group
  which recording hardware an CI - with CA-Module Crypto CAM CryptoGuard jasjol 4 3,357 2011-12-28, 03:31 PM
Last Post: Reddwarf

  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Designed by D&D, modified by NextPVR - Powered by MyBB

Linear Mode
Threaded Mode