Archive for the ‘music’ Category

Streaming iTunes Library?

Friday, March 21st, 2008

I’ll start off with a quick explanation of my set up, then what the problem is, and finally the obvious solution.

I have 2 computers. One is a 15″ Macbook Pro which I recently purchased to replace an iBook G4. My other computer is a desktop Windows box that I used to do all my gaming on. I’ve mostly grown out of that, so I’ve been cannibalizing it slowly and using it as a file server.

Since my laptop only has 160GB hard drive (for now) and I have a lot of music, I have most of it on my desktop and stream it through iTunes to my laptop. This is where the problem lies. I always put my laptop to sleep when I’m not using it because I hate unnecessarily using power. The less I use, the more Hydro can sell to the Americans, which means more money for the Canadian economy, and ultimately less power that has to come from coal. Ever time I close my laptop though, iTunes disconnects from the share on my desktop. I come back a few hours later, maybe just want to listen to a track or 2 while I get ready to go out, but iTunes has to reconnect and (I assume) download the entire library all over again. For a library of my size, we’re looking at 30 seconds or more. Why?

Here’s what I’m wondering. I know that iTunes stores it’s library locally in an XML file. I assume that in the background all iTunes is doing is serving up a stripped down version of that XML file to tell the client iTunes what tracks are shared. My library, and I’m sure most peoples, does not change all that often, at least not daily. So why can’t iTunes cache and only redownload it if it’s recently been changed? It seems so simple to me, so much so that I figure there has to be a much more technical reason as to why that isn’t possible. It’s as simple as storing a lastModified field in XML and having the server send that over first.

Is it because it takes too long to make the initial connection? Maybe that’s what’s taking so much time and not the transfer of the track list. I’m not sure, but I feel that there must be a solution, and I feel that Apple should be all over it seeing as their primary market is Laptops and a two computer model (a la Air).

innerHTML and XHTML Pages

Saturday, November 18th, 2006

I have resumed working on an old project, basically a web based controller for iTunes. I had a working version a few months ago but one day Apache decided not to let me create COM objects any more, so I scrapped it. The code was messy, the UI was horrid, and the AJAX implementation was problematic. So I started a new version, this time diving into YUI as my AJAX library (save some time by not re-inventing the wheel) and some new Javascript tricks to make the whole thing much better. Work always tends to go on and off with me, but I’ve spent a considerable amount of time on it within the last few days. So much that I found a new DOM annoyance.

This time, the deal is when adding nodes using the (not so standard) innerHTML method on an XHTML page, it is all kinds of bad to add your markup in different lines.

element.innerHTML = '<div id="title">';
element.innerHTML += '<div id="name">name</div>';
element.innerHTML += '<div id="artist">artist<.div>';
element.innerHTML += '</div>';

Turns out that at least Firefox 2 and Safari want to make sure I have valid XHTML markup and will auto close that <div id=”title”>. After spending some time in FireBug and on quirksmode I discovered this is by design and it is quiet easy to work around! Here it is.

var markup= '<div id="title">';
markup += '<div id="name">name</div>';
markup += '<div id="artist">artist</div>';
markup += '</div>';
element.innerHTML = markup;

Works like a charm. It seems that basically the browser ‘validates’ the string each time you set innerHTML, makes sence to me. Before you ask why I don’t stick with the W3C DOM, it is just because it is a pain to have to create each element one by one, and then create text nodes, and all that fun stuff. Not to mention when you start dealing with larger number of nodes it can get slow (as proven by quirksmode). There was an other suggestion, to use createContextualFragment(), and honestly I can’t see why that wouldn’t work either.

Itunes Sound

Thursday, September 14th, 2006

Well, I have temporarily fixed my iTunes 7 for Windows sound problem. After searching through forums I discovered that people were having luck playing with the Qucktime audio settings (Start>Contrl Panel>Quicktime>Audio Tab). For me, it’s the the Size under the Sound Out section, it appears iTunes doesn’t like 24 bit, so changing it to 16 bit has some what fixed the problem. The only thing is now the audio is noticeably quieter. What used to be 2 notches is now 10 (when using my diNovo to adjust volume levels). Others are having to turn on Safe Mode and adjust the Rate in order to fix their problems, I wasn’t deep I guess.

