Audio System

From Whitespace (Hackerspace Gent)
Revision as of 15:27, 7 November 2010 by Bert (Talk | contribs)

Jump to: navigation, search


Audio System
WhitespaceLogo.gif
What:
Creating a network controlled integrated music system for the entire space.
Participants:
Koen
Locations:
Whitespace
Events:
Audio system hacking
Cornify


Current Configuration

  • Two channel amplifier placed in the rack
  • Stereo also placed in rack connected to TUNER input
  • Extra analog audio line from main room to amplifier connected (CD input)
  • PC connected to VIDEO/AUX input, see Software section below for more info
  • Small stereo used as rear amplifier (at the moment only one speaker connected to it)

Usage

  • Playing files/web-streams:
    • Power-up the main amplifier
      • Make sure at least one zone is selected (A = Front room / B = Back room)
      • Make sure the volume isn't all the way turned down (or up ;-))
      • Select VIDEO/AUX
    • Boot the Audio server
    • Use any MPD client you like to connect to 172.22.32.42:6600
  • Playing audio from another laptop/music player
    • Power-up the main amplifier
      • Make sure at least one zone is selected (A = Front room / B = Back room)
      • Make sure the volume isn't all the way turned down (or up ;-))
      • Select CD
    • Connect audio source to analog line in the main room and turn it on
  • Playing plain old FM radio
    • Power-up the main amplifier
      • Make sure at least one zone is selected (A = Front room / B = Back room)
      • Make sure the volume isn't all the way turned down (or up ;-))
      • Select TUNER
    • Power-up the stereo and use it as before
    • note volume is controlled by amplifier

Ideas:

  • Fixed amp sound level at max we'll allow
  • Volume controlled with software
  • Software: The silent guy, MPD, Play Airwolf at due time --> combined using Jack (some people suggest pulseaudio can also be used for this purpose)
  • FM? Transmitter of receiver?
  • Make all use cases configurable via the network, proposed solutions:
    • Hack the main amplifier
    • Hack the main amplifiers remote
    • Do a full software solution
      • connect extra audio line to the PC's line-in
      • use a analog capture card to get FM input, and make these streams configurable by MPD (The Medion used as table-PC seems to have a capture card)

Hardware:

What we have available

  • A two channel amplifier. (Bert)
  • Two big speakers (Bert)
  • An average sized stereo (Kurt)
  • A small stereo (Impy)
  • A desktop with surround sound-card (Tom)
  • Jack to cinch cables
  • Cinch to cinch cables

Thanks to all who have contributed hardware!

What we need

  • Speaker cable

Todo

  • Hang all speakers
  • Connect all speakers to there amplifiers (Only one left todo, rear left)
  • Rack mount the amplifier
  • Connect the amplifiers to the PC
  • Give the Audio System a fixed IP

Optional

  • Figure out what the s-control port does on the main amplifier.
  • Make the amplifier for the aft speakers powered only when music is played in that room.

Software:

MPD

MPD or Music player Deamon. Installed from repositories. Currently using Alsa as a sound backend. Needs to be coupled through Jack in order to make sound blend with sound from other sources.

Clients

There are a wide range of MPD clients available for a wide range of platforms. Feel free to add you experiences here:

Cross-platform
Linux
  • Ario
  • Sonata
  • MPC (CLI) usage mpc --host=audio --port=6600 (play/stop/toggle/pause/next/prev/volume +xx/-xx/xx
Mac OS X
iPhone
Android

MPDroid from the market place works like a charm, source code also available: https://github.com/TrevorBender/mpdroid

Optional

Ampache: A web interface to stream one's media library and control an MPD server. The debian install package seems to have a bug so it is necessary to create an extra symlink before configuration can begin. This web interface is available at http://audio/ampache. Try it using user root and password ****** (the one we often use)

Ampache requires a MySQL database. It was installed from repositories with as root password the one we use too often. The ampache user in the MySQL db is ampache, the password is """"

I'm not really happy with this interface... comments/alternatives???

Silent Guy

Playing Airwolf

The Airwolf theme should be played on midnight thursday and friday. The file will come straight from YouTube, so we are not storing copyrighted information on our server. play airwolf from command line straight from youtube ignoring video:

vlc -I dummy --vout null  http://www.youtube.com/watch?v=nr_CJL1YQRc

with additions for running in crontab

DISPLAY=:0.0 /usr/bin/vlc -I dummy --play-and-exit --vout null  http://www.youtube.com/watch?v=nr_CJL1YQRc

full crontab line for now (still running more frequent to allow testing):

*/2 * * * * DISPLAY=:0.0 /usr/bin/vlc -I dummy --play-and-exit --vout null  http://www.youtube.com/watch?v=nr_CJL1YQRc

now running in the sudo crontab (no need for user to be logged in) (not there yet)

*/2 * * * * exec whitespace DISPLAY=:0.0 /usr/bin/vlc -I dummy --play-and-exit --vout null  http://www.youtube.com/watch?v=nr_CJL1YQRc

*/2 * * * * exec whitespace env DISPLAY=:0.0 /usr/bin/vlc-wrapper -I dummy --play-and-exit --vout null  http://www.youtube.com/watch?v=nr_CJL1YQRc


finaly there use this line in /etc/crontab do NOT use sudo crontab -e I thought this had the same effect but it doesn't.

*/2 *   * * *   whitespace DISPLAY=:0.0 /usr/bin/vlc -I dummy --play-and-exit --vout null  http://www.youtube.com/watch?v=nr_CJL1YQRc 
Doctor Who
http://www.youtube.com/watch?v=2CYDgezeQas (recent)
http://www.youtube.com/watch?v=L0TEmJEjUSY (80's)

Jack

We will try to use Jack to make smooth combination of thes audio sources. Jack was installed from the repositories. It's currently working however audio quality is horrobly and now unusalble. Does anybody have some experience configuring Jack?