Topic: btplay issues

Hey all,

So I got annoyed with adverts for Pandora as I'm from the UK and can't use Pandora. I can use last.fm though, so I started writing a widget for that instead, and hopefully later I'll transform it into a music service for my chumby.


Anyway, I've got it kind of working, but the volume knob on the side of my Chumby One has no effect? Is this something btplay related, or do I have to build in volume knob volume setting myself?

It also occasionally doesn't play when skipping to the next track, despite me being able to play the steam the same URL in something like VLC? I'm telling btplay to stop and then start with the new stream, is this the right way to do it?

Finally, is there a way in flash to know when btplay finished streaming the track? Alternatively, I know the duration of the track from the playlist XML last.fm send back, but I'm not sure how to run a nextTrack() function when that time has elapsed?


Any advice would be appreciated smile

Re: btplay issues

The volume knob behavior is handled by the Control Panel. It's pretty simple - the knob produces mouseWheel events and there's a handler that changes the volume accordingly.  As a standalone movie, you'd have to handle that yourself, but once you're a true music source, the CP will do it for you.

As to detecting whether the track is done, you can do that by monitoring the value of ChumbyNative._getAudioPlayerState().  I believe the music source API has a more friendly function for that.

I don't know why it would fail to play a track.

Re: btplay issues

Cheers for the speedy feedback Duane smile

I only noticed today however that controlling btplay from actionscript doesn't work when running as a widget, only when run locally. Which sucks as I wanted this to be a widget that could be used without messing about with USB sticks of data or SSH.

Seems like I have no other choice than making my own music source and making anyone who wants to use it mess about with USB sticks if I want streaming audio.

I'm not so great with actionscript though, and this music source stuff is a tad confusing to me. Is there anyone else on the forums that likes last.fm and wants to help with the flash side of things?

All the last.fm side of things is done and works (though it might be partially against last.fm terms and conditions...), from signing in to selecting stations and getting the playlist from last.fm (paid member or not). So all I need to do now is the interface to let users control all this. But I've only ever used AS2 a couple of times before and all self/Google taught. So I have no idea how separate .as files work, and my previous forays into chumby widgets could only be best described as "it'll do".

So yeah, anyone who knows about flash and actionscript well, and even better to know about chumby specific flash, help me!
In the mean time I'll struggle on, alone, as it seems the old python and lastfmproxy based solution I found in the forums from '08 doesn't work anymore and was a memory hog when it did.