Page 1 of 2 12 LastLast
Results 1 to 15 of 18

Thread: Wireless jukebox

  1. #1

    Wireless jukebox

    Looking at the waveserver and such stuff, and seeing how my router sits right next to my old stereo whose CD player died a while ago, I thought it would be neat to try and use my trusty wl500g as a jukebox.

    I'm not using an MS products, so the waveserver seems useless (given the lack of documentation). Also I'm not convinced I want to store my music on some remote computer. My wl500g is the only computer that's always ON, so it makes sense to keep as much stuff there as possible.

    In the end I decided it would be good to try and install musicpd.
    So I bought a cheap USB audio dongle (about CDN$30).
    It's connected to a hub where I also connect my printer and a flash storage (for my experiments: if it works well, I'll get an external harddrive instead).

    There's an ipkg for musicpd, so I tried to install it with ipkg.sh, but it didn't work (ipkg.sh issued various warnings/error messages along the way, especially about incorrect parameters passed to `sed', but in the end things seemed pretty much installed at the right place): the package needed a libgcc_s.so (or something like that: I don't have the exact message at hand) which is probably distributed with OpenWrt but not with Oleg's firmware.

    So I compiled it by hand. I still had the cross-compiler I used to compile my NTP server, so I decided to try and use that one (dates back to 1.7.X.X days).

    I started by compiling the following packages:
    - libao-0.8.6
    - zlib-1.2.3
    - libogg-1.1.3
    - libvorbis-1.1.2
    - mpd-0.11.5
    (most of my songs are in Vorbis format so I needed that)
    All of those libs have been statically linked into the resulting `mpd' executable (about 700KB).

    When I installed it, it didn't work. Several problems:
    - libao's oss driver is a dynamically loaded plugin but the build procedure relies on libtool for that and for some reason this didn't work (maybe I'd need a cross-compiler version of libtool). So I hacked the source to statically link the oss "plugin".
    - the default mpd.conf used /dev/mixer rather than /dev/sound/mixer. Also it used the "PCM" rather than "Pcm" volume control, so the volume control didn't work.
    - my card only takes 48khz streams, so I had to add a line in mpd.conf.
    - I hadn't plugged my cables correctly (yup, that's right, I'm an idiot).
    - the poor BCM4710 was not up to decoding Vorbis (MP3 is OK with about 65% CPU).

    Luckily I bumped into Tremor, so I installed it from http://svn.xiph.org/branches/lowmem-branch/Tremor.
    Then mpd needed a patch to use the Tremor library. Luckily someone else wrote this one already: http://reich.sdf-eu.org/hannes/code/...morSupport-1.0.

    With the Tremor library, the resulting executable is slightly smaller, but most importantly it plays Vorbis OK (with about 50% CPU).

    Now the resulting sound quality is not that great, tho. Also I don't know yet how well the poor BCM4710 will handle the load when there's some actual network activity at the same time. So I'm not yet sure whether I'll get the external drive to place my music on it.

    Still, print/ntp/dns/http/mpd serving with such a little box is quite respectable (oh and it does the routing and the wireless too).

    BTW, this is all with Oleg's firmware and without using the flash disk as root partition nor as swap. It seems I still have some memory free (I killed lpd, waveserver, rcamd, p9101d, and telnetd (BTW: why isn't there a /var/run/telnetd.pid and neither is there one for waveserver (as opposed to waveservermain)?)). Would it be worth it for me to use a swap partition on my flash drive? And/or to use my flash drive as root partition?

  2. #2
    hello,

    please post your binaries here!
    what usb sound card are you using? (what do you get in dmesg?)
    is the sound FM quality... at least?

    regards,
    [ WL-500G | fw: 1.9.2.7-7f ]

  3. #3
    I'm still not sure what's up with the sound quality. For some parts it's just fine, but for others it sounds like 64kb/s MP3 even with 192kb/s Vorbis (typically for high-pitched parts, which tend to be distorted to sound "metalic"). I'm still not sure if the problem is with my Vorbis files or with the wl500g hard/software or with the USB audio dongle. I don't know much about those things.

    The USB dongle is a no-name kind of thing by "SoundMax Technology Co, Ltd". The closest thing to a product name I can find is "SD-102". It looks identical to the one at http://users.tpg.com.au/davico/image...oundcard_2.jpg (found at http://wiki.openwrt.org/UsbAudioHowto). The dmesg output doesn't say much:

    hub.c: new USB device 00:04.0-1.4, assigned address 5
    usb.c: USB device 5 (vend/prod 0xd8c/0x1) is not claimed by any active driver.
    usb.c: registered new driver audio
    usbaudio: device 5 audiocontrol interface 0 has 0 input and 1 output AudioStreaming interfaces
    usbaudio: device 5 interface 1 altsetting 0 does not have an endpoint
    usbaudio: device 5 interface 1 altsetting 1 channels 2 framesize 2 configured
    usbaudio: valid output sample rate 48000
    usbaudio: device 5 interface 1 altsetting 1: format 0x01000010 sratelo 48000 sratehi 48000 attributes 0x00
    usbaudio: registered dsp 14,3
    usbaudio: constructing mixer for Terminal 3 type 0x0301
    usbaudio: registered mixer 14,0
    usb_audio_parsecontrol: usb_audio_state at 80b0b660
    audio.c: v1.0.0:USB Audio Class driver
    usbaudio: set_format_out(): failed to find desired format/speed combination.
    usbaudio: set_format_out(): failed to find desired format/speed combination.
    usbaudio: set_format_out(): failed to find desired format/speed combination.
    usbaudio: set_format_out(): failed to find desired format/speed combination.

    As for patches, build instructions, and binaries, I'll put them up on the Wiki.

  4. #4
    Join Date
    Aug 2004
    Location
    Germany
    Posts
    377
    Hi

    Since your soundcard only accepts 48khz samples, maybe the resampling which hase to take place somewhere on the path is causeing the scrambled audio ?
    Cheap USB soundcards are not bad, but it seems luck to grab one with a good Chipset like i got (9$, Audio in and Out, multiple sampling rates).

    Im interrested in your effords to make a nice music box out of wl500 devices

    Greets
    Wlanman
    My Stuff: WL-500g, Mapower H31x 10GB HD, Philips Webcam Vesta PRO, TerraTec Webcam PRO, USB Hub

  5. #5
    Duh! Yes, it seems like the resampling is the culprit (I haven't had a chance to check it for real yet, but it does explain the behavior very well, and googling around gives me the impression that it may indeed be the case that the resampling used by musicpd isn't the best).

    I'd rather not re-encode my sound files, tho, especially since I don't have the source wav any more so I'd lose quality.

    Where did you find your USB sound dongle?

    Most importantly how can one figure out (before buying, that is) what kind of chipset/features a cheap USB soundcard offers (all the info I typically get is crap like "works with WMP, with super duper sound quality and you can even virtually move the loudspeakers from your PC").

  6. #6
    Join Date
    Aug 2004
    Location
    Germany
    Posts
    377
    Hi

    You have to google for the adapter brand name / product code and some linux related words, you may find discusions where the inbuild chip is mentioned, with that you can look quite direkt for toppings talking about the compatibility.

    My dongle hast a C-Media Chip which seems well supported under Linux.
    It is not these, but a very simmilar one. Ebay
    Dont wonder about fance 3D and 5.1 features ... they are all softwareemulated and a stereo downmix, so its natively one micro input and a stereo output.

    Greets
    Wlanman
    My Stuff: WL-500g, Mapower H31x 10GB HD, Philips Webcam Vesta PRO, TerraTec Webcam PRO, USB Hub

  7. #7
    Join Date
    Aug 2004
    Location
    Germany
    Posts
    377
    Hi Monnier

    Do you release any sources/binary/prebuild-firmware ??
    I would be happy haveing mpd on wl500g, also i can try out your resampling issue.

    Greets
    Wlanman
    My Stuff: WL-500g, Mapower H31x 10GB HD, Philips Webcam Vesta PRO, TerraTec Webcam PRO, USB Hub

  8. #8
    Quote Originally Posted by WlanMan
    You have to google for the adapter brand name / product code and some linux related words, you may find discusions where the inbuild chip is mentioned, with that you can look quite direkt for toppings talking about the compatibility.

    My dongle hast a C-Media Chip which seems well supported under Linux.
    It is not these, but a very simmilar one. Ebay
    Thanks. Still, regarding your example: all the brand/product info I got on the eBay page is basically "adapter A07" and if I google for it I can only find a backref to eBay or refs to discussions about revision A07 of some BIOS. How do you know it's comparable?

    As for building MPD, I've added links on the wiki to my home page [http://www.iro.umontreal.ca/~~monnier/wl500g/] where I give building instructions (as well as precompiled binaries).

  9. #9
    Hello Monnier,
    Is it normal that mpd starts more then once when I start the mpd program on the asus ?
    When I run top, I see that mpd is started 3 times.
    I also notice that when playing mp3 music with a bitrate at 192 kbps that I hear randomly interruptions of the music.


    Regards,
    Edwin

  10. #10
    Quote Originally Posted by dwienie
    Is it normal th[at mpd starts more then once when I start the mpd program on the asus ?
    When I run top, I see that mpd is started 3 times.
    I don't know if it's normal, but I also see that, yes.

    Quote Originally Posted by dwienie
    I also notice that when playing mp3 music with a bitrate at 192 kbps that I hear randomly interruptions of the music.
    I haven't seen such interruptions, while playing MP3 at 160Kb/s or Ogg at 192Kb/s, except one of the times that I was doing a lot of NFS transfers from the WL500g. Do you hear it even when there's no other significant activity? Playing such files is very demanding for our poor little processor (easily takes around 50% CPU or more), so it can't do much more at the same time.

    Have you tried to play with the audio_buffer_size and buffer_before_play settings?

  11. #11
    Thank you Monnier for the quick response. I will try to play with
    the buffer settings to see if I can get better performance.
    The buffer_before_play setting was disabled. It is now 25%.

    Dwienie

  12. #12
    How do you install this? So far I was only using the ipkg system, but as I haven't found mpd in the package lists, I downloaded mpd-0.12 from your website to /opt/bin/. If I try to launch it, I get this error:
    Code:
    $ mpd-0.12
    /bin/sh: mpd-0.12: Permission denied

  13. #13
    Well, that was stupid. I forgot to 'chmod a+x mpd-0.12'.

  14. #14
    If you are looking for an adapter that does 44.1 and 48 kHz as well: The SpeedLink SL-8850 works good here.

  15. #15
    Join Date
    Aug 2006
    Location
    The Hague / The Netherlands
    Posts
    6

    "Jerky" mp4 / aac playback

    I'm using mpd (music player daemon) to playback mp3 and mp4 (aac encoded with iTunes) music files. The mp3s play without problems.
    However, the mp4s play very, very jerky (jerky as cannot-listen-to-em-like-that-jerky..). I've put an sample of how it sounds like over here: http://www.martijnthe.nl/jerkympd.mp3

    Does somebody have a clue what is going on here?

    Thanks!

Page 1 of 2 12 LastLast

Similar Threads

  1. Replies: 6
    Last Post: 09-08-2008, 07:33
  2. WL-HDD in client mode (wireless)
    By umbertoB67 in forum WL-HDD Q&A
    Replies: 15
    Last Post: 13-08-2006, 17:17
  3. Replies: 5
    Last Post: 09-06-2006, 15:25
  4. Atheros AR5005g Wireless Network Adapter
    By chopin in forum WL-500g Q&A
    Replies: 1
    Last Post: 08-02-2006, 18:59
  5. Wireless connection unstabīlity
    By likeapear in forum WL-500g Q&A
    Replies: 0
    Last Post: 14-12-2005, 09:30

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •