My favorites | Sign in
Project Home Downloads Wiki Issues Source
Search
for
InstallingOSTVpt3_More_Plugins  
This page covers installing the webvideo, schedule, bittorrent and webstreams plugins.
Phase-Deploy, Featured
Updated Oct 10, 2009 by manzanit...@gmail.com

Schedule

to install:

$ ostv install_class schedule

The Schedule plugin will:

  1. record OTA/QAM one time, weekly, Monday through Friday or daily.
  2. schedule a bittorent download weekly, Monday through Friday or daily.
  3. schedule a Web Video menu update weekly, Monday through Friday or daily.
Schedule, obviously, needs either or all of the OTA, bittorrent and webvideo plugins installed.

If you compiled MPlayer yourself and used "make install" it will often be in /usr/local/bin and this probably will need to be added to your crontab's path in the first line. Those who compiled with "check install" will not have worry about this as the the executable will be in usr/bin. Check your crontab by

$ crontab -l

If the path doesn't show in something like this

PATH=/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/bin
add it by editing your crontab:

$ crontab -e

The default editor is often the difficult vim. If you do not want to go through a steep learning curve for something as simple as a text editor, Nano is an editor that is much easier to use. Crontab cannot be edited by gedit or kedit. Before the above command type "editor=nano" at the command line to switch editors. To do this permanently open ~/.bashrc in your favorite text editor and add the line "export EDITOR=nano"

Bittorrent

to install:

step #1

This plugin only works with the Deluge bittorent client. If necessary install Deluge. It is likely available from your package manager

The Deluge bittorent client is an excellent, lightweight program.

step #2

$ ostv install_class bittorrent

step #3

The file ostv_bittorrent in your ~/.ostv/ needs to be moved into the /usr/bin folder. Cut and paste it or:

$ sudo mv ~/.ostv/ostv_bittorrent /usr/bin/

step #4

Make folders for the torrents and for the downloads:

$ cd ~
$ mkdir torrents
$ mkdir recordings/bittorrent

Be sure to go into Deluge and set your preferences. Set your downloads directory to ~/recordings/bittorrent, set stop at share ratio to something reasonable and remove torrent at share ratio unless you do not mind seeding indefinitely.

Torrents can be scheduled with the schedule plugin or downloaded from the command line. If OSTV Bittorrent doesn't find a torrent it will send a notification if you install libnotify-bin (command line only). libnotify-bin is probably in your package manager.

See UsingOSTV

Webvideo

to install:

$ ostv install_class webvideo

OSTV accesses web video that has an xml or rss feed and and a downloadable video file by virtue of the webvideo plugin. This requires a small configuration file in ~/.ostv/webvideo. These folders need to be created:

$ mkdir recordings/webvideo
$ cd .ostv
$ mkdir webvideo
$ mkdir menu/Main/Watch/WebPrograms

and optionally

$ mkdir menu/Main/Watch/WebChannels

WebChannels is a way to group multiple WebPrograms. For instance you could create a Youtube Heavy Metal channel and include Pantera, Metallica, Corosion of Conformity and Megadeath videos.

  • Create a webvideo config file with the name of your WebProgram or WebChannel and save it in ~/.ostv/webvideo

Sample webvideo config files

Youtube

Youtube the Tour de France

This can be used for any Youtube feed with a different url

Prerequisite for Youtube is the program youtube-dl. youtube-dl is available from most package managers. take a look at youtubefeeds wikipage to learn how to construct your own youtube xml feeds.

url="http://gdata.youtube.com/feeds/api/videos?vq=tour%20de%20france"
xml_getter="xmllint -format"
elem_lgth=12
title_element="<media:title"
description_element="<media:descr"
duration_element="<yt:duration"
duration_attribute="seconds"
link_element="<media:playe"
link_attribute="url"
alt_dl_cmd="youtube-dl+-o"
duration_func="duration"

Cranky Geeks

Cranky Geeks is a Computer discussion show hosted by longtime PCMag Columnist John Dvorak

url="http://feeds2.feedburner.com/ziffdavis/cgh264video?format=xml"
xml_getter="xmllint -format"
elem_lgth=13
title_element="<title>Cranky"
description_element="<itunes:subti"
duration_element="<itunes:durat"
link_element="<media:conten"
link_attribute="url"

Democracy Now

Democracy Now is a left wing News and Current Events show.

url="http://www.democracynow.org/podcast-video.xml"
elem_lgth=12
link_element="<media:conte"
link_attribute="url"
#duration_attribute="duration"
title_element="<media:title"
description_element="<media:descr"
duration_element="<itunes:dura"