But fear not, for iTunes 7 has many more issues around the corner. Now, for whatever reason it’s taking around 5 minutes from the time I click the iCon to the time it is able to play music, and it wouldn’t stop bugging me to register my iPod, which actually caused more freezing. I think once Apple gets these problems fixed iTunes 7 will be loved by all, but until then I would probably recommend against upgrading.

One new feature that I discovered today was the option to back up your music to a disc. I would be fine with losing all my hard drives that contain documents, operating system files, and images, but if I lost my music hard drive, I would be devastated. So this seemingly easy to use back up method is a godsend. While I cringe at spending 11 DVDs on it, I know that one day those drives will die, so I’m sure once Apple fixes everything I will be backing it all up. Hopefully DL DVDs will have come down in price by that time too, that or HD DVD will be readily available for PCs. View the full guide at http://www.tuaw.com/2006/09/12/how-to-back-up-your-music-using-itunes-7/.

Showtime? Not So Much

Wednesday, September 13th, 2006

So, Steve did his thing today and released a bunch of fancy new products. Like usual, I followed as much of the presentation live on macrumors.com as I was awake for, eagerly awaiting a new wide screen iPod for me to waste my savings on. While that never came, we did get a bunch of cool new items. A new iPod there is, but my favourite item was iTunes 7, primarily the new iPod integration and album art. As soon as the presentation (note I’m not saying keynote…) was over I quickly jetted over to iTunes.com to download and install it… This is the tale of my journey…

(more…)

Update

Friday, February 3rd, 2006

Wow. Downtime sucks yo! And apparently, so does my host! Well, not entirely. My host, cpphosting.net, somehow managed to lose my account. Don’t ask how or why, but regardless after some harasing on AIM, he managed to get me back online. Luckily my good friend, Josh hooked me up with a premo cronjob to backup my site every night, so I had a full backup from the day it went down, and upon restoration had the site back up in 1/2 hour. So that was actually about 2 weeks of downtime. I wasn’t too worried about it, but I eventually did need the site back up and running.

In the mean time, I have been working on a few other projects, most which I cannot mention yet, so I’ll let ya guess. The good news is that I starting working on a redesign again. The bad news is I scrapped the whole old-new design and started from scratch again. This time, I am not re-using any code. This site was coded so long ago that as I was redesigning it, I ended up re-coding a lot of it more effiecently with new stuff that I have learnt in the past few years, so this time around I am only reusing the database, everything will be new. There was waaay too many bugs in here anyways.

Another thing that I have decided to do is get some good Web2.0 integration going on. I have recently started using del.icio.us and flickr, so instead of the (buggy/functionless) gallery that I built, I am going to just use flickr, as well as have some del.icio.us bookmarks up as well. It’s gonna take some time to learn how to use their APIs, but I think in the end it will speed up development. I also plan on messing around with some AJAX, though nothing big as there is really no need for it here. I’ve been using it a lot lately and I really like it, though I am still tweaking my AJAX toolkit to get it perfected.

The next totally exciting news I just read, my favourite Indie band, Death Cab for Cutie is coming to Winnipeg! I already saw them in Montreal in October, but that doesn’t mean I won’t be scoping them out in my home town again! Wow, first I get a weekend, then news of my favourite band coming to town… what else could I ask for, besides maybe a bit of pink.

Lastly, I command you all to go out and buy a Logitech diNovo. I am sure everyone has looked at it on the Logitech web site and wished they could afford it. Well, I bought myself a birthday present! It’s still hurtin the bank, but wow is it ever amazing. I have yet to start tweaking everthing, but I have never used a better keyboard, and the MX1000 that comes with it is the best mouse I have used to date (MX510, you will always hold a place in my heart). So when those income tax cheques come in, and you finish paying off you’re credit card, spend that extra bit on the diNovo, you won’t regret it!

!– jdyck –!


Bad Behavior has blocked 456 access attempts in the last 7 days.