Posts Tagged tricks

Getting Audiogalaxy running on Ubuntu 11.04

I recently started using Ubuntu as my main OS, and in fact I successfully chmodded something for the first time today, so I’m not exactly an expert. But this was painful so once again, hopefully I’ll save others some time by writing it up.

Audiogalaxy is a platform for streaming your music from a pc to any number of other web-enabled devices (web browsers, smartphones, tablets). It’s not supported for Linux yet, but I found this post encouraging me to try using WINE (WINE Is Not an Emulator, as if that clears anything up :D ). so I gave it a go.

It installed just fine with WINE, but then sat there doing nothing. It didn’t seem to notice any music files that it would be able to stream. I checked that WINE was set up, and indeed the fake Windows filesystem in ~/.wine/drive_c/users/MY_USERNAME/My Music was a symlink (I think!) correctly pointing to my actual music directory (~/Music).

As the post above alludes to, I had to “hack the sqlite”, but I had to take a guess at what that meant. It’s working for me, but use at your own risk. I don’t even know what the “download” column in the appropriate table is for, so if at some point it chooses to overwrite your files with new downloads… let’s just say backups are important. So, that said…

Update: have a screenshot, on the house:
Image Hosted by ImageShack.us
Uploaded with Shutter. Hosted by ImageShack.us. Click to make big.

  1. Close the Audiogalaxy helper, if it’s open.
  2. Open the file ~/.wine/drive_c/users/YOUR_USERNAME_HERE/Local Settings/Application Data/Audiogalaxy/ag.dat with your favourite SQLite browser thing (never having used one before, I picked Sqliteman from the Ubuntu Software Center, which worked just fine).
  3. Find the table called shares_v1, and add a row (the table was initially empty for me, which suggested I’d found the issue!) with the values “C:\users\YOUR_USERNAME_HERE\My Music” in both “path” and “downloads” columns. Commit the change to the database if you haven’t already.
  4. Start the Audiogalaxy helper again.
  5. Hopefully now if you go to Audiogalaxy.com and log in, you’ll see your collection is starting to fill up with music! Play something triumphant and bask in the glory of success. Well, that’s what I did, YMMV.
You can leave questions below, but I’m honestly not sure I’ll be able to help much, being rather a n00b myself. Perhaps your fellow visitors might offer assistance though. I’ll give it a go too :)

, , , , , ,

2 Comments

Playing Sounds in Phonegap on iOS

I’ve worked out that iOS is pretty funny about sounds, especially as it turns out Safari makes it very difficult to play them automatically, thus saving on users’ precious data usage plans (never mind the fact that my sound effects are already downloaded onto the device and are smaller than your average jpeg anyway!). It’ll do it in response to a user action, but that’s such a woolly and undefined concept that I had to fiddle around for a while.

I didn’t have any luck using the usual Phonegap methods. Well I did but it only worked when headphones were plugged in, for some reason, and I eventually gave that up as a dead end. It appeared to play the sound, firing onSuccess callbacks and such, but I couldn’t hear anything, thus rather defeating the point of the exercise.

Anyway, here’s an example of what didn’t work for me, followed by one that did. Hope it’ll save you some silly bother.

Doesn’t work:

var myAudio = new Media('sounds/mySoundFile.wav');
myAudio.play();

Works:

<audio src='sounds/mySoundFile.wav' id='sound'>
<button id='myButton' onClick='document.getElementById("sound").play()'>

