Beyonwiz Software
Home Software list Board Login Register
Welcome, Guest. Please login or register.
Did you miss your activation email?
2009-01-07 19:48:40

Login with username, password and session length
Members
Total Members: 94
Latest: Donno
Stats
Total Posts: 98
Total Topics: 33
Online Today: 6
Online Ever: 39
(2008-08-07 13:30:23)
Users Online
Users: 0
Guests: 3
Total: 3
About this site
BeyonwizBeyonwiz creates combinations of Personal Video Recorders (PVR) and Media Centers. These devices can be used to receive and record broadcasted SD and HD data. Also videos (DivX, Xvid, MPEG-4, ...), music (MP3, Ogg, ...) and pictures (Jpg, ...) can be played with these devices.

This site lists software developed for Beyonwiz products.
Beyonwiz Software  |  Forum  |  Forum content  |  Software (Moderator: DaveŽ)  |  Topic: wiztimerd-0.2. To set timers on the Beyonwiz based on keywords « previous next »
Pages: [1] Print
Author Topic: wiztimerd-0.2. To set timers on the Beyonwiz based on keywords  (Read 717 times)
tonymy01
Newbie
*
Offline Offline

Device: DP-P1

Posts: 2


« on: 2008-07-03 07:49:19 »

wizTimerd 0.2
Provided by jim16, heavily modified, bug fixed etc to work with the Beyonwiz by tonymy01.

This is a perl application that will search for favourite shows based on various search criteria in your favourite XMLTV guide (supplied thru various means but not in the scope of this application, I recommend ICETV as they provide repeat flags etc).

Based on PerlTGD this script has xmltv2tgd integrated so that the searching is performed on a XML document.
Jim has removed all Topfield related routines such as detecting the connection of the unit, producing .tgd
files, rebooting the unit, transferring of files etc... and I have added most of them back again to work with wizremote running on the Beyonwiz now :-)

The code is still based to some extent on the TGD specification as there is no need to change (maybe). In this archive you will
find all the documents required to run this tool. run.sh will run the tool. The settings file is a working
file and there is a favourites and XML file included.

usage:
bash-3.2# perl wiztimerd.pl
wizTimerd version:0.2
usage: wizTimerd -option [-option]..
Where option=
all/a:    download, search, output timers, transfer, append
download:
search:
output:
transfer:
debug:
practise: will search XML, download timers from Wiz, show what will be deleted/set, but won't
          make changes on the Beyonwiz.  Use with other options except reboot.
reboot:   separate option to reboot beyonwiz for GUI to load timer changes MUST BE RUN SEPARATELY (as rebooting will stop any current recordings or timeshifting).


Requires wizremote installed on the Beyonwiz from Eric Fry to operate.   You are best to install wizremote into the Beyonwiz /tmp/config directory, rather than on the Beyonwiz HDD, as doing a HDD check (which the Beyonwiz will do if it has a bad shutdown for example) will fail when any application is currently open on the HDD.   /tmp/config is mounted from a flash sector on boot, and regularly saved during operation, and is maintained after a firmware upgrade too (it is where all the channel scan settings are stored, all timers and other Beywoniz settings).
See here for information about various opensourced projects for the Beyonwiz (and hints etc for installing applications to the Beyonwiz):
http://www.openwiz.org/wiki/Main_Page
You need to disable AES encryption for this to work (at the moment).  There are perl modules to support AES, so I will investigate this for the next release, unless someone else wants to give it a go.    To do this on the beyonwiz, simply rename the wizremote.key to wizremote.key.old, and to replace the wizremote_inc.php with the one in this zipfile.


