Re: [LAU] Channel routing with RME HDSPe AES without HDSPMixer

From: Fons Adriaensen <fons@email-addr-hidden>
Date: Sat Nov 26 2016 - 19:42:11 EET

On Sat, Nov 26, 2016 at 05:42:12PM +0100, francois bluewin wrote:

> Needing to use outputs channels 7&8 with an input on 1&2 (MPD as
> music server), I am unable to setup a correct .asoundrc file in
> order to avoid using HDSPmixer (it works well with HDSPMixer but I
> would have preferred to avoid using the graphic interface).

Instead of using an .asoundrc you could program HDSPmixer from
a script, provided you can find out the channel numbers.

Below is an example of doing this on a Multiface II:

#!/bin/bash

# Multiface II mixer
#
# inputs: 0-7 (analog), 16-23 (adat), 24-25 (spdif) 26-33, 42..51 (playback channels)
# outputs: 0-7 (analog), 16-23 (adat) 24-25 (spdif), 26-27 (phones)

device=hw:DSP
gain=32768

function set_gain ()
{
    amixer -D $device cset numid=5 $1,$2,$3 > /dev/null 2>&1
}

function reset_matrix ()
{
    for out in $(seq 0 27); do
        for inp in $(seq 0 51); do
        set_gain $inp $out 0
        done
    done
}

echo Clearing matrix mixer ...

# Reset all
reset_matrix

echo Setting default connections ...

# Playback 1..8 to analog outs
set_gain 26 0 $gain
set_gain 27 1 $gain
set_gain 28 2 $gain
set_gain 29 3 $gain
set_gain 30 4 $gain
set_gain 31 5 $gain
set_gain 32 6 $gain
set_gain 33 7 $gain

# Playback 9..16 to ADAT outs
set_gain 42 16 $gain
set_gain 43 17 $gain
set_gain 44 18 $gain
set_gain 45 19 $gain
set_gain 46 20 $gain
set_gain 47 23 $gain
set_gain 48 24 $gain
set_gain 49 25 $gain

# Playback 17,18 to headphone amp
set_gain 50 26 $gain
set_gain 51 27 $gain

amixer -D$device sset 'Preferred Sync Reference' 'ADAT1'
amixer -D$device sset 'Sample Clock Source' 'AutoSync'

echo Done.

exit 0

-- 
FA
A world of exhaustive, reliable metadata would be an utopia.
It's also a pipe-dream, founded on self-delusion, nerd hubris
and hysterically inflated market opportunities. (Cory Doctorow)
_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@email-addr-hidden
http://lists.linuxaudio.org/listinfo/linux-audio-user
Received on Sat Nov 26 20:15:01 2016

This archive was generated by hypermail 2.1.8 : Sat Nov 26 2016 - 20:15:01 EET