PDA

View Full Version : New Live365 Plugin for 6.1



chrisp810
2005-06-14, 22:01
As a Live365 junkie, I was disappointed with the state of the Live365 plugin. I spent the last week or so rewriting large parts of the latest Live365 plugin that came with 6.1 (my rewrite is based off the 6/8/05 nightly, and it doesn't appear anything has changed since then). I also bumped the version number to 1.20 (from 1.10).

Upgrades include:
- Now has a web interface
- - EN and Default skins provided
- - Supports all Live365 operations available through the SB2
- - Auto-login like the SB2 interface does
- - Paging of all search/browse results
- - Extended search results in web searches for artist/track/CD (can be toggled on/off in Server Settings)
- Fixed problem with all browse/search operations through SB2 returning a max of 50 results and never fetching more
- Fixed a few typos in parameter lists and text

I tested the hell out of this thing and it seems to work perfectly with SB2, SoftSqueeze, and the web I/F. However...

Caveats:
- This was built and tested only on SlimServer 6.1 (6/8/05) on Linux. I am assuming it works fine on Windows, but never tried.
- This was my first Plugin attempt and I learned on the fly. Parts of the Web I/F are based off the newest Shoutcast plugin and others off the older RealSlim plugin. I'm sure there are things that are not done optimally and the code isn't consistent because I did things differently early on that I found better ways for later.
- All my new strings are EN only. Any multilingual folks, please feel free to add DE, ES, and whatever.

To install:
- Unzip the attached file under the Plugins directory
- DELETE THE OLD PLUGINS/LIVE365.PM FILE!!!!

If someone else out there is a big Live365 user (or just curious) and would like to run this thing through its paces, I would appreciate it... especially Windows testers. Anyone who wants to take a pass through the code to clean it up and perhaps push this into the 6.1 baseline, please do.

Drop me a line if you have any questions, etc. If this thing looks decent, I'm going to try to tackle a serious update of the RealSlim Rhapsody plugin for 6.1 later this month.

Chris

mherger
2005-06-14, 23:15
Chris,

First of all let me say that I'm not a regular Live365 user, but I did the
web interfaces for Shoutcast & Co. And I wanted to do Live365 but did
never understand it :-).

Now what I've seen so far from your mod... this is excellent!

> - This was built and tested only on SlimServer 6.1 (6/8/05) on Linux.

Me too, I'm sorry.

> - All my new strings are EN only. Any multilingual folks, please
> feel free to add DE, ES, and whatever.

I only found two new strings. Is this ok? Please find them translated to
german in the patch.

--

Michael

-----------------------------------------------------------
Help translate SlimServer by using the
StringEditor Plugin (http://www.herger.net/slim/)

kdf
2005-06-14, 23:20
well done!

an initial tip for the web stuff. if you refer to the slimserver.css like so:
[% webroot %]slimserver.css

it will then allow the EN skin to look more like other other skins, since that
allows the skin to use its own style sheets.

-kdf

mherger
2005-06-14, 23:35
> Caveats:
> - This was built and tested only on SlimServer 6.1 (6/8/05) on Linux.
> I am assuming it works fine on Windows, but never tried.

Ok, I booted up Windows on my laptop. It's working fine. The same problems
as on Linux ;-).

I encountered parsing errors with quite a few styles (Rock - *, Easy
Listening), though I did not test a lot:

2005-06-15 08:34:10.9115 Error parsing station directory:
syntax error at line 1, column 61, byte 61 at
/home/mh/eclipse/SVN/CPAN/XML/Parser.pm line 187

As I said this is the same on Windows or Linux (Mandrake 10.1).

--

Michael

-----------------------------------------------------------
Help translate SlimServer by using the
StringEditor Plugin (http://www.herger.net/slim/)

chrisp810
2005-06-15, 09:25
I encountered parsing errors with quite a few styles (Rock - *, Easy
Listening), though I did not test a lot:

2005-06-15 08:34:10.9115 Error parsing station directory:
syntax error at line 1, column 61, byte 61 at
/home/mh/eclipse/SVN/CPAN/XML/Parser.pm line 187

As I said this is the same on Windows or Linux (Mandrake 10.1).


Nice catch, Michael! I guess I need to listen to a wider variety of stations. :)

There was a problem with URI encoding on genres that had spaces or other "special characters" in them. Required a one line fix to Live365API.pm... diff follows and also attached.

