Shop OBEX P1 Docs P2 Docs Learn Events
24bit Audio Mixer — Parallax Forums

24bit Audio Mixer

Mark_TMark_T Posts: 1,981
edited 2012-08-28 16:46 in Robotics
So I've finally started to get my digital audio mixer board to come alive! I had to write a Prop logic analyzer to help debug the I2S bus interface PASM (separate post about that perhaps).

Anyway the mixer board hosts 4 stereo 24bit ADC's (WM8782's), 2 stereo 24bit DACs (WM8524's) and a 24bit stereo DAC/headphone amp (WM8759). The I2S bus clocking is all generated from a 12.288MHz Xtal oscillator and 74HC393 ripple-counter. 74HC244 distributes the 3 clocks across the board (wasn't sure how heavily 8 chips would load them).

A fourth clock of 6.144MHz is fed to Xin (This is 48kHz audio sample rate * 2^7) to give a Prop system (over)clock of 98.304MHz. This allows synchronous input/output of the I2S seral bit streams (at 3.072MHz, 8 instructions per bit).

Other features are:
* a couple of CAT5 sockets and 3 RS485 driver chips to allow remote control/monitoring and raw digital audio bit stream output.
* serial interface to control separate preamp board(s) with selectable-gain via LTC6912-2 opamp.
* 4 regulators to provide 5V and 3V3 for both analog and digital zones.
* 5V analog / digital supplies cross-connected with parallel diodes so the whole board can be powered from a Sparkfun FTDI cable for testing.
* Loads of tantalum decoupling caps!

mixer-board.jpg
mixer-sch.png


The I2S output driver is relatively simple, but the input driver for the WM8782 fits in signal processing in the gaps between "test mask, INA wc ; rcl input, #1" instructions used to read the serial input. 6 out of each 8 instructions are available to do volume, pan and bass/treble computation. The bass/treble implementation is a digital state-variable-filter which is extremely efficient on the Prop. And since the data is 24 bits in 32 bit periods there are a further 64 instructions available per sample to cram in more calculation (unrolled multiplies mainly).

Lots of further work in tying the drivers together and designing a protocol for remote operation and monitoring. I fear I may run out of cogs - 4 for the inputs, 1 for the outputs, 1 to combine input data (actual mixing!), 1 to handle RS485 driver, 1 top level, and the one's I've forgotten!

If you haven't met the Wolfson Microelectronics audio DACs/ADCs they are delightfully cheap and highly speced, love being surrounded by an entourage of capacitors and (frustratingly) usually TSSOP packaged. Just been listening to a straight-through test of the board on headphones, no discernable noise at full volume, audio quality indistinguishable from perfect to my ears.
874 x 734 - 206K
993 x 912 - 246K

Comments

  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2012-08-08 10:15
    Mark,

    Congrats! That looks like a really nice piece of work! Just out of curiosity, what unique features of the Propeller stood out as enablers for this project?

    Thanks,
    -Phil
  • Mark_TMark_T Posts: 1,981
    edited 2012-08-08 10:21
    Mark,

    Congrats! That looks like a really nice piece of work! Just out of curiosity, what unique features of the Propeller stood out as enablers for this project?

    Thanks,
    -Phil

    Definitely the deterministic timing and parallelism. I could have used the Prop to generate all the clocks too, the 393 ripple counter isn't strictly needed, just convenient. Plenty of pins left over (in fact adding VGA support would have been OK, but wouldn't have enough cogs really - pins 16 to 23 are free.
  • Mark_TMark_T Posts: 1,981
    edited 2012-08-28 16:46
    Well I've been working on the remote sending side of the project recently. 320x240 lcd graphics plus a Playstation controller as UI. Commands currently sent as DMX512 compatible signals down CAT5. Here's the virtual mixing desk graphic - it scrolls as needed by navigation (left analog stick and buttons) and knobs rotate according to right analog button (up-down gives fast rotation, left-right gives slow rotation.
    virtual-mix.jpg


    Currently 4 mixer channels are populated, 2 are being tested (left 2 columns of knobs). Space for total of 8 channels on the board. Preamplifiers available to connect but line-level for now for testing.
    387 x 468 - 55K
Sign In or Register to comment.