# Want to play iTunes AAC music on your TiVo?



## Dan203

Note: This plug-in has now been replaced by my new Universal Audio Plug-in....

http://www.3wdesigns.net/TDUAP/Setup.exe

It not only supports AAC, but also WMA, OGG and pretty much any other format you want it to support provided your PC has the appropriate DirectShow filter(s) installed for that format. 

Well now you can! I've written a plug-in for TiVo Desktop that allows you to play iTunes AAC files (unencrypted) on your TiVo via HMO....

The best part about this plug-in is that it uses a very open, DirectShow based approach to transcoding. So it could potentially be ported to work with any audio format that can be played in Windows Media Player. (which is most with the right filters) So if anyone has another format they'd really like to see supported on TiVo (i.e. OGG, APE, FLAC, etc...) please post your suggestion here and I'll look into producing a plug-in for it.

Note: This ia a Windows plug-in, you Mac guys already have the ability to do this. 

*New version released 3/20/06. It is highly recommended that you upgrade as this version fixes a bug which may cause TiVo Desktop to deadlock if you seek to many times consecutively. (i.e. used instant replay 4+ times in a row)*

Dan


----------



## VinceA

Excellent. I've got no use for it, personally, since I use pzand's WMA transcoder which works on the same basis as yours but I know that a lot of people will find it of great use. Now if someone could create a multi-format transcoder that would handle AAC, WMA, OGG, etc with one plugin, it would be great.


----------



## David Platt

Excellent! I can't wait to try this out. Big thumps up, Dan!


----------



## Dan203

VinceA said:


> Now if someone could create a multi-format transcoder that would handle AAC, WMA, OGG, etc with one plugin, it would be great.


I was actually considering doing that, however I figured I'd see how this one went over before I put the time into that.

Dan


----------



## pzand

Hey Dan! 

Nice job!! You're about to make me obsolete  
Good thing too, 'cause I've been slacking off with keeping up to date with new versions and all. Impressive that you'd been able to make this work through DirectShow! I know I tried and failed miserably.... Theoretically, that could open all kinds of new doors....

Very cool!

Peter


----------



## mfrns0123

Dan, after I install this, what do I need to do to make it work? anything?


----------



## Dan203

pzand said:


> Impressive that you'd been able to make this work through DirectShow! I know I tried and failed miserably


I tried this a few months back and also failed miserably, so I know how that is. However for some reason a new approach to the idea popped into my head last week and I decided to try again. I was literally shocked when I tried it the first time and actually heard audio coming out of my TV. 

Dan


----------



## Dan203

mfrns0123 said:


> Dan, after I install this, what do I need to do to make it work? anything?


You need to restart TiVo Server if it's already running. Then publish the music via TiVo Desktop. (if you already have your iTunes music folder shared then you can skip this step)

Dan


----------



## MarkSFCA

I can't wait to try this out when I get home! I hope it works for me.


----------



## megazone

Yeah, I'll have to try this when I get home. Though I wish it was a module for Galleon instead. ;-) (I've disabled TiVo Server because it kept bogging my box down and then crashing (Desktop, not the box))

I think the next format to support is WMA - with MP3, AAC, and WMA you cover the most popular formats and most users. After that it seems to be a crap shoot - WAV, FLAC, Ogg Vorbis, ATRAC, etc.


----------



## cheerdude

Dan,

Thanks for doing this... I assume that encrypted AAC will always be a no-go?


----------



## Dan203

cheerdude said:


> Thanks for doing this... I assume that encrypted AAC will always be a no-go?


Not if you use hymn. 

Although from what I hear Apple is making that harder and harder to use. Apparently it doesn't work on any music purchased with iTunes 6 and now they're starting to require iTunes 6 to purchase some songs. 

Dan


----------



## Dan203

megazone said:


> Yeah, I'll have to try this when I get home. Though I wish it was a module for Galleon instead. ;-)


Unfortunately Java is not my thing. And even if it were, from what I read, getting Java and DirectShow to work together is darn near impossible.

Dan


----------



## MarkSFCA

I guess all my Ituned purchased music is encrypted because this plug in didn't work for me. Is there anything I can do to make this work for me? Thanks in advance for any suggestions.