Since I'm new to this effort, what is the best way to distribute changes, patches, etc. for the future?

Thanks,
Chris

------------------ Begin Diff -------------
diff -c Live365/Live365API.pm /root/Live365/Live365API.pm
*** Live365/Live365API.pm Wed Jun 15 12:16:05 2005
--- /root/Live365/Live365API.pm Tue Jun 14 16:36:57 2005
***************
*** 92,98 ****
$errorCallback,
$callbackArgs);

! my $stringArgs = join( '&', map { "$_=" . URI::Escape::uri_escape($args->{$_}) } grep { $args->{$_} } keys %$args );
my $url = $live365_base . $path . '?' . $stringArgs;
$http->get($url);

--- 92,98 ----
$errorCallback,
$callbackArgs);

! my $stringArgs = join( '&', map { "$_=$args->{$_}" } grep { $args->{$_} } keys %$args );
my $url = $live365_base . $path . '?' . $stringArgs;
$http->get($url);

------------------ End Diff -------------

mherger
2005-06-15, 10:53
> Nice catch, Michael! I guess I need to listen to a wider variety of
> stations. :)

I did not even listen to them :-) Just clicked "Rock - Classic" first.

> Since I'm new to this effort, what is the best way to distribute
> changes, patches, etc. for the future?

Keep writing and sending good patches until someone who has the power does
accept it ;-). Or contact the original author of the plugin (should be in
the header lines).

> ------------------ Begin Diff -------------
> diff -c Live365/Live365API.pm /root/Live365/Live365API.pm

I think the standard procedure is "diff -u" and attach the result as a
file.

--

Michael

-----------------------------------------------------------
Help translate SlimServer by using the
StringEditor Plugin (http://www.herger.net/slim/)

vidurapparao
2005-06-15, 12:58
Chris,

This is great! I've committed your original submission plus the patch to
svn. They will appear in the next nightly build. I've also checked in a
few other fixes
(http://lists.slimdevices.com/archives/checkins/2005-June/005574.html).
Please feel free to submit any changes to the plugin to this list as an
svn diff.

Thanks!
--Vidur

chrisp810 wrote:

>As a Live365 junkie, I was disappointed with the state of the Live365
>plugin. I spent the last week or so rewriting large parts of the
>latest Live365 plugin that came with 6.1 (my rewrite is based off the
>6/8/05 nightly, and it doesn't appear anything has changed since then).
>I also bumped the version number to 1.20 (from 1.10).
>
>Upgrades include:
>- Now has a web interface
>- - EN and Default skins provided
>- - Supports all Live365 operations available through the SB2
>- - Auto-login like the SB2 interface does
>- - Paging of all search/browse results
>- - Extended search results in web searches for artist/track/CD (can
>be toggled on/off in Server Settings)
>- Fixed problem with all browse/search operations through SB2
>returning a max of 50 results and never fetching more
>- Fixed a few typos in parameter lists and text
>
>I tested the hell out of this thing and it seems to work perfectly with
>SB2, SoftSqueeze, and the web I/F. However...
>
>Caveats:
>- This was built and tested only on SlimServer 6.1 (6/8/05) on Linux.
>I am assuming it works fine on Windows, but never tried.
>- This was my first Plugin attempt and I learned on the fly. Parts
>of the Web I/F are based off the newest Shoutcast plugin and others off
>the older RealSlim plugin. I'm sure there are things that are not done
>optimally and the code isn't consistent because I did things
>differently early on that I found better ways for later.
>- All my new strings are EN only. Any multilingual folks, please
>feel free to add DE, ES, and whatever.
>
>To install:
>- Unzip the attached file under the Plugins directory
>- DELETE THE OLD PLUGINS/LIVE365.PM FILE!!!!
>
>If someone else out there is a big Live365 user (or just curious) and
>would like to run this thing through its paces, I would appreciate
>it... especially Windows testers. Anyone who wants to take a pass
>through the code to clean it up and perhaps push this into the 6.1
>baseline, please do.
>
>Drop me a line if you have any questions, etc. If this thing looks
>decent, I'm going to try to tackle a serious update of the RealSlim
>Rhapsody plugin for 6.1 later this month.
>
>Chris
>
>
>+-------------------------------------------------------------------+
>|Filename: Live365PluginV1.20.zip |
>|Download: http://forums.slimdevices.com/attachment.php?attachmentid=157|
>+-------------------------------------------------------------------+
>
>
>