[OT] Analog sensor on soundcard input ?
Hello,
Is it possible to easily adapt a soundcard's microphone input to receive an analog sensor's output ?
I suppose it is possible to use the +48 V phantom power to provide the +5 V needed by the sensor. However, what about the voltage range at the sensor output and the impedance of the input ?
I know there might be an issue with some cards filtering the very low frequencies and DC too but I have heard there's no such issue with MOTU soundcards (I have a Traveler Mk I). Is it true ?
So, anyone has the schematics for a possible adapter circuit ?
Thank you in advance.
Roald Baudoux
that would be interesting to know about. could be scaled up to multichannel audio cards too perhaps? a new analog sensor input, already available as channels on an external soundcard? pretty cool. careful not to blow anything up. that said, I wonder how the signal from an accelerometer would "sound" :)
Very interesting idea.
hope it's not out-of-subject and you obviously know that but, when looking for CHEAP and quick ways of getting analog sensors to computers (and not willing to arduino blah-blah), using cheap joysticks is easy as the voltage is yet closer to what is used by a lot of analog sensors.
Though the audio inputs would probably have a much quicker refresh ("poll") time due to sampling frequency...
Now that is an interesting idea, just found this:
http://www.techspot.com/vb/topic146269.html
Notably:
"1) a uV meter (used to measure audio) is calibrated to 0 dBV = 1 V RMS across 1k load at 1kHz and that is 'massive'
2) microphone inputs are in millivolts ( 5mV-50mV), and thus +- 4v would swamp the input circuit --
instead of nice sign wave inputs, the input curcuit would see something very square wave like
3) the input curcuit *MUST* be protected with a capacitor (value depends upon the lowest Fq to be allowed; a 0.1mfd would allow low Fq into the low impedence of transister/chip circuits) in series with the signal lead"
>microphone inputs are in millivolts ( 5mV-50mV), and thus +- 4v would swamp the input circuit --
This is true but you could reduce the signal voltage before entering the soundcard. However it would also probably reduce the signal-to-noise ratio. I suppose it wouldn't be difficult to take the power from a microphone input but send the signal output from the sensor to a line input. It spoils an additional input but for me it's not a problem.
But the main question remains the frequency range of audio inputs: wouldn't they filter the almots-DC frequencies from the sensors when the signals evolve slowly ?
> using cheap joysticks is easy as the voltage is yet closer to what is used by a lot of analog sensors.
Interesting but does the joystick provide the +5V demanded by most sensors? Also, joysticks digitize with a lower resolution than soundcards (actually it depends on the HId implementation. I have seen that within Max some joysticks do not have the same resolution on MacOS and Windows).
The 24-bits resolution of the soundcard is what I am most interested in (even if the 5 V to more or less 1 V conversion would probably reduce the actual resolution).
Still thinking about the idea...
However it seems that most soundcards include a high-pass filter on the analog inputs to remove frequencies below 20 Hz. As analog sensors produce signals with very low frequencies, hence an unmodified soundcard couldn't be used.
A solution would be to either frequency- or amplitude-modulate the sensor signal before its routing to the soundcard. But then it should be demodulated by software afterwards.
I was just curious how the analog inputs of my soundcard (MOTU Traveler Mk I) would deal with very low frequencies. So I sent a cycle~ to one analog out and took it back from an analog input and compared output and input signals.
First, I have a small softening even for audio range frequencies despite of a full balanced output to input connection.
However, there is no significant difference between 100 Hz and 5 Hz. Below that point it's not so good. There's not only an expected softening but also some distorsion. Please have a look at the pictures below. The last one shows a 5 Hz to 0 Hz continuous sweep over 8 seconds.
The test was run at both 44.1 kHz and 192 kHz. The results are identical.
Of course one cannot know whether the output or the output is responsible for the results but I'd say both.
Here's an article about modulation of a DC signal:
Bonjour Roald,
just curious... what kind of sensor do you use that wil benefit a 24bits resolution?
The higher resolution I know for "standard" A/D interfaces is 16 bits in the Gluion. The Teabox has a 12bits resolution.
p
Bonjour Patrick,
I want to connect a ribbon to drive a playback head in a very long buffer, so any improvement of the precision in positioning would help. Currently I have only a 10-bits device (Interface-Z). I know about the Gluion but if I could adapt a soundcard input it might be a cheaper solution. Also, apart from the higher resolution the sampling frequency would be better too.