Mark


----------



## Dan203

MarkSFCA said:


> I guess all my Ituned purchased music is encrypted because this plug in didn't work for me. Is there anything I can do to make this work for me? Thanks in advance for any suggestions.


Do a Google search for hymn.

Dan


----------



## jefsta

Thanks for doing this. This was on my wish list. It works great.


----------



## Dan203

I've uploaded a slightly updated version of the plug-in. The only difference between this one and the original is the way I access the meta tags. The new method is more efficient and accurate and allows me access to more of the tags. Including Genre, which was missing from the original, as well as other extended tags, such as cover art, which may become useful should TiVo ever add support for them. 

The link in the original post has been updated with the new file. If you already installed the previous version and want to upgrade make sure to close TiVo Desktop and TiVo Server before running the installer. 

Dan


----------



## DVDerek

This is great. For audio formats - how about FLAC and SHN? Would this be possible?


----------



## Dan203

Any format that has a DirectShow filter could possibly be adapted to work with my framework. The only issue is metadata. It seems that most formats have their own way of storing metadata, which makes reading any information from these formats a little tricky. I'm thinking about writing a universal plug-in that will play anything that you can play in WMP, but will simply show the file name as the name of the song and nothing else. However we'll have to see how that goes.

Dan


----------



## DVDerek

Dan203 said:


> Any format that has a DirectShow filter could possibly be adapted to work with my framework. The only issue is metadata. It seems that most formats have their own way of storing metadata, which makes reading any information from these formats a little tricky. I'm thinking about writing a universal plug-in that will play anything that you can play in WMP, but will simply show the file name as the name of the song and nothing else. However we'll have to see how that goes.
> 
> Dan


Yeah, I'm only interested in SHN and FLAC to play back my live recordings - I don't much care if they have metadata or not. I'm not sure if they have DirectShow filters, but I'm off to google to figure it out...


----------



## Dan203

I looked and both of those formats do have DirectShow filters available. I'm currently working on the universal filter. So when/if I get it going I'll be sure to post something here about it.

Dan


----------



## HDTiVo

Dan:

Do you know if there is some combination of freeware/shareware, that coupled with your plug in could multicast MP3 streams to TiVoes throughout the house?


----------



## Dan203

The only way you would ever get that to work right would be to use Shoutcast to broadcast whatever is playing on your computer as a live stream, then select that stream on each TiVo. (there is a guide around here somewhere that explains how to do this) Even then the slight performance difference between TiVos could cause a reverberation effect as you transition from one room to another. 

A better option might be to get some wireless speakers for the other rooms. 

Dan


----------



## greg_burns

I was just reading here that the SqueezeBox 3 can do this (if you have more than one). I own one, but didn't know that. 



> And here's another one: you can buy several Squeezeboxes and park them around the house. Impressively, they can all play different music from the same computer simultaneously  or you can synchronize them so they all play the same thing.


----------



## HDTiVo

Thanks Dan and Greg. That SqueezeBox is interesting, and the wireless speakers are a thought. I am really trying to find a 'TiVo only' solution not just for myself, but because I think it could be popular with lots of TiVoites (imagine a free feature that could save them from buying $300 Squeezeboxes  )

I know about the delay effects. In my case, I've got it planned so that won't be an issue - there won't be in an overlaping area of sound.

I'll look for the Shoutcast thread. Anyone that finds it, please post.


----------



## HDTiVo

Greg:

What do you think this means?


> Third, the wireless Squeezebox offers an Ethernet jack that lets another component of your system  Xbox, PlayStation or TiVo, for example  join the network just by the addition of one cable


Also were you thinking that Squeeze's free open source server software might be repurposed somehow as a PC based multicaster that a TiVo can tune into like a Live365 station?

If this does not involve Dan's plug in then I'd like to continue this here... http://www.tivocommunity.com/tivo-vb/showthread.php?t=287721


----------



## greg_burns

HDTiVo said:


> What do you think this means?


I bought a wired Squeezbox (SB) for myself and a wireless one for my brother for an xmas gift. (They had $100 of second one at the time).

