how much data can be transferred over an audio cable?

i'm wondering how much I can do with one audio cable connection.

what i would ideally like to transmit is:
has a connection been made with the jack? (possibly one digital input on arduino)
one potentiometer going through this same jack (analog in)
and if possible another potentiometer if I use TRRS jacks, but not going to get my hopes up.

mrtunes:
i'm wondering how much I can do with one audio cable connection.

what i would ideally like to transmit is:
has a connection been made with the jack? (possibly one digital input on arduino)
one potentiometer going through this same jack (analog in)
and if possible another potentiometer if I use TRRS jacks, but not going to get my hopes up.

Are you afraid to try? If so, can't help.

Are you asking if you can use different wires in an Audio cable for different purposes?

The answer is almost certainly YES. But you need to tell us what sort of audio cable you are using.

It is also possible to use an audio cable to send serial data between two Arduinos over a short distance - that would just require 3 wires - Tx, Rx and GND.

...R

has a connection been made with the jack? (possibly one digital input on arduino)
one potentiometer going through this same jack (analog in)
and if possible another potentiometer if I use TRRS jacks, but not going to get my hopes up.

That's three things... A TRRS connector/cable has 4 connections. With one connection-conductor used for ground, you have 3 left so that should work fine.

has a connection been made with the jack?

You could use a pull-up resistor at the Arduino input, then pull down to ground when connected.

ok thanks everyone, i have been able to get started here.

i have plugged in a mono female jack into the arduino, and ran the digital input pullup example sketch which detects input on pin 2. when i plug the male jack in, the serial port shows a 0 and a 1 when the jack is not plugged in. great.

now let's say i have a few different possible jacks on the other side of this, how would the arduino know which jacks are connected?

mrtunes:
ok thanks everyone, i have been able to get started here.

i have plugged in a mono female jack into the arduino, and ran the digital input pullup example sketch which detects input on pin 2. when i plug the male jack in, the serial port shows a 0 and a 1 when the jack is not plugged in. great.

now let's say i have a few different possible jacks on the other side of this, how would the arduino know which jacks are connected?

Get a stereo switching jack (like the headphone socket on your computer). That will give you 3 inputs and let you know when the plug is in. It works in exactly the same way as your computer disconnects the speakers when the headphones are plugged in.

This sounds like an XY problem.

...R