If like me you prefer jQuery to the monstrosity we like to call raw Javascript, it would appear that inside your click() function you’ll need to use $(‘#sound’)[0].play() rather than $(‘#sound’).play(). I think that’s because then you escape the jQuery-ness and call the DOM’s native play() method on the <audio> element itself, not some set of jQuery-enhanced elements.

So, that was nice and straightforward, thanks Apple!!! In case you can’t tell, I’m being sarcastic :P

 

, , , , ,

2 Comments

How to Mute Adverts in Spotify

spotify logoI realise I may be shooting myself in the foot, revealing this tip – if word gets out, I’m sure the Spotify team will patch it immediately – but I’ve found a way to quieten those pesky commercials.

If you’re not aware, Spotify is a free music streaming service that you browse with a super-fast, proprietary media player. It boasts millions of tracks and many thousands of albums, playing at high quality and with instant access. The price you pay is occasional adverts, which are significantly less frequent or annoying than those on commercial radio. They are still quite annoying though, nonetheless. And, cleverly, turning the volume down actually pauses the ad, so you’ve no choice but to listen to it. Until now.

So here’s what you do: when the advert starts playing, hit pause. You can then turn down the volume on the player and press play, and the advert will resume playing silently. You can watch the little timer to see when it’s done, and then just turn the volume back up. I haven’t tried pausing and then using the system volume to turn down the sound, so I’ll report on that soon.

Before I go, I’d just like to plead with Spotify to open-source the software, so people like me can start making add-ons for it, just like with Songbird. Your service has rocketed in popularity, leaving a small team to service over a million users. Right now, all we want is an equaliser. Oh and a lyrics plug-in. And not to mention…! So open-source the player and we’ll fill in the gaps. Come on, you know it makes sense.

edit: this article used to be titled “How to Mute Adverts in Spotify – July 2009″. However, as of April 2010, this technique still works just as well as it ever did – Spotify have taken no actions to close this loophole. I’ve taken the July part of the title out in order to make it obvious that the article is still relevant today.

, , , , ,

25 Comments

Atom feeds for RSS-only readers (yes, they still exist!)

Yessssss! Nothing beats the feeling of, well, beating a problem that was initially difficult to get your head around. I’d been trying to add a Feeddit (Digg feeds mashed up for direct links) feed to my new desktop-based mini feed reader in the quite nice Enigma for Rainmeter. Enigma adds little gadgets to your desktop in XP similar to those in Vista, so you can keep an eye on the news as well as your CPU usage and hard drive space… and calendar, weather, whatever.

I couldn’t work out why this one feed wasn’t working when my Lifehacker and Guardian feeds were showing up just fine. I’m not sure what eventually clicked in my head, but I got the hunch that Enigma’s reader was quite a simple, hand-coded reader and possibly only set-up for rss and not atom feeds like those on Feeddit. I needed to bridge the gap, and the only obvious answer on Google was 2rss.com – a conversion service that didn’t work (for me). With a little more ‘digging’ though, I found a Yahoo! Pipes app by Bruce Boughton, which did the trick. Voila, after many previous attempts leading to me staring at nothing, I finally had a bunch of topics appear in my reader.

If you’re trying to get an atom feed into Enigma or another bargain-basement reader that doesn’t support it, visit the above Yahoo! link, or modify this url as appropriate and paste it into your reader:

http://pipes.yahoo.com/pipes/pipe.run?_id=PicO8ejT3BG6sr1Uy6ky6g&_render=rss&atom_feed_url=<YOUR ATOM FEED HERE>

Hope that saves someone out there some time; I’ll never get that hour back, but as usual, I think I’ve learned something in the process. Just don’t ask me what.

, , , , ,

No Comments

Mouseless browsing and Ctrl-K in Opera 9

operalogoThe Opera web browser has now firmly been edged out for me by Firefox 3 after many years of fine service. The latest Firefox is a great browser, and with extensions like Greasefire for easy website customization, Delicious.com web bookmarks integration and instant picture editing with Picnik, it’s becoming increasingly difficult to walk away from.

There’s still life in an old dog yet though. Opera does one thing much better than FF – mouseless browsing. I’ve tried – and failed – to find anything like it in a Mozilla addon. Simply put, holding down the shift key allows the user to flit around a page, going from link to link with the cursor keys. Hitting Enter then takes you to that link, and the process repeats. It’s massively intuitive, and it works really well. Since getting a gorgeous new Samsung NC10 netbook whose only drawback is a slightly scrawny touchpad, I’m finding this gives Opera a new lease of life. Boot it using Launchy and your fingers never leave the keyboard.

Perhaps a just tribute to the impact and influence Opera had as a forerunner to Firefox, it’s very easy to go back to Opera and use mostly the same keyboard shorcuts you currently have ingrained into your muscle memory. The only significant change for me is that Ctrl-L still takes you to the location bar, while Ctrl-K tries to open your email instead of the search bar. Dear Reader, fear not, for I have a solution.

To alter the behaviour of Ctrl-K in Opera, go to Tools->Preferences, switch to the Advanced tab, and select Shortcuts down the left-hand side. In the Keyboard pane (below the Mouse pane), click Edit… for the profile you want to change (probably your current one). Type the letter ‘k” in the search box, and look down the list until you see an entry on the left that reads ‘k ctrl’, or ‘ctrl k’. On the right is its current assigned function, which should say something about mail. Double-click the function and start typing “focus search field”. The auto-complete should be able to fill the rest in for you.

Et voila! Ctrl-K now takes you to the search bar as expected. You can now effortlessly browse websites using just your keyboard, and pretend you’re still in Firefox!

Update 14/3/09: I’m finding some other useful tidbits and thought I’d share them, though they’ll probably elicit a ‘duhh’ from many readers. First, shift-enter opens a link in a new tab. Second, ctrl-enter is the equivalent of hitting the Wand button. And third, I previously thought that Opera popup dialogues were mouse-only affairs, since they had no obviously associated keys like alt-s to ‘Save’, and hitting the cursor keys did nothing. Well you can use tab to cycle round the options. Still nasty, so let me know if you have a better way.

There’s an official guide, Use Opera Without A Mouse, but frankly the tutorial is about 10 times longer than any time-saving technique ever warranted.

, , , , ,

7 Comments