WebChannels

For webchannels, do not include a url value in the config file. Create a file with the same name as the webvideo/configfile and save it in ~/.ostv/channels. For each program in the channel on a separate line:

name of program:url of feed

example:

Pantera:http://gdata.youtube.com/feeds/api/videos/-/Music/?q=Pantera&orderby=relevance
Metallica:http://gdata.youtube.com/feeds/api/videos/-/Music/?q=Metallica&orderby=relevance
Corosion of Conformity:http://gdata.youtube.com/feeds/api/videos/-/Music/?q=Corosion%20of%20Conformity&orderby=relevanc
Megadeath:http://gdata.youtube.com/feeds/api/videos/-/Music/?q=Megadeath&orderby=relevance

After you create and save the your file in ~/.ostv/webvideo you will be able to create the menu by going to main->Utilities->Update-Menus. You can schedule menu updates with the Schedule plugin too.

Config file Specifics

As OSTV catches on -- if it does -- it is expected that only more advanced users will put together webvideo config files and share them. Most users will just copy them. Here is the Cranky Geeks config file with a bunch of comments of explanation:

#remove or comment out empty values
#
###### programs only #########################
#only for programs, if it is a channel(group of programs) put group of programs in a file in ~/.ostv/channels/ 
#Name file the same as this file, + remove or comment out
#The url of the Program's xml or rss feed
url="http://feeds2.feedburner.com/ziffdavis/cgh264video?format=xml"
#
###### end programs only #####################
#
##########################################
##xml_getter 
#is the program that downloads the xml/rss feed file(s)
#default is wget, xmllint -format is an alternative, youtube, for instance, needs it to make line endings
#leave commented out for default
xml_getter="xmllint -format"
#
##########################################
##  xml element data
#the xml elements where program title, description, link, duration + thumbnail are
#elem_lgth is the length of the element strings
#nec. for processing, element strings need to be same length
elem_lgth=13
title_element="<title>Cranky"
description_element="<itunes:subti"
duration_element="<itunes:durat"
#duration_attribute="second"
link_element="<media:conten"
link_attribute="url"
#not currently supported but could be in the future
#thumbnail_element="<media:thumb"
#thumbnail_attribute="url"
#
##########################################
##  alt_dl_cmd
#this is the command webvideo will use to download the video file
#default is wget. leave commented out or remove for default
#youtube for instance uses youtube-dl
#the command is:
#youtube-dl -o filetobesaved linkofdownload
#ostv handles the args, but needs the option specific to youtube-dl
#so this is what it should look like:
#this command needs spaces replaced with +
#instead of
#alt_dl_cmd="youtube-dl -o"
#do this
#alt_dl_cmd="youtube-dl+-o"
#if you want to use a function that will not work like this:
#mycommand <options> filetobesaved linkofdownload
#then you need to write another function, which would be the alt_dl_cmd
#this function would format filetobesaved linkofdownload 
#so the actual downloading function would work
#alt_dl_cmd=
#
##########################################
#if a duration element is in seconds, and needs to be 
#converted to a readable mm:ss
#duration_func="duration"

Webstreams

to install:

$ ostv install_class webstreams

Webstreams accesses streaming video channels from the web in OSTV. These are usually from the mms: or rtsp: protocols.

Create a file "webstreams" in ~/.ostv/channels

for each webstream on a separate line:

name of stream:url of stream

You can name it anything you wish.

example:

CSPAN1:mms://rx-wes-sea159.rbn.com/farm/pull/tx-rbn-sea001:1459/wmtencoder/cspan/cspan/wmlive/cspan1v.asf
CSPAN2:mms://rx-wes-sea157.rbn.com/farm/pull/tx-rbn-sea004:1459/wmtencoder/cspan/cspan/wmlive/cspan2v.asf
CSPAN3:mms://rx-wes-sea156.rbn.com/farm/pull/tx-rbn-sea007:1459/wmtencoder/cspan/cspan/wmlive/cspan3v.asf
NBCNews:mms://msnbc.wmod.llnwd.net/a275/e1/video/100/vh.asf

This plugin is not recommended, I do not have it installed. This protocol assumes that webvideo can be streamed like OTA TV. OTA TV is a direct stream and transmission is the same for 1 or 100,000, while web video has countless nodes to get tripped up on and servers that bog down with greater usage. I have not found any webstream that is the least bit watchable. Has anybody found one? There are websites that specialize in this --they are a waste of time! The other methods OSTV uses for TV/Video seem to be the future.


Sign in to add a comment
Powered by Google Project Hosting