Sorry, I forgot about sending you the board last weekend, I will have it out this weekend, I promise!
Sorry!
As for smarts, I think you surpassed this old geezerā¦
JK
You have come a long way since the beginning though. Proves you have really taken the bull by the horn and learned a great deal on your own. Yeeeehaaawww!
Although Iāll be playing with Mikeās loudness circuit for a while once I replace my programmer, in the meantime Iāve been putting together a circuit for my bipedās car that uses both loudness and speed as Pete did.
Iāve decided to go ahead and make it with 3 mics though, so the bot will know which direction (forewards/backwards) the sound is coming from as well.
Iāve finally come to the point where Iāve run out of ADC pins, though (and my micro has 13!).
So instead of keeping them seperate as in Mikeās circuit, Iām going to combine the three with another opamp.
In your circuit, Pete, it looks like you use 110k resistors before the 3rd opamp to divide each seperate voltage in half before smushing the two together.
So, methinks Iāll just take the output of my 3 opamps and use a 200kās and a 100k to divide each into thirds before smushing all 3 together.
Iām a bit confused as to the gain resistor across your opamps.
Mikeās circuit uses 1M.
Did you split up the gain into two stages by using 300k in the first and 110k in the second?
If so, how do you determine the overall gain of the two stages?
Iām thinking that itās not simply multaplicative, since thatād give you a 30M totalā¦
well nick, considering you asked me to help out on this on AIM, heres wat i think
you need to make this thing realllllyy power, the rover i mean, so that it can carry and little perron in it, (I.E. me), from there, you have me blindfolded while you recklessy race around you house, if i scream you know youāve hit something, and also, i would point to the noise when i hear one and from wat direction, if all works out, you shouldnāt need a new me for a dayā¦or two
Nick, perhaps Pete can chime in on the question regarding the gain resistors for the op amp. I know that the resistor acts as a feed back loop. Higher resistance provides less feedback to the neg input of the op amp. This causes the op amp to āthinkā it needs to amplify more.
Best way to describe it is like our ears are the neg input and when we adjust the volume on the stereo, we ālistenā for the loudness. We keep cranking up the volume till we get the desired output level. Now if you put ear muffs on your ears (the resistors) you will not hear the volume as much, so you keep cranking the output so that itās loud enough for you to hear it through the muffs.
The resistors on the op amp take the output and ātrickā the op amp into thinking it needs to crank out more and more.
This is in a nutshell how I understand it. Pete might want to put me in a straight jacket, but thatās my analogy of it.
In my circuit, the 3rd amp does a summation of the 2 signals, but it does not amplify the summation (because of the value of the feedback R). It is a simple āmixerā.
On your circuit with 3 sources instead of two, you should still use 100Kās all around. The reason is that the Rās for each channel are part of the equation for each other channel.
But if you want to add overall gain to the mixer, just increase the feedback R. The gain of the circuit is about proportional to Rf/Ri, so if the Rf were 200K, the gain is doubled. [This is a simplification, but itās close enough for now.]
My first stage has a gain of less than 300 (actually 300/1.1). Mikeās circuit is going for a rather high gain (about 1000). My own version hasnāt really been āroad-testedā yet, so I could end up changing the Rf values. Mikeās mics are different, as is his A/D.
It is multiplicative across the stages, but the first stage is 300, and the second stage is 1, so overall itās still 300.
Regarding the need for the feedback resistors:
An op-amp is fundamentally a very high-gain device. Without using negative feedback, it would run āfull throttleā all the time - it is called ārunning open loopā. This may sound like a good thing, but in reality it makes it unstable, and you wouldnāt be able to predict the exact gain for each amp. If you look at U5 on my schematic, those are ācomparatorsā, which are essentially a special type of op-amp that is designed to run open-loop. Why? Because a comparator is intended to have its output be either all on or all off (a digital signal). By comparison, the regular op-amps are intended to amplify signals proportionally; that is, they run ālinearā.
Mathematically, you could say that the output of an op-amp is y=mx+b (remember that from basic algebra?), where x is the input, m is the gain, b is the DC offset, and y is the output.
Ahhhh!
I love when things come full circle and finally click together.
I had been multiplying the gain resistor values when I needed to be multiplying the calculated gain of each stage.
That makes so much sense, since gain is reported without any units, the lack of which is produced by division of Rf/Ri.
Good olā function of a line, how well I remember theeā¦
Iāll be soldering it together tomorrow, probably.
If all goes well, Iāll be able to test it even before I get a replacement programmer for my robot PICs.
In school, the other students (slowpokes) just finished building their 16F877ās boards (which means that Iāve done that a week ago and have started programming in assembler ).
So, as soon as I learn enough assembler to multiply (thereās no multiplication built into this chip!) and access the ADC, Iāll be able to test it.
(Sigh)
Ya gotta luv archives. Here I was, contemplating just how to add audio direction-finding without re-inventing the wheel (again), when a site search reveals this.
Exactly what I had in mind. Complete. Whole.
Just thought you should know that old posts never die⦠and are appreciated by the cogniscenti.
Greetings kdwyer, this circuit is old, and although it works, its performance fell a little short. I have a new circuit design that eliminates the use of the ADC chip and performs much better. You can build two copies of the new design for left and right ears and write code to do fancy things like finding angles. I will try to remember to post the updated schematic tonight if youāre interested.
Now Iām interested too⦠And a few days have gone by. Slacker!
if all you are doing is trying to measure the difference between left and right, could you not have used the two mics more like a comparator? one to the inverting input, one to the non? I guess the issue would then be measuring the output. You donāt want infinite gain, because that would tell you left and right, but not by how much. And if you want to measure the output, you almost need a +5v and -5v with 741 chips, but that canāt be read easily by the atom. Anywho, didnāt see the original posts so Iām not sure what you tried, but Iāve always been interested in op-amps. My first robot was a line follower using 4 op-amp comparators.
No to what? Oh yeah⦠thatās right! just kidding
Ok the note in my hand worked! Here it is, see attached. The values are base values. When you bread board this circuit, you can experiment with C1, R2, R3, R5 values for desired sensitivity.
Thanks, an interesting circuit. I like the lights when it hears sounds
The two outputs- the first is the output of the op amp, whats the second? When the output is high, the transistor is open, so that would be the LED voltage it reads plus 0.3V of whatever for the transistor. When the output goes low that would go to 5V? So its almost but not really the inverse of output 1, or am I missing something?