PDA

View Full Version : Slimp3slave



Lawrence Bricknell
2003-12-16, 00:28
Has anyone written a Windows based "virtual SLIMP3" ?

Rgds

Lawrence Bricknell

------------
I mentioned on the developers list an intention to implement the audio
part of a SLIMP3 client. I've now done so:

http://www.ex-parrot.com/~pdw/slimp3slave/

It's a command-line linux program. You type:

slimp3slave -s my_server_name

and you'll see a new client on your server that plays sound through the
computer that you ran slimp3slave on. It's similar to running:

mpg123 http://my_server_name:9000/stream.mp3

but it's more responsive.

Enjoy,

Paul

kdf
2003-12-16, 00:53
Quoting Lawrence Bricknell <lawrence (AT) avitech (DOT) co.za>:

> Has anyone written a Windows based "virtual SLIMP3" ?
>
> Rgds
>
Its possible the current release will work from a windows command line if
compiled with a windows compiler, or maybe with a little bit of porting. Anyone
got a dev platform on which to try it?

-kdf

mherger
2003-12-16, 06:35
Do you know about a mp3 player for windows which accepts stdin? I found
some mpg123 for dos but did not get a single beep so far. Did not spend
much time, though.

Compiling slimp3slave with cygwin spit out the following lines (and I have
no idea about C programming...):

$ make
gcc -g -Wall -c -o slimp3slave.o slimp3slave.c
slimp3slave.c: In function `receive_mpeg_data':
slimp3slave.c:265: warning: unused variable `addr'
slimp3slave.c: In function `read_packet':
slimp3slave.c:295: warning: unused variable `ina'
slimp3slave.c:296: warning: unused variable `slen'
gcc -g -Wall -c -o util.o util.c
gcc -g -o slimp3slave slimp3slave.o util.o

>> Has anyone written a Windows based "virtual SLIMP3" ?
>>
>> Rgds
>>
> Its possible the current release will work from a windows command line if
> compiled with a windows compiler, or maybe with a little bit of porting.
> Anyone
> got a dev platform on which to try it?

--

Michael

-----------------------------------------------------------
http://www.jo-sac.ch/lindenberg - die JO des SAC Lindenberg
http://www.jo-sac.ch - JO-SAC inoffiziell!
http://photo.jo-sac.ch - mein kleines Photoalbum

mherger
2003-12-16, 06:52
Some more information:

Run slimserver (yesterday's build) using perl 5.8 (ActiveState and
Cygwin), but it does not recognize slimp3slave:

$ ./slimp3slave -v -s mymachine
=> sending discovery request
Use of uninitialized value in send at c:/Perl/lib/IO/Socket.pm line 218.
<= short packet

Same error message when run using cygwin's perl.

> Do you know about a mp3 player for windows which accepts stdin? I found
> some mpg123 for dos but did not get a single beep so far. Did not spend
> much time, though.
>
> Compiling slimp3slave with cygwin spit out the following lines (and I
> have no idea about C programming...):
>
> $ make
> gcc -g -Wall -c -o slimp3slave.o slimp3slave.c
> slimp3slave.c: In function `receive_mpeg_data':
> slimp3slave.c:265: warning: unused variable `addr'
> slimp3slave.c: In function `read_packet':
> slimp3slave.c:295: warning: unused variable `ina'
> slimp3slave.c:296: warning: unused variable `slen'
> gcc -g -Wall -c -o util.o util.c
> gcc -g -o slimp3slave slimp3slave.o util.o
>
>>> Has anyone written a Windows based "virtual SLIMP3" ?
>>>
>>> Rgds
>>>
>> Its possible the current release will work from a windows command line
>> if
>> compiled with a windows compiler, or maybe with a little bit of
>> porting. Anyone
>> got a dev platform on which to try it?
>



--

Michael

-----------------------------------------------------------
http://www.jo-sac.ch/lindenberg - die JO des SAC Lindenberg
http://www.jo-sac.ch - JO-SAC inoffiziell!
http://photo.jo-sac.ch - mein kleines Photoalbum

Paul Warren
2003-12-16, 06:58
On Tue, Dec 16, 2003 at 02:52:34PM +0100, Michael Herger wrote:
> Some more information:
>
> Run slimserver (yesterday's build) using perl 5.8 (ActiveState and
> Cygwin), but it does not recognize slimp3slave:
>
> $ ./slimp3slave -v -s mymachine
> => sending discovery request
> Use of uninitialized value in send at c:/Perl/lib/IO/Socket.pm line 218.
> <= short packet
>
> Same error message when run using cygwin's perl.

Are you using 0.3? There were bugs in 0.1 and 0.2 that caused exactly
those errors when run with 5.x servers.

Paul

Paul Warren
2003-12-16, 07:09
On Tue, Dec 16, 2003 at 02:35:47PM +0100, Michael Herger wrote:
> Do you know about a mp3 player for windows which accepts stdin? I found
> some mpg123 for dos but did not get a single beep so far. Did not spend
> much time, though.