Put all files from this zipfile into the one directory to run, edit the wizip and gmt depending on region and/or XML source (some won't need any offset added, and all timer information on the Beyonwiz is luckily in localtime).

You MUST either copy the wizremote web config_channels_inc.php generated by the Wizremote update_channels.php script from your webserver, or by running the attached perl update_channelinfo.pl script.   Make sure the created config_channels_inc.php is copied to the wiztimerd working directory (specified in wiztimerd.settings).    "./" means the current directory by the way.

I have been running commonly with: 
perl wiztimerd.pl -all 
perl wiztimerd.pl -all -practise if you don't want the application disturbing the beyonwiz timers (add or delete) at all, to observe the program behaviour and ensure everything is setup correctly first.

Settings file wiztimerd.settings now looks like this (use the attached file, the # here is just to explain the option)

favfile::favourites.ini
xmlfile::listings.xml
workdir::./
outputdir::./
wizip::ipaddress_of_beyonwiz (or hostname) must be setup to connect to the wizremote daemon
wizport::30464 (TCP port of wizremote).
channelfile::config_channels_inc.php  (you must either copy the channel config from the Web PHP wizremote, or run the "perl update_channelinfo.pl" script to obtain channel info, if you rename channels in the Beyonwiz, you must re-run this script and copy the channelfile to the working directory).
datestamp::DD/MM
gmt::10:00  #ICE XML is GMT reference, this will be added to make XML data localtime.
startbuffer::-00 #as the beyonwiz supports its own padding, this is best left at 00, although it will cope with real settings.  negative means starts earlier than forecast start by XXmins
endbuffer::+00 #positive padding means duration is extended by XXmins
join::+ #string used to join titles together when combining timers
showtitle::- #string used to join prog subtitle with main title, e.g Scrapheap Challenge-Steam Car
addtime::50 #minutes added if show is between addtime start/end minutes in the day (needs more work to, say, support 23:00 to 06:00 for example)
addtimestart::0
addtimeend::360
overrun::15 #minutes to add to the end of any shows that follow the overrun.shows listed shows
writelog::yes
transfer::
download::
repeatflag::\[Rpt\]  #the xml interpreter sees the ICE "<previously-shown" and puts [Rpt] into the description of the event, thus this is the flag.  The attached sample xml document is not ICE, for obvious copyright reasons, and doesn't have repeat flags it seems.
repeatmethod::
#left side of channel rename is ice/xml name, right side is PVR channel name.   This MUST be setup correctly or else you will end up with "phantom" times in the beyonwiz that don't have any channel reference to them (if the script detects a channel issue, it proceeds the timer name with an error message so you can edit in the Beyonwiz
renamechannels::"ABC1-ABC1:Seven HD-7 HD:Seven-7 Digital:Ten HD-10 HD:Ten-10 Digital:ABC2-ABC2:Nine HD-9 HD:Nine-9 Digital:SBS-SBS:SBS World News Digital-SBS News"
ignoretimers::daily #name of timers not to delete/modify.   I have a daily wakeup timer which I named "daily" (by making a real wiz timer to provide a name, then editing to a wakeup/view timer).
deleteok::no #wiztimerd will add and delete timers from the beyonwiz if it detects changes or new clashes.   If you don't want any timers deleted, then set this to no, else yes.   Wiztimerd appears to not delete any timers if it has no new timers to add, possibly to protect against, say, a day of no XMLTV data (or empty XMLTV file).


Still to do:
*Get the addtime working a bit better, currently it does a basic "if start time in minutes is between X and Y, add extra duration", but this doesn't work for, say, if you want to start this process at 11pm and finish it at 6am.
*Get a priority scheme working for HD vs SD channels, so that if a favourite matches on both channels, decide how to prioritise if you want the HD version or the SD version recorded.    At first you might think to just put the HD channels only into the search criteria in the favourites.ini file, however take 3 examples from real life:
Channel Nine had "Terminator: The Sarah Connor Chronicals" on both SD and HD at the same time, but when they introduced some trashy reality show to attempt to boost ratings (Scifi never rates really :sniff:), they moved T:TSCC after the trash show on SD, and didn't show it at all on HD (instead showing Nightline on HD!).
Channel Ten now puts MOTOGP and the F1 on the HD channel in "realtime" rather than delayed to after 10.30pm or later, and for that week, doesn't show the typically 9.30 or 10.30 program that normally showed on HD, this impacted "Supernatural" (which looks *great* in HD, thanx Ten for not showing an encore grrr), and now "Dexter" which I haven't seen but have it on good authority that this is another excellent HD show (pilot starting this Sunday 6 July 2008).
*iron out a few other quirks.    I turned on perl warnings and strict, and found a *heap* of issues with essentially PerlTGD which I repaired along the way, and will eventually merge these fixes back into the PerlTGD Topfield code.    You will find that if you, say, have an extra TAB in your faves file where it doesn't belong, then you may get errors reported now by the perl interpreter.    I think this is better than no errors and perl "guessing" about what to do (which I figure it must do for the Toppy PerlTGD given the various bits that are directly copied out of it).
*a few other odds & sodds :-)
*creating a new version of Wizremote that supports LCNs rather than the variable channel names (which can now be edited on the Beyonwiz and thus requires you to rerun the update_channelinfo.pl script if you rename any channels, and then also updating both your favourites file and the settings channel rename file.   I have already analysed the mods require to wizremote to achieve this, and believe it is not a huge change, the biggest issue is trying to keep everything backwards compatible.
Cheers,
Tony 3/7/2008

* wizTimerd-0.2.zip (193.01 KB - downloaded 49 times.)
« Last Edit: 2008-07-03 08:23:50 by tonymy01 » Logged
Pages: [1] Print 
Beyonwiz Software  |  Forum  |  Forum content  |  Software (Moderator: DaveŽ)  |  Topic: wiztimerd-0.2. To set timers on the Beyonwiz based on keywords « previous next »
Jump to:  

 
Links
  Beyonwiz Software
   All areas
  
   Software list
   International discussion
   Guides and Help
   General discussion
  
  For Developers
   OpenWiz.org
  
  Other
   www.beyonwiz.com
   Australian forum
   Finnish forum
Bookmark this
Powered by SMF 1.1.7 | SMF © 2006-2008, Simple Machines LLC
TinyPortal v0.9.8 © Bloc

Contact information