How much software and/or networking knowledge do you have?
If it were me, I would make RPi 2 the "server" and RPi 1 the "client" (since RPi 2 is remote). I'd write a little C program to open up a TCP/IP port on RPi 2, listen for commands, and take the appropriate actions with the relays. I'd write another little C program to connect to said port from RPi 1 and issue commands based on the switches. They would be able to freely communicate with each other using whatever handshaking or command structure you want over the TCP/IP socket.
Since RPi 2 will be remote, you can use one of the RPis to autonomously open an SSH tunnel to the other one to allow the TCP/IP connection through an encrypted and protected SSH tunnel. Unless you can give a static public IP to one of the RPis, you'll likely still need to set up port forwarding in the router on one of the ends, and possibly set up a Dyn DNS domain so you don't have to worry about DHCP updates from the ISP.
As for the audio, I don't know the details of these sound cards, but I'm sure there'd be a way to get them to pass data to each other through either the same or a separate TCP/IP socket or SSH tunnel as above.
Last edited by suicidaleggroll; 01-31-2017 at 05:45 PM.
|