[mythtv-users] Using mythtv and PVR-350 to capture from video camera

Michael T. Dean mtdean at thirdcontact.com
Wed Oct 25 07:44:55 UTC 2006

On 10/24/06 21:51, Jason Surprise wrote:

>The PVR-350 has svideo and composite inputs.  Is there a way to set up 
>mythtv to be able to capture from these sources, and hook up my video 
>camera to use the PVR-350 to convert to mpeg2?
Shut down mythfrontend and mythbackend. Run mythtv-setup.

In "Video Sources", create a new video source (i.e. "VCR" or "Digital 
Video Camera" or "External" or whatever--just make sure you give it a 
name).  For the grabber, select, "No grabber."  Select "Finish".  Hit 
Escape to go back to the menu.

In "Channels", create a new channel.  Give it a name (like "VCR" or 
"Camera" or "External" or ...) and a unique channel number (one that 
doesn't yet exist on your system) and callsign ("VCR", "Cam", "Ext", 
"Other Stuff", ...).  Select the video source you just created.  While 
you're at it, you'll probably want to mark the channel as commercial 
free (depends on your home movies, I guess :).  Select "Next."  Do /not/ 
change the "Frequency or Channel" field--it should be exactly the same 
as the channel number you specified previously.  Select "Finish".  Hit 
Escape to go back to the menu.

In "Input Connections", associate the new source to the appropriate 
input.  Set the "External channel change command" to "/bin/true" (no 
quotes).  Do /not/ fill in a value for "Preset tuner to channel", do 
/not/ "Scan for channels" or "Fetch channels from listings source".  
Ensure the channel you just created is selected as the starting 
channel.  Select "Finish".  Hit Escape to go back to the menu.

Exit mythtv-setup.  You'll be told to run mythfilldatabase, but--since 
your new source uses "No grabber", it's unnecessary.  So, start up 
mythbackend and mythfrontend.  Then, create manual recording schedules 
to record from your camera.

What?  Manual recording schedules?


Using manual recording schedules is not ideal because it's 
non-interactive (as a PVR should be).  So, when creating a manual 
recording, you'll be able to specify a name (which is good), but you 
must specify a start time and an end time (which isn't so good).  
Therefore, you have to guess the content's length and specify a 
longer-than-the-content recording time to allow for starting the video 
sometime after the recording starts and ensuring it ends sometime before 
the recording stops.

Note, though, that if you start watching LiveTV and hit record, Myth 
will create a 30-minute manual recording starting at the time you press 
record.  If you need to extend the recording time, you will have to exit 
LiveTV and modify the end time on the in-progress recording before the 
recording finishes.  Also, recordings made on "channels" with no guide 
data will get terrible names if recorded from LiveTV with the record 
button, so manual recordings--which allow specifying names for the 
recordings--are much more appropriate.

If you just "watch" LiveTV to do the recordings, Myth will in fact 
record input; however, you'll encounter similar issues as with the 
record button.  Since you have no guide data, the recordings will have 
terrible names and will be broken into 30-minute segments.  I think with 
LiveTV, though, the first segment breaks on the half-hour--i.e. at the 
top of or half-past an hour on the clock, regardless of when you started 
watching LiveTV, so the first segment will be less than 30 minutes 
long.  Note, also, that it's critical that you change the recording 
group from LiveTV to something else if you record the video this 
way--otherwise, the recording will be autoexpired "tomorrow."

So, basically, although you can do as you asked, doing so is probably 
not what you want because Myth was designed as a PVR, not as an 
interactive recording application.  Therefore, it may actually make a 
lot more sense to just find a time when a capture card isn't in use and 
use "dd if=/dev/video4 of=/home/me/MySummerVacation.mpg".  (This example 
shows using capture card 5 because it's the least likely to be used for 
recordings.  If you only have 1 card, use "/dev/video0", or with 2 cards 
use "/dev/video1", or ...)  Note, though, that with this approach, 
you'll have to run the appropriate ivtvctl commands to set the format, 
resolution, and input before using dd to capture.

Something like:

ivtvctl -u 0x3000
ivtvctl -p 6
ivtvctl -f width=720,height=480
dd if=/dev/video4 of=/home/me/MySummerVacation.mpg

Should do.  Submit the last command--the dd command--when you're ready 
to start recording.  Then, when finished, use Ctrl-C to stop the 
recording (you may want to record a few seconds longer than necessary so 
you can clean up the end of the recording with an MPEG editor).


More information about the mythtv-users mailing list