More than you wanted to know about the Internet Radio Player

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
FreePlay
Posts: 71
Joined: Wed Jan 04, 2006 6:53 pm
Location: Schenectady, New York, USA

More than you wanted to know about the Internet Radio Player

Post by FreePlay »

I've spent quite a bit of time fiddling with the Internet Radio Player plugin Sony added in firmware 3.80, as it offers many interesting new possibilities, such as a pseudo-XMLHttpRequest capability and directory scanning functions built into the web browser. It also appears to be the first public acknowledgement of the screenshot plugin, since there's a function (albeit a placeholder for the moment) with a name that implies that it's solely meant to be used for taking screenshots.

As part of the process I've been gradually documenting the various functions that we've been given with this plugin; a chart of everything I've discovered is available here in glorious, eye-burning color.

Last but not least, when you first set up the radio player, you'll download a .PRS file which contains information about the radio player you're using -things like the title, URL, author, copyright info, icon, etc. I reverse-engineered the .PRS format for kicks and wrote a tool for displaying information about .PRS files and spitting out the associated icon. Source/binaries for the tool are located here.

I know most people don't get excited about web portals, but there's a lot of power tucked away in the radio player plugin if you know how to properly flex its muscles.
User avatar
Wally
Posts: 663
Joined: Mon Sep 26, 2005 11:25 am

Post by Wally »

*pats freeplay* Good boy :)
Hellcat
Posts: 83
Joined: Wed Jan 24, 2007 2:52 pm

Post by Hellcat »

Nice!

How did you get the function name? Bruteforcing NIDs?
How would one call all the functions? From a custom radioplayer .PRS?
FreePlay
Posts: 71
Joined: Wed Jan 04, 2006 6:53 pm
Location: Schenectady, New York, USA

Post by FreePlay »

The function names are javascript; they're referenced as plain text in the radioshack.prx :)

You'd call them from a custom .PRS, yes. You edit your .PRS to point to whatever file you want, then add this in your html code:

Code: Select all

<object name="psp" id="psp" type="application/x-psp-extplugin"></object>
Then you can script the 'psp' object however you want, using the functions I listed, e.g. 'psp.sysRadioPlayEffectSound()'. The functions are only available if you use the 'Internet Radio Player' icon in the XMB, though; the radioshack plugin isn't loaded otherwise.

Maybe this weekend I'll write a tool for making custom .PRS files based on plain text input. That'd be nice, I think.
Last edited by FreePlay on Sun Jan 20, 2008 2:25 am, edited 1 time in total.
Hellcat
Posts: 83
Joined: Wed Jan 24, 2007 2:52 pm

Post by Hellcat »

I get the feeling that radio thingy will get a very nice "toy" to play with :D

Not bad! :up:
FreePlay
Posts: 71
Joined: Wed Jan 04, 2006 6:53 pm
Location: Schenectady, New York, USA

Post by FreePlay »

Here is what I know about the PRS format so far.
FreePlay
Posts: 71
Joined: Wed Jan 04, 2006 6:53 pm
Location: Schenectady, New York, USA

Post by FreePlay »

Fixed :)

I've made a program that lets you make and edit .PRS files. Enjoy.
Last edited by FreePlay on Mon Jan 21, 2008 7:42 am, edited 1 time in total.
Team-3GO
Posts: 17
Joined: Wed Nov 21, 2007 7:40 am
Location: PSP-Development

Post by Team-3GO »

thanks for sharing the infos freeplay.
played around with the radio stuff for two days while i had sony 3.80.
now since there is 3.80 M33 its time to look at it again.
"Ignorance is the night of the mind, but a night without moon and star."
zefie
Posts: 6
Joined: Tue Feb 12, 2008 1:31 pm

Post by zefie »

Thanks for the great player, FreePlay.

Here is my modification of your player code to enable metadata:

http://psp.zefie.com/radiotest.html
http://psp.zefie.com/zefie.prs

Edit: Screenshot
Image

Javascript file:
http://psp.zefie.com/js/radioplayer.js

updateStreamTitle() is a modified version of one of Sony's javascript routines.
Post Reply