I'm not aware of any, and I doubt that any of the UNIX ones will do,
because the code that writes to the sound driver will be platform
specific.

> Compiling slimp3slave with cygwin spit out the following lines (and I have
> no idea about C programming...):
>
> $ make
> gcc -g -Wall -c -o slimp3slave.o slimp3slave.c
> slimp3slave.c: In function `receive_mpeg_data':
> slimp3slave.c:265: warning: unused variable `addr'
> slimp3slave.c: In function `read_packet':
> slimp3slave.c:295: warning: unused variable `ina'
> slimp3slave.c:296: warning: unused variable `slen'
> gcc -g -Wall -c -o util.o util.c
> gcc -g -o slimp3slave slimp3slave.o util.o

That looks fine - I must fix those warnings.

Paul

mherger
2003-12-16, 07:28
> Are you using 0.3?

Of course I do, NOT! :-) too stupid to refresh my browsers window.

> There were bugs in 0.1 and 0.2 that caused exactly
> those errors when run with 5.x servers.

Ok, downloaded latest version, compiles with same messages. Running it...
and voilą:

$ ./slimp3slave -v -s localhost
=> sending discovery request
<= discovery response
<= LCD data
<= LCD data
<= i2c data
[.. many mor of them...]
<= mpeg data
Address: 0 Control: 3 Seq: 1
=> sending ack for 1
<= mpeg data
Address: 0 Control: 3 Seq: 1
=> sending ack for 1
<= mpeg data
Address: 700 Control: 3 Seq: 2
=> sending ack for 2
<= mpeg data
Address: 1400 Control: 3 Seq: 3
=> sending ack for 3
<= mpeg data
Address: 2100 Control: 3 Seq: 4
=> sending ack for 4
<= LCD data
[... ok, even more of it...]
Address: 32200 Control: 0 Seq: 47
=> sending ack for 47
mpg123: not found
Broken pipe

Little surprise: there's no mpg123. But so far it does look ok. I think it
only crashed when I actually started the non existing player.

--

Michael

-----------------------------------------------------------
http://www.jo-sac.ch/lindenberg - die JO des SAC Lindenberg
http://www.jo-sac.ch - JO-SAC inoffiziell!
http://photo.jo-sac.ch - mein kleines Photoalbum

mherger
2003-12-16, 07:29
On Tue, 16 Dec 2003 14:09:56 +0000, Paul Warren <pdw (AT) ex-parrot (DOT) com> wrote:

> On Tue, Dec 16, 2003 at 02:35:47PM +0100, Michael Herger wrote:
>> Do you know about a mp3 player for windows which accepts stdin? I found
>> some mpg123 for dos but did not get a single beep so far. Did not spend
>> much time, though.
>
> I'm not aware of any, and I doubt that any of the UNIX ones will do,
> because the code that writes to the sound driver will be platform
> specific.

I think those I've found only work with some SB16 compatible cards. Maybe
I'll give it another try a little later.

--

Michael

-----------------------------------------------------------
http://www.jo-sac.ch/lindenberg - die JO des SAC Lindenberg
http://www.jo-sac.ch - JO-SAC inoffiziell!
http://photo.jo-sac.ch - mein kleines Photoalbum

Paul Warren
2003-12-16, 07:35
On Tue, Dec 16, 2003 at 03:29:29PM +0100, Michael Herger wrote:
> On Tue, 16 Dec 2003 14:09:56 +0000, Paul Warren <pdw (AT) ex-parrot (DOT) com> wrote:
>
> > On Tue, Dec 16, 2003 at 02:35:47PM +0100, Michael Herger wrote:
> >> Do you know about a mp3 player for windows which accepts stdin? I found
> >> some mpg123 for dos but did not get a single beep so far. Did not spend
> >> much time, though.
> >
> > I'm not aware of any, and I doubt that any of the UNIX ones will do,
> > because the code that writes to the sound driver will be platform
> > specific.
>
> I think those I've found only work with some SB16 compatible cards. Maybe
> I'll give it another try a little later.

Some minimal googling suggested that esound might work under cygwin, in
which case madplay has support for esound.

Paul

Robert J. Wygand, III, Esq., D. D.
2003-12-17, 02:16
I compiled, but did not attempt to run it, under windows using cygwin.
Just typed make, and it compiled and linked flawlessly.

rjw

kdf wrote:
> Quoting Lawrence Bricknell <lawrence (AT) avitech (DOT) co.za>:
>
>
>>Has anyone written a Windows based "virtual SLIMP3" ?
>>
>>Rgds
>>
>
> Its possible the current release will work from a windows command line if
> compiled with a windows compiler, or maybe with a little bit of porting. Anyone
> got a dev platform on which to try it?
>
> -kdf
>
>
>