Main Site Documentation

Panda II Comparing Voltages question


#1

How would i go about comapring two voltages (milivolt range) from different sources and based on the result turn a servo on way or the other?

The idea is to have 2 microphones pointing 180 degrees away from each other. If a noise is louder on one side i need to turn both mics so that the sound level is even (within a tolerance i guess)

To visualize this think of how your ears work. You hear a sound on one side then turn your head to look directly at it

I guess some kind of opamp setup would be needed? or could i just use analog inputs on the panda II and compare in code?

All thoughts greatly recieved :slight_smile:


#2

Not everything should be done in software :slight_smile:


#3

If the microphones are 180 deg apart, say at 0 and 180 degrees and the source of the sound was 90 degrees you could not determine if the sound was at 90 or 270 as both microphones would pick up the same sound level. You would need ad least three microphones to know from what direction the sound came. Assuming that the sound is not constant enough to pan and locate it, if it is constant than one microphone would do.


#4

@ gus this looks interesting, many thanks :slight_smile: looks like I have a learning curve to play with.

@ jeff there would be a rotation constraint on the servo of about 170 degrees so even if the sound source was at say 270 (directly behind ) then that would be fine just to rotate to where the levels are even.

Does anyone know of a comparator that can compare milivolts?


#5

Any Opamp can:

use it as a differential amplifier
http://en.wikipedia.org/wiki/Differential_amplifier