/elec/audio-switcher

To get this branch, use:
bzr branch http://bzr.ed.am/elec/audio-switcher

« back to all changes in this revision

Viewing changes to README

  • Committer: Tim Marston
  • Date: 2012-11-27 00:57:29 UTC
  • Revision ID: tim@ed.am-20121127005729-nzb9lxv0lae969vd
cleaned up project

Show diffs side-by-side

added added

removed removed

1
1
ABOUT
2
 
=====
3
2
 
4
3
This is a project to provide automated control over a relay that switches
5
 
audio.  The idea being that you can automatically route line-out audio from the
6
 
computer to different locations/amps.
 
4
audio.
7
5
 
8
 
Schematics for the audio switching unit can be found in the project directory.
 
6
Scematics for the audio switching unit can be found in the project directory.
9
7
In summary, a relay is controlled to switch stereo input audio between two
10
8
outputs.  Also, one of the outputs can be overridden by plugging in some
11
 
headphones.
 
9
heaphones.
12
10
 
13
 
The software below is for a MinimusUSB and will turn it in to a USB serial
 
11
The software below is for a MinimusUSB and will turn it in to a USB serisl
14
12
device with a unique vendor and product id.  It is based on LUFA.
15
13
 
16
14
 
17
 
BUILDING THE PROJECT
18
 
====================
19
 
 
20
 
Lufa Setup
21
 
----------
 
15
LUFA SETUP
22
16
 
23
17
Download the LUFA project and unpack it in to the root directory of this
24
18
project.  Then, either rename the LUFA directory to "LUFA", or just symlink to
25
19
it (which will allow you to have several versions of the library, should you
26
 
want to).  For example,
 
20
want to).
27
21
 
28
22
  $ wget http://lufa-lib.googlecode.com/files/LUFA-120730.zip
29
23
  $ unzip LUFA-120730.zip
30
24
  $ ln -s LUFA-120730 LUFA
31
25
 
32
26
 
33
 
Building and uploading
34
 
----------------------
 
27
BUILDING THE PROJECT
35
28
 
36
29
Having unpacked LUFA, build the audio-switcher software.
37
30
 
42
35
down button B, press reset).  You can confirm it is ready with `lsusb`, which
43
36
should list the following device present:
44
37
 
45
 
  ID 03eb:2ffa Atmel Corp.
 
38
  xxxxxxxxxxxxxxx
46
39
 
47
40
Now upload the audio switcher software.
48
41
 
49
42
  $ make dfu
50
43
 
51
44
Finally, reset the MinimusUSB.  You can confirm that the software is working
52
 
with `lsusb`, which should show the following device present (note the product
53
 
id is different):
54
 
 
55
 
  ID 03eb:ba7f Atmel Corp.
56
 
 
57
 
 
58
 
CONTROL
59
 
=======
60
 
 
61
 
The audio switcher is a serial device.  To turn the audio switcher on and off,
62
 
you can connect to the serial device and send commands (followed by a newline).
63
 
The following commands are supported:
64
 
 
65
 
  0  - turn relay off
66
 
  1  - turn relay on
67
 
  ?  - query state of relay (returns a 0 or 1)
68
 
  .      - toggle relay
69
 
 
70
 
You can also use the `audio-switch` shell script included in this project,
71
 
which finds the correct serial device to talk to and has a nice command-line
72
 
interface.
 
45
with `lsusb`, which should show the following device present:
 
46
 
 
47
  xxxxxxxxxxxxxxxx
73
48
 
74
49
 
75
50
REFERENCE
76
 
=========
77
51
 
78
52
You can find out more about the excellent LUFA project here:
79
53