PDA

View Full Version : Tivo Now Playing RSS Feed


BOfH
11-16-2005, 08:10 PM
I wanted an RSS feed for my Now Playing list that would load correctly inside the Safari RSS reader (and other aggregators). I couldn't find anything that did exactly what I wanted in this space, so I rolled my own...

http://static.flickr.com/25/64011752_d77a2ab1b2.jpg

It's a TivoWeb module that produces a valid XML/RSS feed for your Now Playing list. It includes the title, episode title, summary and correctly formats the date so your aggregator can sort by recording time.

More info and download here: Now Playing RSS (http://blog.durdle.com/nowplayingrss)

My TivoStatus Wordpress pluging here: TivoStatus (http://blog.durdle.com/tivostatus)

Gunnyman
11-16-2005, 09:24 PM
VERY Cool
downloading now.
I wonder if there's a way to turn them into links that VLC will play.

Gunnyman
11-16-2005, 09:45 PM
Oooh.
I get to ASK a tech support question for a change.
When clicking on either a show title or more info I get the following:

INTERNAL SERVER ERROR
--cut here--
action_showing '/805894/11' ''
invalid attribute: Date
while executing
"dbobj $showing get Date"
("uplevel" body line 8)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 5)
invoked from within
"RetryTransaction {
if { [regexp {([0-9]*)/(.*)} $objectid junk fsid subobjid] } {
set showing [db $db openidconstruction $fsid $subobjid]
..."
(procedure "::action_showing" line 24)
invoked from within
"::action_$action $chan $part $env"
("eval" body line 1)
invoked from within
"eval {::action_$action $chan $part $env}"
--cut here--
I'm running the latest TWP and have done a FULL restart.

BOfH
11-17-2005, 04:52 AM
Two things...

First: links to start VLC - good idea; I'll add a config option to allow it to do that.

Second: I don't use TivoWebPlus, just the stock 1.9.4 TivoWeb. When I click on an episode title from my nowshowing list (http://my.tivo/nowshowing/) I am taken to a URL of the form:

http://my.tivo/showing/$fsid/11

Where $fsid is, obviously, the ID of the show in question.

If someone can tell me the right URL for TivoWebPlus, I'll code it so it works for TWP too.

Is it possible to run TivoWeb and TivoWebPlus on the same box (on different ports)? It'd make debugging stuff like this easier.

Update: New Version (0.2) (http://blog.durdle.com/nowplayingrss) with tivo:// video streaming links. No fix for the other issue yet though.

Cheers,
Howard

Gunnyman
11-17-2005, 07:15 AM
BofH,
you sure can run both tw and twp on a S1. Series 2 Dtivos are better running tivowebplus because it handles 2 tuners.
twp can be found at http://tivowebplus.sourceforge.net/
This project is awesome by the way.

BOfH
11-17-2005, 08:20 AM
This project is awesome by the way.

Thanks! I wasn't sure if anyone else would even want such a thing, but as I'd written it I thought I may as well share!

I've checked the TivoWebPlus code, and it points to the same URL for show info (tivo/showing/fsid/11) so you shouldn't see any errors. Do you get that message for every show in the RSS feed?

Howard
(BOfH)

Gunnyman
11-17-2005, 08:25 AM
yes I picked 10-15 links randomly they all did it.
is the format of the url correct? http://192.168.1.106/showing/801235/11
just noticed if I use the ui section in twp I get a url with a /12
edited the script replacing the /11 with /12 and all is well :D

Gunnyman
11-17-2005, 09:11 AM
ok got new version
added my /12
turned on vserver links.
what am I missing for those to work? I click on show title and get the infopage (aren't I a PAIN) :D
oops spoke too soon
clicking on a show generates this error:
Safari can’t open “tivo://192.168.1.106/801232” because Mac OS X doesn’t recognize Internet addresses starting with “tivo:”.

BOfH
11-17-2005, 12:18 PM
Safari can’t open “tivo://192.168.1.106/801232” because Mac OS X doesn’t recognize Internet addresses starting with “tivo:”.

Yup, OS X will do that. I have exactly the same issue on OS X. On Windows however I know how to configure IE/Firefox to launch VLC when you click a tivo:// link. Take a look at this guide here (http://blog.durdle.com/archives/2005/09/20/streaming-tivo-to-the-videolan-client/).

I've been unable to find a way to configure Safari (or Firefox on OS X for that matter) to behave the same way. If you work it out please let me know!

Those links will work on a Windows aggregator to launch VLC with the correct stream, it's just OS X that it breaks in for now. :(

I'll update the code to use the /12 for TivoWebPlus - thanks for that pointer.

Howard

Gunnyman
11-17-2005, 12:35 PM
Now that you've opened this can of worms :D
there's a video enabled aggregator called DTV that is very very new. I've been unable to get my now playing list to show up there though.
check out http://dtvmac.com

Gunnyman
11-17-2005, 01:03 PM
yet another post from me
I can only get this to work in safari for some reason.
Other aggregators I've tried have said not a valid feed

Gunnyman
11-17-2005, 08:07 PM
thanks to drewster and more internet http://www.versiontracker.com/dyn/moreinfo/macosx/16066
I got vserver links working in safari!
Very very nice

bengalfreak
11-18-2005, 05:47 AM
Safari is Mac only right?

BOfH
11-18-2005, 05:53 AM
Safari is Mac only right?

Yep. But if you want vserver links working in Internet Explorer or Firefox on Windows, use the registry hack at the bottom of this guide (http://blog.durdle.com/archives/2005/09/20/streaming-tivo-to-the-videolan-client/).

I'm going to have to take a look at the feed my RSS module generates, as while it is valid for Safari, it does break other readers. :( Time to dig out the official RSS 2.0 spec!

H

BOfH
11-18-2005, 06:02 AM
thanks to drewster and more internet http://www.versiontracker.com/dyn/moreinfo/macosx/16066
I got vserver links working in safari!
Very very nice

Brilliant! Great find - thanks Gunnyman!

Gunnyman
11-18-2005, 08:31 AM
Any thing for the ba$tard operator from Hell :D

Fofer
11-28-2005, 07:21 PM
I installed this last night and it works like a charm. (Thanks for the inspiration, Gunny. And thanks for creating and sharing a wonderful module, BOfH!) I can view the RSS just wonderfully in Safari. And I was happily surprised to see that it even works when I connect from outside my home network, through a Orenosp Proxy I'd set up for security. :up:


I do notice however that the Series Name as well as the episode description shows... but not the episode title.

For example, last night's Family Guy says:

"Family Guy
Fofer's Tivo
Yesterday, 09:00 PM
Lois learns she has a brother she has never met (Robert Downey Jr.), so she brings him home from a mental institution to live with her family. Read more…"

...but nowhere does it say "Fat Guy Strangler."


And when I click "Read more" it actually starts playing the video via VLC. Which is nice, of course. (Any way to get that link to read "Stream Video" instead? Or is that built in to Safari's RSS rendering engine?)

BOfH
11-29-2005, 07:50 AM
I do notice however that the Series Name as well as the episode description shows... but not the episode title.

...

(Any way to get that link to read "Stream Video" instead? Or is that built in to Safari's RSS rendering engine?)

Hi Fofer - glad you like the module!

I'll take the last question first - the "Read More" is part of the Safari RSS renderer, so we can't change it unfortunately. I could alter the RSS to output a "view video" link at the end of the description, and leave the "read more" to be the link to the info page. What do you think?

As to missing episode titles... when you look at the info page for that Family Guy episode, does it show "Fat Guy Strangler" in the Episode Title row? If my code can't see a valid episode title it doesn't display anything - if it can, it places it in quotes at the front of the description. So you'd have seen:

Family Guy
"Fat Guy Strangler" blah blah description here blah blah _Read More_

If it finds nothing, or "No Episode Title" or "Not an Episode" it doesn't include the quotes.

If your Tivo *does* have an episode title for the show, then we have a problem, which I'm sure we can work out. Which Tivoweb are you using?

Cheers,
Howard
(BOfH)

Gunnyman
11-29-2005, 07:58 AM
I would love an added video link myself. It would be nice to be able to "see more info" OR "play now"
Great project. I use it daily.

Fofer
11-29-2005, 12:18 PM
I'll take the last question first - the "Read More" is part of the Safari RSS renderer, so we can't change it unfortunately. I could alter the RSS to output a "view video" link at the end of the description, and leave the "read more" to be the link to the info page. What do you think?

That would be great. Right now, clicking the Series name, "Fofer's TiVo," the date of the recording, or "Read More" on any of the entries all do the same thing - they open VLC and allow me to stream the video by clicking the play button. Which works great, BTW.

Not one of the links goes to an "info" page. It would probably make more sense if those thinks all went to an "Info" page... with a new link specifically titled "View Video" taking me to VLC.


If your Tivo *does* have an episode title for the show, then we have a problem, which I'm sure we can work out. Which Tivoweb are you using?


Yes, my TiVo does have episode titles for many (if not most) of my shows... but none appear in this RSS page. I am running TivoWebPlus Project - v1.2.1.

Gunny, do you get individual episode titles on your RSS feed?

Gunnyman
11-29-2005, 12:34 PM
nope
Law & Order
Living Room Tivo
Wednesday, 10:00 PM
Detectives investigate a series of seemingly random murders. Read more…

is what mine says

bushman4
12-06-2005, 09:02 AM
I'm getting episode titles on my S1 SA...

On another note, I ran my RSS feed through www.feedvalidator.org, and came up with a few problems:

Feeds should not be served with the "text/html; charset=utf-8" media type
I'm not sure if it's possible to change the media type of a returned page in TWP

line 2, column 0: This feed is an obsolete version
<feed version="0.3"

modified must be an W3CDTF date

<modified>2005-12-06 12:57:59</modified>
That should be trivial

link must be a valid URI (187 occurrences)
<link rel="alternate" type="text/html" href="tivo://tivo/919360" />
I'm betting that FeedValidator doesn't recognize tivo:// as anything...

issued must be an ISO8601 date (187 occurrences)
<issued>2005-12-06 06:00:00</issued>
Trivial as well.

I'm no TCL wiz, but I can take a look and see if I can get it to work right... I'm struggling to get the feed to work as a news feed in xAP News (www.mi4.biz)... it works fine in FeedDemon 1.5...

Bushman

Arcady
12-06-2005, 04:04 PM
I have this working on my DirecTivo and Mac. It's really cool. However, I am also not seeing episode titles.

Gunnyman
12-07-2005, 08:36 AM
I think we're seeing some differences between S2 Tivos and/or TWP and older tivoweb.

bushman4
12-07-2005, 10:05 AM
Do either of you happen to run DailyMail? Do episode Names show up there?

Looking at the module, there is only one difference between how the two pieces of code get the title... DailyMail assumes that all programs are episodic (and hence have episode titles) unless explictly defined as non-episodic.

NowPlayingRSS assumes the oposite...

Try this:
Change this code:
set episodic [dbobj $series get Episodic]

to This code:
if {$series != ""} {
set episodic [defaultval 1 [dbobj $series get Episodic]]
} else {
set episodic 1
}

Maybe some of these items are not "episodic" or maybe the "episodic" value is bogus, or named something different.

HTH,

Bushman

bushman4
12-07-2005, 10:08 AM
BTW, I am using a Series 1 Stand Alone, with the latest and greatest TiVoWebPlus.

And I get episode titles...

(It looks like the comonality has more to do with either Series 1 vs. Series 2, or DTV vs. SA, since Gunny and I are both on the same TWP)

Bushman

Gunnyman
12-07-2005, 10:18 AM
Do either of you happen to run DailyMail? Do episode Names show up there?

Looking at the module, there is only one difference between how the two pieces of code get the title... DailyMail assumes that all programs are episodic (and hence have episode titles) unless explictly defined as non-episodic.

NowPlayingRSS assumes the oposite...

Try this:
Change this code:
set episodic [dbobj $series get Episodic]

to This code:
if {$series != ""} {
set episodic [defaultval 1 [dbobj $series get Episodic]]
} else {
set episodic 1
}

Maybe some of these items are not "episodic" or maybe the "episodic" value is bogus, or named something different.

HTH,

Bushman
That fixed it for me.
Nice work!

Fofer
12-07-2005, 11:20 AM
That fixed it for me.
Nice work!

Me too! Thanks!

I think we're seeing some differences between S2 Tivos and/or TWP and older tivoweb.

I was thinking Standalone vs. DirecTiVo. I recall reading some similar notes with other modules and how these units handled episode listings differently.

But here's another wrinkle. This change initially worked for me on one HDVR2 DirecTiVo, but not the other. I could see ep. titles on one, but not the other. :confused: These machines are otherwise identical, modded the same. So I restarted TWP, I cleared my browser cache, etc. Still no episode titles in the RSS feed for unit #2.

Then I realized DTiVo #2 has mostly older recordings (lots of movies, some seasons of shows I am keeping around.) They were all recorded back when I was on 4.0.1b on that unit. (I am now on 6.2.) So I set up a quickie recording of something airing right now, that had an episode title.

Sure enough, the episode title now shows up in the RSS module!


So it's got something to do with SA/Combo, older OS vs. 6.2.

Glad to see it working now for me though. :)

Fofer
12-07-2005, 11:28 AM
Just curious, how long after I delete a show from Now Showing should it disappear from the RSS feed?

bushman4
12-07-2005, 11:47 AM
It will dissappear from the "feed" immediately...

How long it will kick around as a "news item" in your RSS aggregator application is a different story.

Does anyone know if there is a way to expire a news item in a feed? If so, I could add a piece of code to the module to send out expiration messages for each item in the deleted list...

I'm not an RSS whiz... maybe I'll dig out the spec and look into it.

Bushman

Fofer
12-07-2005, 12:14 PM
It will dissappear from the "feed" immediately...

How long it will kick around as a "news item" in your RSS aggregator application is a different story.


Ahh... gotcha.

bushman4
12-07-2005, 03:26 PM
OK, I'm looking into the Spec, and answering a few more questions...

First off, to fix the Feed Modified date replace this line:
puts $chan "<modified>[clock format [clock seconds] -format "%Y-%m-%d %H:%M:%S"]</modified>"

with:
puts $chan "<modified>[clock format [clock seconds] -format "%Y-%m-%dT%H:%M:%S"]Z</modified>"

To fix the entry modified date, replace this line (in print_nsrow):
set timestr [clock format $seconds -format "%Y-%m-%d %H:%M:%S"]
with:
set timestr [clock format [clock seconds] -format "%Y-%m-%dT%H:%M:%S"]Z

And to deal with empty descriptions (since the summary section of each item should not be blank) replace this line:
puts $chan "\x5b$eptitle[strim [dbobj $program get Description]]\x5d\x5d>"

with this:
set descrip [dbobj $program get Description]
set trimdescrip [strim $descrip]
if {$trimdescrip == "" } {
puts $chan "\x5b$eptitle No Description\x5d\x5d>"
} else {
puts $chan "\x5b$eptitle[strim [dbobj $program get Description]]\x5d\x5d>"
}

FeddValidator.org now only complains about feed version and bad links... bad links are going to stay, since it doesn't recognize "tivo://" as a URI, but the version is a different story.

Speaking of that... is this supposed to be in RSS format, or in Atom format? It appears as though RSS feeds should all start with a "<RSS" tag, but this feed starts with "<feed"... I haven't looked into atom format yet, so maybe that's the answer.

More later...

Bushman

bushman4
12-07-2005, 03:28 PM
BTW, do these changes make it readable in any of the readers that failed before? I'm trying to bring this feed into "spec" and maybe it will be more universally used...

Bushman

Fofer
12-07-2005, 03:33 PM
Does anyone know if there is a way to expire a news item in a feed? If so, I could add a piece of code to the module to send out expiration messages for each item in the deleted list...

That would be great. :)

Because now that I've tested the "episode name" by recording 5 minutes of "Dragon Tales"... and them promptly deleted it... I'm stuck looking at "Dragon Tales" in my RSS feed. http://homepage.mac.com/joshr/tc/meh.gif

:D

Gunnyman
12-07-2005, 03:51 PM
wow this has truely become a 'Community" Project!
Awesome.

Tenacious Lee
12-07-2005, 04:27 PM
I'm not sure if it's because I haven't edited the tcl at all, aside from the variables I'm supposed to- but when I open the feed in Safari, it's just blank.

Any clue as to why?

ruexp67
12-07-2005, 11:59 PM
I am getting a blank listing when I view it with WIZZ RSS in Firefox on my PC as well. HDVR2 TWP 1.2.1

Even at that, I cannot get this to stream at ALL. I can click on any link and get the TIVO:// link, but it simply will NOT play in VLC at all. :confused: I cut and pasted the link into VLC as described in the blog link, but no joy. I tried disabling my personal firewall and no change.

FWIW I have not been able to get the .asx file to stream to WMP either.

I used the Zipper to hack the tivo. Is there a component I may be missing?

Gunnyman
12-08-2005, 02:11 AM
vserver

bushman4
12-08-2005, 07:44 AM
I just realized that the date format that I used in the Modified tags is wrong.

W3C format says (http://www.w3.org/TR/NOTE-datetime) that a date should be in the format:
YYYY-MM-DDThh:mm:ssTZD (eg 1997-07-16T19:20:30+01:00)

and then give the examples:
1994-11-05T08:15:30-05:00 corresponds to November 5, 1994, 8:15:30 am, US Eastern Standard Time.

1994-11-05T13:15:30Z corresponds to the same instant.

Since the TiVo's time is in GMT, there is no Time Zone offset... the RSS reader application should do the offset automatically, depending on where it is running (what time zone).

I will edit my other post to reflect the correct format, but essentially, the Global definition I mentioned can be removed again, and replace "[format "%+03d" [expr $tzoffset / 3600]]:00" with "Z"

Bushman

ruexp67
12-08-2005, 08:47 AM
vserver

Both HackMan and ps both list vserver as running.

I'll keep digging, thanks for the suggestion though.

Tenacious Lee
12-08-2005, 02:31 PM
Ditto. Just started up TiVoTool and was able to pull a listing of shows. vserver is running fine.

Hmm.

bushman4
12-08-2005, 03:26 PM
Are you using TiVoWeb or TiVoWebPlus?

Do you have the TiVoWebPlus variable set correctly?

Bushman

Tenacious Lee
12-08-2005, 04:34 PM
Are you using TiVoWeb or TiVoWebPlus?

Do you have the TiVoWebPlus variable set correctly?

Bushman

Yep and yep.

Tenacious Lee
12-08-2005, 05:29 PM
Here's a sample of the rss feed generated, which I can view in Firefox/MSIE from work. It looks like a great deal of the variables are somehow getting skipped over, although I can't find where in the code the problem is.

<?xml version="1.0" encoding="utf-8"?>
<feed version="0.3"
xmlns="http://purl.org/atom/ns#"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xml:lang="en">
<title>Tivo Now Playing</title>
<link rel="alternate" type="text/html" href="http://zaphod.homedns.org/tivo/nowshowing" />
<tagline>What's on Jae's Tivo?</tagline>
<modified>2005-12-08 22:21:09</modified>
<copyright>Copyright 2005</copyright>
<generator url="http://blog.durdle.com/nowplayingrss/" version="0.3">NowPlayingRSS</generator>
The Tyra Banks Show^12/8^Salvaging quick marriages.^A couple who wed just weeks into their relationship and a couple whose shotgun wedding was a disaster try to salvage their marriages.
King of the Hill^12/8^Be True to Your Fool^After Bill gives lice to the other guys, they refuse to drink beer with him.
Yoga Zone^12/8^No Episode Title^
Late Night With Conan O'Brien^12/8^Lindsay Lohan; Colin Hanks; Coldplay.^Actress Lindsay Lohan; actor Colin Hanks; Coldplay performs.
The Simpsons^12/7^The Strong Arms of the Ma^Marge retreats to the basement to lift weights after she is mugged.
</feed>

bushman4
12-09-2005, 02:09 PM
OK, I did a fair bit of research about Feed Formats.

Turns out, the original BoFH version is really an ATOM 0.3 format, not a RSS 2.0 format...

I did a re-write to convert it from ATOM format to RSS 2.0... now the only issue that FeedValidator.org has with it is the MIME type of the returned feed, which I'm not sure if it's possible to change in TWP.

Major Changes:
1. the Publish Date of each "news item" is the record date of the show, rather than "now"
2. The "more info" link is set to take you to the TWP info page for the show.
3. The bottom of the description has a "-View-" link that should launch VLC or whatever your tivo:// URI handler prefers.
4. All times are in GMT, since that is the native time of the TiVo... your RSS client should then convert it to local time for you...

If you want to run both modules in parallel, you will need to modify the existing module to have a different name. I did this:

* rename nowplayingrss.itcl to nowplayingatom.itcl
* change the last line from:
register_module "nowplayingrss" "Now Playing RSS" "Now Playing List as RSS"

to:
register_module "nowplayingatom" "Now Playing ATOM" "Now Playing List as ATOM"

Then upload this new module (after saving it and removing the .txt extension) to your TivoWeb Modules directory, and do a quick restart.

If someone could check this out with other readers, I'd appreciate it.

Thanks,

Bushman

PS, all props to BoFH for his intial work on this module... without him, I never would have thought to modify it...

EDIT: New version posted on Feb 8, 2006. See post #72 in this thread for more info. The version attached to this message is the updated version

Tenacious Lee
12-09-2005, 06:17 PM
Hmm. Just tried your version, bushman and I'm still getting no articles. Very strange.

Gunnyman
12-09-2005, 06:56 PM
go into teh script and make sure the variable for tivourl is changed to match your tivo's IP.

Fofer
12-09-2005, 07:03 PM
New one workin' for ya, Gunny? I'll try it out when I get home.

Tenacious Lee
12-09-2005, 07:08 PM
My tivo's address is 192.168.1.222. I have this mapped in NetInfo Manager to 'tivo'.
I've tried setting the variable in nowplayingrss.itcl to 'tivo' ,'192.168.1.222', and 'mydomain.com/tivo'

Apache has a VirtualHost/proxy set up to send connections at mydomain.com/tivo to the TiVo.

TiVoWeb+ has a prefix set to tivo in tivoweb.cfg, because otherwise the css didn't take (not sure why)

When I connect to http://tivo and then click on nowplayingrss from the menu, it actually takes me to http://tivo/tivo/nowplayingrss, which gives safari a problem (it thinks for a second, then goes to feed:http:// and gives me an error that it could not be located)

If I go to feed://192.168.1.222/nowplayingrss directly, it pulls up the rss page- only it says there are no articles.

Looking at the code I pasted from yesterday, I'm very confused why none of the channel or item information for each show is included when outputting the data (which only shows up in not safari)

Gunnyman
12-09-2005, 07:13 PM
New one workin' for ya, Gunny? I'll try it out when I get home.
yep and it works in my RSS widget too :D

bushman4
12-09-2005, 10:24 PM
People who have tried the RSS version, do the item titles show up correctly in your RSS Reader? Not the episode names (ie, the problem that was happening before... Dragon Tales anyone? ;) ) but the title portion of the RSS items.

In FeedDemon, the encoded titles show up fine, but in the homebrew xAP News application, the titles are blank because of the encoding...

Just curious if your readers are OK with the encoded title. It's in the spec that they should handle encoded titles...

Thanks,

Bushman

TubaMan-Z
12-22-2005, 04:51 PM
bushman4,

I've installed your RSS-corrected nowplayingrss.itcl module and am trying it out as a Firefox Live Bookmark. In general things work well. However, for those shows that I have marked SUID, I get the info screen that Gunnyman reported back on 11-16-05 (post #3 in this thread). All of my SUID shows are older than the oldest non-SUID show with my newest SUID show being recorded on 12/5 and the oldest non-SUID show recorded on 12/10.

FYI - Using Live Bookmarks for this is not the best. All I get is a list of the same icons - no text at all.

km
12-24-2005, 06:58 PM
Is there a way to actually use this with Firefox Live Bookmarks? Firefox doesn't seem to like the utf-8/CDATA encoding of the Titles.

bushman4
12-26-2005, 09:34 PM
Sure...

Change:
puts -nonewline $chan "<!"
puts -nonewline $chan "\x5b"
puts -nonewline $chan "CDATA"
puts -nonewline $chan "\x5b"
puts -nonewline $chan "$title"
puts -nonewline $chan "\x5d\x5d"
puts $chan ">"

to:
puts -nonewline $chan "$title"

and then do a quick restart...

Bushman

km
01-18-2006, 11:53 AM
Sure...

Change:
puts -nonewline $chan "<!"
puts -nonewline $chan "\x5b"
puts -nonewline $chan "CDATA"
puts -nonewline $chan "\x5b"
puts -nonewline $chan "$title"
puts -nonewline $chan "\x5d\x5d"
puts $chan ">"

to:
puts -nonewline $chan "$title"

and then do a quick restart...

Bushman

Thanks for the tip! However, it turns out that the CDATA is really needed because of the "&" that often appear in Titles and Descriptions.

The issue is really that firefox is sensitive to any white space preceeding CDATA and the easiest fix to satisfy firefox is

116c116
< puts $chan "<title>"
---
> puts -nonewline $chan "<title>"
127c127
< puts $chan "<description>"
---
> puts -nonewline $chan "<description>"

km
01-18-2006, 12:25 PM
By the way, I think the comment

# Are you using TivoWebPlus? 1 if yes, 0 if no.
set tivowebplus 1

is not really correct. What it controls is whether fsid/11 or fsid/12 is used for the link to the showing. That's not a Tivoweb issue at all, it really speaks to the structure of the MFS on the tivo, which is dependent on the version of the tivo software not tivoweb.

For example, on my tivo series 1 with 2.0 software, the correct setting would be 0 even with TivoWebPlus.

bushman4
01-19-2006, 01:55 PM
Do you know when to use each one? I only have a S1 SA, with 3.0 software, and TWP... that setting was there from when the Bastard wrote the original script.

If someone can provide me with rules, I can program them in...

Bushman

twynne
01-19-2006, 05:06 PM
Really looking forward to getting this working, but having a couple of teething problems:

1. In my RSS reader (I'm trialing Greatnews if it matters), the date shows up correctly but the time is showing 12:00am on every recording. Any ideas what causes this and if it can be fixed??

2. Like someone else in this thread, I can't get streaming to work for anything. I've installed/run vserver, and get the message 'waiting for connections on port 8074' when run manually from a telnet prompt. Tivo:// links do launch VLC, but it just does nothing. I have downloaded and installed the latest plugins for VLC. Is there anything else I'm missing?

Many thanks,

Tom

Oh, this is a UK S1 Tivo running 2.5.

twynne
01-21-2006, 08:15 AM
Really looking forward to getting this working, but having a couple of teething problems:

1. In my RSS reader (I'm trialing Greatnews if it matters), the date shows up correctly but the time is showing 12:00am on every recording. Any ideas what causes this and if it can be fixed??

2. Like someone else in this thread, I can't get streaming to work for anything. I've installed/run vserver, and get the message 'waiting for connections on port 8074' when run manually from a telnet prompt. Tivo:// links do launch VLC, but it just does nothing. I have downloaded and installed the latest plugins for VLC. Is there anything else I'm missing?

Many thanks,

Tom

Oh, this is a UK S1 Tivo running 2.5.

Quick update - got streaming working. Turns out it was the vstream modules for VLC not being the correct version. I had VLC 0.8.4a and modules 0.8.2. Managed to find the correct version of the modules and it works fine.

Now if I could just sort out the time showing incorrectly in my RSS reader. Does anyone else have this problem with the RSS module, or do you think it's an issue with my reader?

Cheers,

Tom

twynne
01-21-2006, 04:01 PM
If you want to run both modules in parallel, you will need to modify the existing module to have a different name. I did this:

* rename nowplayingrss.itcl to nowplayingatom.itcl
* change the last line from:
register_module "nowplayingrss" "Now Playing RSS" "Now Playing List as RSS"

to:
register_module "nowplayingatom" "Now Playing ATOM" "Now Playing List as ATOM"

Then upload this new module (after saving it and removing the .txt extension) to your TivoWeb Modules directory, and do a quick restart.

If someone could check this out with other readers, I'd appreciate it.

Thanks,

Bushman

PS, all props to BoFH for his intial work on this module... without him, I never would have thought to modify it...

Bushman - I thought I'd try your updated version to see if it resolved my 'time' issues (see above) but I can't even get it to work in Tivoweb. I first tried running the two in parallel. When that failed I removed both and added the new version alone - still no joy. I then removed it and put the old version back and it works fine.

Is there any possibility that this only works with TWP?

Cheers,

Tom

twynne
01-21-2006, 04:19 PM
Doh - nevermind my last post. I had assumed because clicking the link to the new version in TW was doing nothing (where the old version would actually display within IE) that it wasn't working. Not only is it working but appears to have resolved the time issue... hurrah! :-)

bushman4
01-23-2006, 09:42 AM
Excellent.

The version I posted follows the RSS 2.0 spec religiously, except for the fact that it is sent out using the incorrect Mime Type, but I don't think TWP has the ability to send out other MIME types.

I will edit the version posted to include the "remove whitespace" changes that were suggested for the title tag. Look for a repost.

Bushman

thepicman
02-05-2006, 10:33 AM
We use this plugin (Bushman's version) to send the Now Playing list to my wife's WordPress blog. As we did not want to have dead links for the descriptions and did not want the links back to our TiVo to actually work :eek: We made two small changes. (Obviously if you have TivoWeb rather than TivoWebPlus you would need to change the top entrylink value)

if {$tivowebplus == 0} {
set entrylink "http://$tivourl/showing/$fsid/11"
} else {
set entrylink "http://search.tv.yahoo.com/tvtitlesearch?p={$title}&fsid=$fsid"

to send the link to the Yahoo tv listing and

puts $chan "<link>http://www.tivocommunity.com/tivo-vb/</link>"
puts $chan "<description>Visit the TiVo Community Forums</description>"

to send the main Now Playing link to the TiVo forums.

Now we have to wonder why anybody would care whats on our TiVo and why we would want to tell them :cool:.

We have the WordPress TiVo Status plugin working on a 2 tuner DTiVo as well

http://www.tivocommunity.com/tivo-vb/showthread.php?t=268780

TPM

bushman4
02-06-2006, 10:22 AM
Glad it works out for you...

Bushman

Markman07
02-06-2006, 08:38 PM
So what am I doing wrong here.

I see the feed (actually using IE 7 beta preview 2)... and Sage also in Firefox


I see a clickable link on the top called "Tivo Now playing list" that when clicked brings me to the TWP now playing list where I can click View and play the video using TYSHOW.

Below that link are all my shows with a brief description under it. I can click any of the shows in the list and it brings me to a screen again in TWP

(like http://192.168.1.150/showing/85395/12)

I do see a -view- right under each show's description but I can't click on it. I also never see any READ MORE links like I see in the OP.

I am using the Bushman's file found later in this thread. Any ideas?

UPDATE: Installed the VLC media player on my PC now. The View links open the player but nothing shows. ALSO using the VIEW (mplayer) in the TWP Now Playing List does work (using Vserver).

bushman4
02-07-2006, 10:00 AM
Did you install TyShow as well? That is the codec used to decode the stream...

Bushman

Markman07
02-07-2006, 11:23 AM
Yes as stated in the prior post - "I see a clickable link on the top called "Tivo Now playing list" that when clicked brings me to the TWP now playing list where I can click View and play the video using TYSHOW."

In other words I can click the VIEW link when viewing the Now Playing List in TWP (per activating this feature in tivoweb.cfg" and having Vserver running along with the Tyshow installed) This worked before I even found out about this RSS feature...

In my Firefox Sage RSS reader I can click the View button and it launches the VLC media player yet nothing ever happens after that. If I go into the TWP Now Playing List I can click the View link and it launches the TyShow enhanced Windows Media Player and plays the show fine.

bushman4
02-07-2006, 01:45 PM
Sorry... missed that.

Right click on each of the "view" links (the one in Sage and the one in TWP), copy the shortcut, and paste them into a new post... I'll debug from there.

Bushman

bushman4
02-07-2006, 01:56 PM
Another question: I guess I misunderstood before. Are you saying that the individual -view- links are not "clickable"?

Sounds like you need to enable hotlinks in messages, but I don't use either reader that you mention.

A feed can have a URL... that is what is taking you to the TWP Now Playing List when you click on the feed title. But items can also have links, which is how the "view" links work.

For debugging, would you try a reader that we know has the ability to have clickable article text, like FeedDemon or something like that?

LMK,

Bushman

Markman07
02-07-2006, 03:21 PM
Now with SAGE yes I can click the View links but the VLC application launches but nothing happens.

From SAGE - The link properties are tivo://192.168.1.150/80291 for one example.

I will install FeedDemon and try that out.

UPDATE: I got the View link to launch the VLC player now and it works. The VLC was version 8.4 and the Binaries plugins from http://www.XXA@#OD@KIDK@.com now match.

Leddy
02-08-2006, 09:27 AM
Great script. Here's a few things that I would like to suggest:

1.) Strip out windows EOL (^M)
2.) Take a look at zNowShowing.itcl on how they decode episode links.
i.e. you use /12 for everything on the "View Article" and most of the time it is wrong. Mine bounce back and forth between 12/13 and on occasion some weird random number. This makes it very difficult to always get information on an episode.

FYI Wizz rss doesn't show any information on feed, but you can click on it and get (in my case) a broken /showing page. However it works beautifully in Outlook 12

bushman4
02-08-2006, 11:49 AM
Here is a new version with some fixes.

Changes:

Trim whitespace on the Title and Description tags - as requested by KM, these will all be on one line, with no line feeds between the <title> and </title> tags (and the description tags too)
UNIX format - Don't know how that happened before, but it's fixed now.
More Info links - I took Leddy's advice and looked at the ui.itcl (where I get MY Now Playing list from...) for how they constructed their episode links. Because of this, it eliminated the need for the TiVoWebPlus variable to be set, since that was only changing the More Info URLs from /11 to /12.


I'd be interested to see if it works in RSS Agravators that it didn't work in before...

TIA,

Bushman

Leddy
02-08-2006, 02:05 PM
Well it looks like it is doing something different at least. I am seeing 12's and 13's :)

However it gives this error before finishing the page load in FF

INTERNAL SERVER ERROR
--cut here--
action_nowplayingrss '/' ''
can't open object (0x30007)

while executing
"db $db openid $fsid"
("uplevel" body line 2)
invoked from within
"uplevel $body"
invoked from within
"ForeachMfsFileTrans fsid name type $nowshowingdir "" 15 {
set rec [db $db openid $fsid]
print_nsrow $chan $rec
}"
(procedure "::action_nowplayingrss" line 43)
invoked from within
"::action_$action $chan $part $env"
("eval" body line 1)
invoked from within
"eval {::action_$action $chan $part $env}"
--cut here--

I think FF may be re-writing the text and adding ^M. The new version still had them. However I just downloaded through lynx and ftp'd it over to the tivo.

Luv2DrvFst
02-08-2006, 02:16 PM
Like someone else in this thread, I can't get streaming to work for anything. I've installed/run vserver, and get the message 'waiting for connections on port 8074' when run manually from a telnet prompt. Tivo:// links do launch VLC, but it just does nothing. I have downloaded and installed the latest plugins for VLC. Is there anything else I'm missing?

Quick update - got streaming working. Turns out it was the vstream modules for VLC not being the correct version. I had VLC 0.8.4a and modules 0.8.2. Managed to find the correct version of the modules and it works fine.

I know I'm missing something obvious but I just can't figure this out. I've reached this same point and can't seem to get VLC to play. The RSS feed works just fine, and when I click on 'View' VLC opens but does nothing. If I click 'play' then I get this error in VLC:

main: no suitable access module for `tivo://192.168.1.201/2734868'

And the debug log has this:

main debug: adding playlist item `2769369' ( tivo://192.168.1.201/2769369 )
main debug: creating new input thread
main debug: waiting for thread completion
main debug: thread 43228160 (input) created at priority 37 (src/input/input.c:230)
main debug: `tivo://192.168.1.201/2769369' gives access `tivo' demux `' path `192.168.1.201/2769369'
main debug: creating demux: access='tivo' demux='' path='192.168.1.201/2769369'
main debug: looking for access_demux module: 0 candidates
main warning: no access_demux module matched "tivo"
main debug: creating access 'tivo' path='192.168.1.201/2769369'
main debug: looking for access2 module: 4 candidates
access_file warning: 192.168.1.201/2769369: No such file or directory
macosx debug: input has changed, refreshing interface
cdda warning: could not open 192.168.1.201/2769369
main warning: no access2 module matching "tivo" could be loaded
main error: no suitable access module for `tivo://192.168.1.201/2769369'
main debug: thread 43228160 joined (src/input/input.c:386)
main: nothing to play

This is the same thing that happens if I try to click 'View' in the ui screen in TWP. So there must be something wrong with my VLC setup. I am running VLC 0.8.4a but I can't find any other plug-in modules than 0.8.2 (from vlc-082-ty-mac-r45.tar.bz2). My vserver has a date of 8-4-05 (can't find a version number anywhere). Help!

Jim

bushman4
02-08-2006, 02:32 PM
Leddy,

What version of TW (or TWP) are you running?

I only have TWP to test on... I should install the old TW to see how it reacts as well.

Bushman

bushman4
02-08-2006, 02:33 PM
Mr. Speeding Ticket,

Do you have tyshow installed? I assume so, since VLC actually opens, so the tivo:// URI is obviously working...

I can't check my settings until I get home...

Bushman

Markman07
02-08-2006, 02:39 PM
"This is the same thing that happens if I try to click 'View' in the ui screen in TWP. So there must be something wrong with my VLC setup. I am running VLC 0.8.4a but I can't find any other plug-in modules than 0.8.2 (from vlc-082-ty-mac-r45.tar.bz2). My vserver has a date of 8-4-05 (can't find a version number anywhere). Help!"

Yes I had the same problem until I found the two DLL (version .84) on the site we can't talk about. If you can find the .84 files then copy them over the two on your computer (located in the c:\program files\VideoLAN\VLC\plugins"

HINT - Post 15 when you find the thread

Leddy
02-08-2006, 02:53 PM
Leddy,

What version of TW (or TWP) are you running?

I only have TWP to test on... I should install the old TW to see how it reacts as well.

Bushman


TW+ 1.2.1 on an HDVR2 DTivo

bushman4
02-08-2006, 03:12 PM
And that message is consistant? Or was it a case of the TiVo having that particular program locked for mainenance of something?

Slightly stumped...

Bushman

Leddy
02-08-2006, 03:22 PM
And that message is consistant? Or was it a case of the TiVo having that particular program locked for mainenance of something?

Slightly stumped...

Bushman


Well it was consistent. Now it's working. Musta been a locked program.

On the plus side. Wizz reader for Firefox now displays the show titles and descriptions. I also get no broken links when clicking on show titles.

GOOD WORK!

Now if I can figure out how to get outlook to open my password protected feed :(

Rock on I tried the old http://user:password@host/nowplayingrss

Luv2DrvFst
02-08-2006, 03:27 PM
Thanks, Markman! Everything is all fixed with 'view' and the RSS feed is great! Thanks to bushman and BOfH for the script.

For the record... running Tiger 10.4.4 on a Mac with Safari using More Internet to define tivo://

Jim

Gunnyman
02-08-2006, 04:29 PM
more internet ROCKS!
For some reason the feed is broken in my safari. Works fine in newsfire, and shiira which is odd since shiira uses webkit too.

here's the error:
Safari can’t open the page “feed:http://”. The error was: “unknown error” (NSURLErrorDomain:-1)
Please choose Report Bug to Apple from the Safari menu, note the error number, and describe what you did before you saw this message.

bushman4
02-13-2006, 08:24 AM
Gunny,

Did that message resolve itself, or are you still having problems?

Bushman

Gunnyman
02-13-2006, 08:53 AM
still having problems.
What's odd is, it used to work just fine
I think Apple did something to safari.

Gunnyman
02-13-2006, 09:06 AM
and I THINK I just figured it out.
The rss feed doesn't seem to like using my hostname (livingroom) to get to the tivo
it works just fine if I browse tivoweb using the actual IP.
newsfire works fine using the hostname though.

pdawg17
03-01-2006, 05:19 PM
Is there a way to use WMP when clicking on a show in the RSS feed?

Leddy
06-27-2006, 02:11 PM
Hopefully this project is still alive. Have an issue with PPC rss reader. Was hoping you could take a look at it.

bushman4
06-27-2006, 03:01 PM
Sure...

What is the problem? Is it the lack of Episode Title in the list? Or is it the squares at the end of each line?

Thanks for the (inadvertent) pointer on an RSS reader for pocket PC... it even supports authenticated feeds, which is a requirement if you have your TiVo behind a reverse proxy...

Bushman

Leddy
06-28-2006, 08:19 PM
I don't mind the title thing. Once you click on it you see all.

I just don't like seeing the square ;)

You're welcome.They have a number of good RSS readers, but this one is great, especially for free :)

bushman4
06-30-2006, 09:38 AM
To get rid of the square, either download and install this new version (attached) or just change one line.

Find this block of code:
puts -nonewline $chan "<title>"
puts -nonewline $chan "<!"
puts -nonewline $chan "\x5b"
puts -nonewline $chan "CDATA"
puts -nonewline $chan "\x5b"
puts -nonewline $chan "$title"
puts -nonewline $chan "\x5d\x5d"
puts $chan ">"
puts $chan "</title>"

and modify the second to last line:
puts -nonewline $chan "<title>"
puts -nonewline $chan "<!"
puts -nonewline $chan "\x5b"
puts -nonewline $chan "CDATA"
puts -nonewline $chan "\x5b"
puts -nonewline $chan "$title"
puts -nonewline $chan "\x5d\x5d"
puts -nonewline $chan ">"
puts $chan "</title>"

You just need to modify the second to last line, and add a "-nonewline" to it, to remove the carriage return/line feed between the actual title and the "Close Title (</title>)" tag.

HTH,

Bushman

Leddy
07-02-2006, 04:38 PM
Editing the file worked awesome!!

Thanks

lloyd
11-03-2006, 02:51 PM
Has anyone got nowplayingrss working with google reader? I can't seem to make it recognise the output from my Tivo as an rss feed.

Lloyd

luder
12-27-2006, 09:31 PM
anyone know how to play tivo://tivo.ip/2893099 from tivowebplus?

*edit*

I have change the now playing list links to the above link but, unable to have a rss aggregator to view the shows anyone have any ideas please pm thanks

ruexp67
12-28-2006, 11:40 AM
Another question: I guess I misunderstood before. Are you saying that the individual -view- links are not "clickable"?

Sounds like you need to enable hotlinks in messages, but I don't use either reader that you mention.

A feed can have a URL... that is what is taking you to the TWP Now Playing List when you click on the feed title. But items can also have links, which is how the "view" links work.

For debugging, would you try a reader that we know has the ability to have clickable article text, like FeedDemon or something like that?

LMK,

Bushman

I just had the same problem. I got -View- to appear in the feed using IE7 as the reader, but it is not a link. I tried it with FeedDemon and the link is there. It looks like IE7 does not support embedded links.

I am going to continue to research this, and see if there is a way to turn on Embedded links in IE7 RSS feeds.

jack
08-31-2007, 05:00 AM
Does this stuff still work? I have a DTV Tivo with 6.2 on it. I download the last
version of this posted here and I get:

http://tivoa/nowshowing What's on Living Room Tivo? en-us Fri, 31 Aug 2007 08:58:15 GMT http://www.tivocommunity.com/tivo-vb/showthread.php?t=271578 NowPlayingRSS (http://blog.durdle.com/nowplayingrss/)

INTERNAL SERVER ERROR
--cut here--
action_nowplayingrss '' ''
can't read "cache_ns_rec": no such variable
while executing
"lsearch $cache_ns_rec $fsid"
(procedure "print_nsrow" line 121)
invoked from within
"print_nsrow $chan $rec"
("uplevel" body line 7)
invoked from within
"uplevel $body"
invoked from within
"ForeachMfsFileTrans fsid name type $nowshowingdir "" 15 {


set rec [db $db openid $fsid]


print_nsrow $chan $rec


}"
(procedure "MOD::action_nowplayingrss" line 127)
invoked from within
"$cmd $p1 $p2 $p3"
(procedure "do_action" line 19)
invoked from within
"do_action $action $chan $part $env 1"
--cut here--

when I try and use it.

Thanks - jack

BOfH
08-31-2007, 05:20 AM
Hi,

I wrote the Now Playing code when I was using a Series 1 UK Tivo - a long discontinued device which is now gathering dust in my attic.

If anyone wants to take the code and ensure it works for later models (including all the new spiffy HD models you get in the US) then feel free. Maybe, if we're very lucky, we might some day get Tivo back in the UK, but I somehow doubt it.

Cheers,
Howard

BTUx9
08-31-2007, 12:04 PM
Does this stuff still work? I have a DTV Tivo with 6.2 on it. I download the last
version of this posted here and I get:
You're running an external module with TWP2. 2 problems with that:

1) TWP2 clearly states it broke compatibility with external modules... only those that specifically state they run on TWP2 work

2) TWP2 already has the rss feed rolled into it

try deleting the module and then running "update" within TWP to load the latest version

jack
09-03-2007, 09:27 AM
You're running an external module with TWP2. 2 problems with that:

1) TWP2 clearly states it broke compatibility with external modules... only those that specifically state they run on TWP2 work

2) TWP2 already has the rss feed rolled into it

try deleting the module and then running "update" within TWP to load the latest version

your right.. I'm a idiot.... I removed the added module, restarted TWP 2.x and
see the RSS link now. it works.

Sorry.