Anywho, what it allows him to do (since he has the wireless unit) is use his SB as a one port wireless bridge. The SB is wireless to his wireless router. His Tivo is hardwired using a crossover cable to the SB. This simplifies his setup and he didn't have to deal with the nightmare of wirless Tivo adapters.  You could conceivably hardwire any device to the port on the back on the SB (like an XBOX for example).

For me I have a WDS wireless network (using hacked Linksys WRT54Gs) so I didn't need this solution. In fact it is limiting cause you only get one port. Where with a WDS router I have 4 ports.

Hope that is not too confusing. 

Now is SB worth the price, since Tivo already does pretty much the same thing? I dunno. It was a pretty much an impluse buy. I hardly stream audio from either device. 

FYI, a SB can't play "Protected AAC" (.m4p) files either.


----------



## HDTiVo

greg_burns said:


> Hope that is not too confusing.
> 
> ......
> 
> FYI, a SB can't play "Protected AAC" (.m4p) files either.


I thought that would be the answer. Devices are really going to have to consider 1 port hub/switch as it becomes common to have 2, 3, 4, 5 ethernet devices attached to the entertainment system. There's not going to be be 5 cat5 runs to every family room  and a 4 port hub/switch may not be the most desired solution either. Raise your hand if you are old enough to remember daisy chaining Apple Talk devices.

Imagine that, another company stiffed on Apple's DRM.


----------



## Francesco

Very cool. Except that now when I try to play one of the mp3s in my iTunes Music directory, TiVo Desktop's server crashes.


----------



## Dan203

Francesco said:


> Very cool. Except that now when I try to play one of the mp3s in my iTunes Music directory, TiVo Desktop's server crashes.


That's very strange because this plug-in should have absolutely no effect on MP3 files. Those are handled by TD internally. In fact the way plug-ins works is they convert other audio formats to MP3 because that's the only format that TiVo natively supports.

Are you sure the MP3 file you're having trouble with just isn't corrupt? To test this you could try uninstalling the AAC plug-in and then try playing the suspect MP3 file. If it still crashes then you know it has nothing to do with the plug-in. If it doesn't let me know and I'll look into it more.

Dan


----------



## Francesco

