For awhile, I've wanted to try my hands at writing a gadget for the Windows Sidebar in Vista, but I could never come up with a project idea that was small enough to accomplish and useful enough to justify. Since we recently added two TiVo HD units to our home network, I thought it'd be handy to expose their Now Playing lists. I knew the data was available over our home network, because the TiVo Desktop software displays a lot of it. Turns out, the TiVo Developer Resources section of their site contains just enough to get going.
Without going into too many details, recent versions of the TiVo software on certain units (TiVo HD and TiVo Series3 HD, I think) contain a small web server that can be issued requests. These requests are passed via the query string and return their results as XML. For example, our downstairs TiVo unit has an IP address of 192.168.1.104 (you can find the IP address of your TiVo by navigating to Messages & Settings, then Settings, then Phone & Network). If I open my web browser and navigate to https://192.168.1.104/TiVoConnect?Command=QueryContainer, I'll receive an XML response that includes information like the title of the unit and a URL to obtain the current Now Playing list.
If you try this same request with your own TiVo (using the correct IP address, of course), you will first run into a security certificate warning. If you decide to continue, you'll then be asked for credentials. The user name is always tivo, and the password is your media access key. Your media access key can be found in the right column by logging in to your TiVo account online or by navigating to Messages & Settings, then Account & System Information, then Media Access Key on your TiVo. For a more "friendly" Now Playing list, you can also navigate to https://192.168.1.104/nowplaying/index.html using a similar procedure.
When I started writing the TiVo gadget, I could not successfully complete an XMLHttpRequest for the XML data because of the certificate warning (which I couldn't see, since this was all happening behind the scenes of the gadget). I soon figured out that the actual certificate is issued to the service number of the TiVo unit, but since the requests are being made to an IP address instead, the mismatch causes the warning. It's kind of like saying that I trust Mike Swanson, but I don't trust Swanson, Mike (same person, but represented differently). Ideally, then, I would want to issue my request to the service number of the TiVo so that the certificate would match.
On most networks, you can reach a machine by its IP address and its name; that's because the machine shares its name on the network. Unfortunately, the TiVo doesn't share its name (the service number) on the network like other devices. To resolve this issue requires a few steps, and if you decide to download and try the TiVo Now Playing gadget, you'll need to perform them:
Whew! Sorry that you had to go through all of that, but I'm not aware of any other method (short of possibly installing a custom ActiveX control) to get around this certificate issue. TiVo could solve the issue by broadcasting its service name on the network. Perhaps they'll do that in a future version of their software.
Assuming you've made it this far, you can download the TiVo Now Playing v1.0.1 gadget (182KB) and install it on your Windows Sidebar. Click the little "wrench" icon to configure the gadget. Enter your service number in TiVo address(es), and your Media access key. If you have more than one TiVo on your home network, you can enter multiple service numbers separated by semicolons. Note that all TiVos in a single household share the same media access key, so you only need to enter one of those.
This post is already rather long, so I'll quickly summarize the current gadget features:
I'm sure there's more I could say, and I'll probably say it in a future post. Please enjoy the gadget, and pass along any comments, suggestions, or questions via e-mail or by leaving feedback.
Update: If you downloaded version 1.0 of the gadget and you're not seeing any of your programs listed, please try version 1.0.1. Hopefully, this will fix the issue.
"Great idea...I installed under Windows Vista and I have 1 TiVo HD and all I get is (unknown)(0).
I can see the XML document showing the link for now playing in my browser so I know I can reach the TiVo...just can't seem to get it to work on my machine."
I've having the same problem. I went to the 1.0.1 version and still can't seem to get the sidebar gadget to connect.
However, I can access myTIVO through IE7, Host File has been set and works. Certificate installed and no issues connecting to the tivobox though IE7.
Could their be some firewall or other setting?
TIVOHD with latest firmware.
Patrick...if you don't mind, drop me an e-mail (link in upper-right), and I'll reply. Then, if you could send me the XML from the Now Playing link, that would be helpful. The XML doesn't come across very well in the feedback section. Thanks.
Good work Mike. Thanks for sharing this with us. Keep em coming.
Mike Swanson recently blogged about a cool new gadget he wrote for the Windows Vista Sidebar, the
I love this Gadget, its probably the most useful beyond the weather
Pretty sweet. Almost as good as my XM Radio gadget. What I'd like, though, is to be able to affect the list of recorded programs by deleting or changing the keep time, etc. I'm still not sure why TiVo doesn't have a webserver on this thing for easy management...
Great job though!
same problem as described by person above:
I have vista64 ultimate, I am the admin, even tried running as admin. I did the first step in ie7 by adding it to trusted sites. I can also get to the certificate on the xml page, but nowhere can I add a certificate.
I like the gadget, I want the gadget, I have installed the 1.01 version. Vista will not allow me to change the security settings for the certificate. I have Vista 64-bit Home Media Edition, and yes, I am the administrator. When I get to the Certificates screen showing the Tivo certificate, the ONLY buttons that are not disabled are the OK button and the button to close the window. I've disabled my firewall, added both User and Computer Certificate control to the MMC, and still nada. Any suggestions?
Nice job... perfectlittle Gagget... Do you think you can add a hyper link so we can download the show in the popup window.
I'm having the same problem as Patrick, except my TiVo isn't HD. Installation of everything following your steps worked great. Just stuck with unknown (0). Please let me know if there's a solution.
@Patrick & Jen: The "unknown" tells me that the request for the name of the TiVo isn't coming back. This request is the result of issuing the https://123-0000-4567-7f7f/TiVoConnect?Command=QueryContainer query in the blog post. If you issue this query (with your service number, of course) in IE7, do you get a response from your TiVo without any certificate warnings? One other thing to check is that you're only entering the service number in the gadget configuration window. In other words, don't include the "https://" or anything else...just the digits, characters, and dashes of your service number (like: XXX-XXXX-XXXX-XXXX).
@szczesnyb, Michael, & Andy: I will add a download link to the description window...hopefully within the next few days.
For those of you with 64-bit problems, I'm not sure what to suggest, and I can't test that configuration, since I run the 32-bit version of Windows Vista.
I made a very minor update to my TiVo Now Playing gadget that allows you to download recorded shows to
Just added a video download feature to the gadget. Read more here: http://blogs.msdn.com/mswanson/archive/2007/12/22/tivo-gadget-v1-0-2-enables-video-download.aspx