Topic: How to publish a widget that needs extra setup on the Chumby?

Hi there.
I wrote my first widget, and now I am not sure how to go about publishing it. It's called "NowOnTivo" and it lists the programs currently available on my Tivo. In order to do that I had to write a small script running curl to get the info, and had to install lighthttp so I could bypass the crossdomain.xml problem (still not sure if this would work if the widget came from *.chumby.com, any help appreciated).

What would be the proper procedure to have this added to a channel so it can mix with the other widgets? Right now I can only run it from the command line.

cheers,

--izar

Re: How to publish a widget that needs extra setup on the Chumby?

Any chance you could send out detailed instructions on how you got this working?

Thanks
Damien

Re: How to publish a widget that needs extra setup on the Chumby?

Here's the README that I am putting together with the widget, and the script I got to download the Tivo information. Let me know if you'd like me to email you the whole thing, as it seems this forum doesn't let you attach files.

This is a work in progress. Izar Tarandach - November, 2007.
<izar.tarandach at gmail.com>

All Tivo symbols and names that are trademarks of Tivo are subjected to their
rules of use as listed in their website, http://www.tivo.com


1. install lighthttp on chumby as per http://wiki.chumby.com/mediawiki/index. … ourself.3F

2. create a crossdomain.xml file on the html root of your installed server containing:

<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "http://www.macromedia.com/xml/dtds/cros … policy.dtd">
<cross-domain-policy>
   <allow-access-from domain="*" />
</cross-domain-policy>

3. drop the NowOnTivo.swf file there too.

4. edit the beginning of get_now_playing.sh - MAK is your Tivo Media Access Code, TIVOIP is obvious, and INTERVAL is how long between accesses to the Tivo, in seconds.

5. if you don't have one, create a file called "debugchumby" on your usb root, and add "/mnt/usb/DIR/get_now_playing.sh &" - where DIR is the directory where you opened the NowOnTivo files. Don't forget that debugchumby has to be executable.

6. Right now you can only run from the command line: chumbyflashplayer.x -z -W 2  -i http://localhost/NowOnTivo.swf

TODO:
1. add scrolling buttons
2. add multiple Tivos
3. add a clock widget
4. add red status for "recording" and blue for "transferring"


-------------------------------------------

get_now_playing.sh:

TIVOIP=your_tivo_ip
MAK=your_mak
HTTP=../lighty
INTERVAL=900

while true; do
        curl -s --digest -o $HTTP/html/nowplaying.xml -k "https://tivo:$MAK@$TIVOIP/TiVoConnect?Command=QueryContainer&Container=%2FNowPlaying&Recurse=Yes"
        sleep $INTERVAL
done