Checked a few more tunes. Some, downloaded from legit sites that have simple directories (like Jonathan Coulton's _Baby Got Back.mp3_ as a straight download) just toss a server error and HMO backs out to the main menu. Others that are more complex and inlclude folders for album art and whatnot cause the server to crash outright and throw an error on screen. I have to go upstairs and restart the server.

Strange. These are all mp3s that worked before through HMO (when AAC didn't ). I'll uninstall the plugin and try them.


----------



## Dan203

That is bizare. Let me know how it goes after the uninstall.

Dan


----------



## Francesco

Wow. OK, stupid me.

The tunes that are tripping it up aren't mp3, they are mp3 that were converted to AAC by iTunes at some point. I misremembered that I had backed up my old iTunes directory and pointed to one that was all converted to mp3 for HMO use (made it huge!), then recntly pointed back to what I thought was the original with mp3s. Turns out they are converted mp3s. This directory still has a few recently-added real mp3s in it that play fine without the plugin. I've noted the exact tracks I just tried, re-installed the plugin and will report back. 

Meanwhile, I've got some work ahead of me getting rid of iTunes-converted mp3>AAC files and re-encoding with a better converter like LAME.


----------



## Francesco

Yep, your plug-in is not the cause; I'm guessing something in the re-encoding of mp3s to AAC is tripping it up with your plug-in installed. Without it, they just don't play - like any other AAC tracks. FWIW, they play fine on iPods and on iTunes on the PC.

here is a copy of the exception:


Code:


---------------------------
Assertion Failure
---------------------------
Tip: You can save an exact copy this message by pressing Ctrl+C and then pasting the copied text into another program (Notepad, for example).

Condition: !"Oops, a C++ exception occurred during an Api_Release() call!"
Function: TivoApiRef<Api>::Release()
Source: ..\..\..\TivoApi\Src\TivoApi/TivoApiRef.inl, 115
Module: C:\Program Files\TiVo\Desktop\TiVoServer.exe
Process: C:\Program Files\TiVo\Desktop\TiVoServer.exe
---------------------------
OK   
---------------------------


----------



## Dan203

I was just looking at my code and I use some very poor error catching when reading the tags from the AAC file. It's possible that this could be causing the problem if the tags are malformed or simply missing. I'll see if I can't throw together an update sometime this weekend. (it's still going to be a few more weeks before my universal plug-in is done)

Dan


----------



## Francesco

Your work is very much appreciated, Dan! Thanks!

[Say hi to Cyn for us from the Happy Hour, eh?]


----------



## Dan203

OK I've upload a new build. This version not only has better error checking on the tags but also fixes a bug which could have caused a deadlock if you seeked around in the file too much.

Dan


----------



## Francesco

No luck yet with those specific files - except that now they only throw an error instead of crashing the server.

I'm nearly 100% sure now that the problem is within those specific files, however. Just before un-installing the plug-in and installing the newest version, I added a few folders full of random mp3s and m4as from various sources with various missing tags, and they all play just fine.

I'll devote some time to it tomorrow and start removing specific tags, and let you know where the corruption is.


----------



## Dan203

What's the error? Also any chance you could email me one of these files? Or post it on a server somewhere so I can download it and use it for touble shooting?

Thanks for your help,
Dan


----------



## bbains

Hey Dan203,

Just wanted to add another vote for your universal transcoder. I have a lot of music in FLAC that I'd like to play through my tivo.

NNTR

Thanks,

Buddy


----------



## Dan203

Still working on it. I hit a little snag that hung me up for bit, but I think I'm past it and back on track. As soon as it's ready I'll be sure everyone here knows about it. 

Dan


----------



## mcitron

I am trying to use Universal Audio Plug-in to play my audible.com files through my TiVo. Should this work? Tivotogo sees the files and I can select them on my tivo, however other than the title, everything else shows as unknown. And when I hit play I get nothing. Looks like a zero length recording.

Any suggestions?


----------



## Dan203

Are they encrypted?

Dan


----------



## mcitron

I have no idea if they are encrypted. Since it requires a subscription to audible.com it is quite possible. Any way to tell?

What does it mean if they are (or are not)?


----------



## greg_burns

mcitron said:


> I have no idea if they are encrypted. Since it requires a subscription to audible.com it is quite possible. Any way to tell?


http://www.audible.com/adbl/store/home/howAudibleWorks.jsp?BV_UseBVCookie=Yes



> How is the audible file format different from the mp3 format?
> MP3 technology offers a number of different compression levels. Audible has chosen a level appropriate for spoken audio, resulting in smaller files and longer playback time. The Audible file format also provides bookmarking and chapter stops, and a state-recall that remembers where you left off listening before.
> 
> Audible also uses security encryption to protect purchased programs. While the more typical MP3 files contain the same kind of audio data, they are unprotected. You will not be able to convert the Audible format to MP3 because of this encryption. The measures taken by Audible are required to protect both the intellectual property rights of our Content Providers as well as the Authors.


Wasn't Audible.com taking a lot of heat over their format not being compatible with a lot of mp3 players?


----------



## Dan203

You might be able to get this to work. Try installing the WIndows Media Player filter from the bottom of this page...

http://www.audible.com/adbl/store/audibletogo.jsp?BV_UseBVCookie=Yes&Type=audiblemanagersoftware

Dan


----------



## knbetts

Thanks for this thread and the download! I just got this new tivo and was pretty upset that the itunes didnt work. Except of course, the purchased music still doesnt work. Do you know if you could burn a cd and copy the files back onto the computer? Maybe it would work then? Thanks again.


----------



## Dan203

Do a web search for hymn it'll help you out.

Dan


----------



## greg_burns

Dan203 said:


> Do a web search for hymn it'll help you out.
> 
> Dan


Does hymn support that latest versin of iTunes? Haven't kept up with it myself. I thought the latest iTunes broke it once again. Could be wrong.

Don't need to burn a CD to convert to mp3 format. Don't have the steps in front of me, but iTunes will convert to mp3 without wasting a CD. (pretty sure I've done this in the past)


----------



## tonyf3

Dan203 said:


> Note: This plug-in has now been replaced by my new Universal Audio Plug-in....
> 
> http://www.3wdesigns.net/TDUAP/Setup.exe
> 
> It not only supports AAC, but also WMA, OGG and pretty much any other format you want it to support provided your PC has the appropriate DirectShow filter(s) installed for that format.
> 
> Well now you can! I've written a plug-in for TiVo Desktop that allows you to play iTunes AAC files (unencrypted) on your TiVo via HMO....
> 
> The best part about this plug-in is that it uses a very open, DirectShow based approach to transcoding. So it could potentially be ported to work with any audio format that can be played in Windows Media Player. (which is most with the right filters) So if anyone has another format they'd really like to see supported on TiVo (i.e. OGG, APE, FLAC, etc...) please post your suggestion here and I'll look into producing a plug-in for it.
> 
> Note: This ia a Windows plug-in, you Mac guys already have the ability to do this.
> 
> *New version released 3/20/06. It is highly recommended that you upgrade as this version fixes a bug which may cause TiVo Desktop to deadlock if you seek to many times consecutively. (i.e. used instant replay 4+ times in a row)*
> 
> Dan


We do?????? (Mac Guys) I've been waiting for 3 years for that.
Did I miss something?


----------



## Dennis Wilkinson

tonyf3 said:


> We do?????? (Mac Guys) I've been waiting for 3 years for that.
> Did I miss something?


The same hack that allows TiVo Desktop to decode unencoded AAC also allows other audio formats and codecs supported by QuickTime/iTunes. While I haven't tried every codec out there that works in iTunes, AIFF, WAV, AAC, and ALAC have all worked fine in my testing. With the Flip4Mac codecs, you might be able to support WMA, although I haven't checked to see that iTunes would play nice in that case. OGG might be iffy, though, since I'm not aware of a fully-functional OGG decoder that runs as a QuickTime sound codec.


----------



## megazone

greg_burns said:


> Does hymn support that latest versin of iTunes?


Not yet, iTunes 6 broke JHymn and they're still working on it. But if you still haven't upgraded to 6 - or if you download 5 and setup a NEW account for purchases - you can still buy music with 5 and strip the DRM.

Personally I just shrugged and kept using 6, I figure someone will get a stripper working eventually. Everything I bought before the 6 upgrade I'd stripped.


----------



## eblair

My new TiVo won't seem to find any playable music files that are m4a format. mp3's work predictably fine.


----------



## Dan203

Before the plug-in is recognized you have to exit both TiVo Desktop and TiVo Server. You exit TiVo server by right clicking the little TiVo icon in your tray, selecting properties, then clicking the exit button. After that start up TiVo Desktop again, go to the Music section and then publish the folder(s) that contain all your m4a audio files. Then finally restart the server from the Server menu.

Also keep in mind that this plug-in only works for unencrypted audio files. So it wont work for anything you purchased off of the iTunes Store.

Dan


----------



## DuncanBlkthrn

Any interest in writing an application that will stream Shoutcast (in both MP3 and AAC/AAC+ formats) to Tivo? So far Galleon is the only thing that does that, but it's quite buggy and really isn't being maintained by anyone..


----------



## ah30k

megazone said:


> I've disabled TiVo Server because it kept bogging my box down and then crashing (Desktop, not the box)


A little off topic, but I've had this problem since day-1 and felt like I was the only one in the world with the problem. The ehrecvr service leaks memory like crazy then core dumps. Rinse & repeat.

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


----------



## VanGoghLikesTivo

With this add-on active, I can see iTunes on my Tivo, but when I try to play them or any other audio file (even mp3 files) I get no music on the Tivo.


----------



## Dan203

The newest version is posted in this thread...

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

Make sure you uninstall this AAC only version first otherwise they will conflict.

Dan


----------



## ph-list

I've tried the link in the first message of this thread to install the software but I keep getting a "corrupted install files" message ... is there another source/lin?


----------



## Dan203

Click the link in my above post

Dan


----------



## jackpollard

Does this plug-in work with 2.8? It does not seem to for me.


----------

