I2S switch with SN74HC157N

I am considering changing logic, but this is about how I have it now (a bit simplyfied drawn here though).
Relay_1: RIAA
Relay_2: AUX
Relay_3: Analog from DAC
i2s: Chose i2s-input
Relay_4: Relay to control an external board for CD/DVD.

As I had 5VDC anyway for other things and to make use it does not draw to much power I made it like this. Raspberry is only one of the i2s-sources I have. I could use the 3.3v from Raspberry but then it needs to be powered on even if i listen to CD.

I am not sure I thinking correctly now, but maybe it would be easier if I used negative logic all over instead?

View attachment 1082629
You use the rotary switch to drive relays and multiplexer select inputs (or three-state buffer output enable inputs), if I understand it correctly. Don't forget to put freewheeling diodes across the relays, otherwise the relay coil current will temporarily be drawn out of a digital input when you switch to another input.
 
  • Like
Reactions: Blossa and nicoch58