Question: weird audio mixing circuit conendrum - Page 1
Forum section: electronics / projects

author: vtkkorhanjoh
author_rank: Contributor
timestamp: July 21, 2013, 12:36:37 pm
content: I have for a long time been designing a directional and distance- based microphone array circuit, and wanted to do it as small and analogue as possible. The problem, is that I have a problem with the mixing part. I am going to use 7 extremely sensitive microphones, placed an even distance apart. The mikes are individually amplified and delayed, and finally ran into a mixer to make the sound coming from only from a specific source, a specific distance away, at a specific angle, reach the headphones (or an adc), while blocking out all the other crap.I wonder how i can make a relatively small, analogue mixer that greatly amplifies the tiny equally-timed similarities in the signal, and silences all the non-simliar noise the majority of the signal will have. I have thourght about some weird AM- modulating sceme, but it has been a complete flop.All help would be greatly appreciated, as this has taken up way too much of my spare time, and has made me quite annoyed and somewhat anguished!

author: David_AVD
author_rank: Super Contributor
timestamp: July 21, 2013, 12:41:13 pm
content: How close are the microphones to each other and how far away is the sound source? I ask this as mixing multiple microphones that share the same source can result incomb filtering effects.

author: vtkkorhanjoh
author_rank: Contributor
timestamp: July 21, 2013, 04:45:50 pm
content: I was thinking everything from 10cm to about 1 metre, and the source everything from a few metres up to around 50m. And i know that with normal setups the comb filtering effects will ruin the signal, but i am going to rely on a precise delay to cancel out the very slightly differing times of arrival. The mixer would have to be extremely sensitive and selective, but i know this is possible as i have seen the same thing done with an FPGA.

author: fcb
author_rank: Super Contributor
timestamp: July 21, 2013, 04:59:24 pm
content: Basically, you're describing SONAR - but I guess you already know that.One method SONAR arrays use:Take X transducers (microphones/hydrophones/whatever), amplify and convert (ADC*) them simultaneously. Then add a (carefully calculated) delay to each microphone's output. Then sum them. Do this in parallel for each channel and for each angle you want.The sample rate needs to be high enough that you can get meaningful delay granularity, but this will depend on the size of the array somewhat (distance between sensors). The noise level will increase with each added source, but so will the size of the correlated signal.So from a practical point, I would use 4 stereo ADC's running at 96/192KHz, into a simple DSP.Create at least 5 delay based correlators as above.Then look for the differential small regular signal (it will appear the strongest in the correlator that is best aligned).Once you have the signal, you could do some retrospective gating on the output of that correlator to get a higher perceived S/N ratio).You've chosen to do it in analogue... That's going to be more difficult - do you know the exact repetition frequency of the signal could you lock onto it with a PLL (4046), are you trying to detect it's presence or make some quality judgement about it?

author: vtkkorhanjoh
author_rank: Contributor
timestamp: July 21, 2013, 05:18:44 pm
content: Well if i was only going to use it like a detecting sonar it wouldn't be a big problem. But i am trying to locate, then zoom in on, then listen to an audio source, so a PLL system is not fesible. I have thought about a system consisting of some adding and subtracting op-amps and a logarithmic one plus a few standard averaging audio mixers, but the system i had was no good, and took up way too much space.I can do it digitally if it is absolutely nessecary, but it would have to be extremely selective, very small, have little power consumption and high resolution. If anyone knows a way to do it. I am all ears!

author: fcb
author_rank: Super Contributor
timestamp: July 21, 2013, 05:25:41 pm
content: There's too little information to go on. And I think you'll struggle massively with doing this in the analogue domain.I guess you can't scan a microphone (parabolic reflector?) if you need a physically small system.Look up "acoustic sniper detection", you may get a few more hints - but it's all digital past the front-end.

author: vtkkorhanjoh
author_rank: Contributor
timestamp: August 07, 2013, 03:36:13 pm
content: I did some reading, calculations, and the news weren't great. I need at lest a 16 bit ADC running at minimum 12GHz... I guess it has to be done the analogue way after all!

author: fcb
author_rank: Super Contributor
timestamp: August 08, 2013, 08:08:24 am
content: Can you explain your proposed setup in more depth, and your workings out.12GHz...

author: Marco
author_rank: Super Contributor
timestamp: August 08, 2013, 01:29:00 pm
content: Ignoring the mixing for a moment for which I (and I think everyone else too) don't really understand the relevance ... you are going to have to delay the signals too somehow. LOTS of coax to build delay lines can work, the old discretized bucket delay line ics might work ... but they are both silly, you can't really avoid digital.PS. how is a fpga relevant to analogue signal processing?

author: vtkkorhanjoh
author_rank: Contributor
timestamp: August 08, 2013, 01:41:44 pm
content: Well, lets say the microphones are 10 cm apart (dm), the source is over 50m away (ds), the audio out sample rate is 44Khz.First, we need to find out the distance between the mic 1 and mic 2 in correlation with the source;tan?¹(dm/ds)Now multiply that by the inverse ov the speed of sound to find the time the sound will use for that distance(tan?¹(dm/ds))*1/340m/sFinally, invert the equation and multiply it by the audio sample rate, to get the sampling frequency required to make out the time difference:(1/(tan?¹(dm/ds))*(1/340m/s))*44khzSo finally, for my proposed operating distances;At 50m, my smallest max operating range; (1/(tan?¹(0,1m/50m))*(1/340m/s))*44khz=7,48*10? Hz=7,48GhzAnd at 75m; (1/(tan?¹(0,1m/75m))*(1/340m/s))*44khz=1,122*10¹? Hz=11,22GhzAnd at 100m, my maximum operating range; (1/(tan?¹(0,1m/100m))*(1/340m/s))*44khz=1,496*10¹? Hz=14,96(lets say 15)GhzI intend the microphones to sit 10cm spaced out on a pair of oversized sunglasses, except much wider than normal, with the electronics mounted inside the frame. If i could put this stuff in a 19" rack box, it wouldn't really be a problem, but because this is supposed to be battery powered, worn on the head and possible to make with todays technology, there's no way i can do it. Unless someone knows of a 16bit+, 8Ghz minimum adc that takes up no more space than a standard SO8 package, that is...And Marco, The delay would be FPGA based if i was going to go the digital way. But since i am going analogue way, the delay part must be done with a special BBD setup, it is not possible to adjust a coax delay line over two orders of magnitude with such cramped space. I am thinking about individual mosfets, capcitors and resistors soldered with the component leads together.

author: fcb
author_rank: Super Contributor
timestamp: August 08, 2013, 04:02:52 pm
content: I'm very sceptical if your concept will work with any amount of processing. Even things like small local variations in air temperature over your range will significantly effect your accuracy, that aside I think you should rethink your approach, also 12GHz should indicate that something is awry.If you go forward, I would suggest getting your concept to work regardless of size (even if you have a truck driving behind the sensor block/guy/assy), worry about miniaturization later.Many years ago I did some work on small TDR based level sensors, the trick to making these work was to average over 10K samples - do you have control of the noise source?

author: vtkkorhanjoh
author_rank: Contributor
timestamp: August 08, 2013, 04:40:12 pm
content: Yeah i am probably going to go analog, i have for a while thought about some weird dc- coupling and subtracting op- amp sceme. And no, i have practically no control of the source, especially because i may use this for animal localization and listening in on conversations way out of normal hearing range.

author: ejeffrey
author_rank: Super Contributor
timestamp: August 08, 2013, 07:04:35 pm
content: I didn't follow your calculations exactly, but it can't possibly be right. You haven't included the most important parameter, the desired angular resolution. My guess would be that you are using the 10 cm separation of the microphones as the source separation at 50 meters.I also don't really understand your sampling rate calculation at a fundamental level. Getting a number like 12 GHz from a audio sampling system could be an indication that you are trying to do something impossible, but much more likely it means your equations are wrong or not appropriate. You need a time resolution on the order of the arrival time differnence, which should be hundreds of nanoseconds or microseconds, implying a sampling rate more like 1 MHz. Even that is probably not necessary: with good SNR you can have time resolution much better than 1/ sample rate.

author: Marco
author_rank: Super Contributor
timestamp: August 08, 2013, 08:48:28 pm
content: Quote from: vtkkorhanjoh on August 08, 2013, 01:41:44 pmNo, that's an angle ... the distance difference is sqrt(50^2+0.1^2)-50

author: Marco
author_rank: Super Contributor
timestamp: August 09, 2013, 11:33:49 am
content: Any way, lets make a basic problem statement regardless of whether it can work analogue or digital ...Presumably it's the user's task to look straight at the source and to set the distance (no bloody way can you do sound localization with analogue electronics) Then you want to precisely delay the signals from the microphones to match up before averaging them, this delay is a non-linear function of distance, with BBDs you would need a VCO for each BBD with some way of generating the nonlinear voltage function from distance in analogue ... uhuh.Really it's hard to see what's less likely ... that this could work or that it makes sense to try to do this in analogue.Just for a lark lets determine the distance at which a 1 KHz signal goes 180 degrees out of phase between 2 microphones at 10 cm apart when it is off axis (so you expect some decent attenuation from the averaging). I wasted a little time calculating before realizing the answer is NEVER (max phase difference is when it's infinity off axis, at which point the path difference is still only 10 cm which isn't enough for the 180 degree phase difference). The phase differences between closely spaced sources will be tiny when the distance between the microphones is tiny, you can't effectively filter them out by just averaging ... you have to get a lot trickier than that.

author: vtkkorhanjoh
author_rank: Contributor
timestamp: August 09, 2013, 02:06:07 pm
content: Actually tan?¹(dm/ds) is a distance, however, it is just like using pythagoras, like you did.And to ejeffery: You may be right there, i am to be honest not totally shure about my calculations after the arrival time calculations myself. I am certain that the smallest time of arrival is around 2,9us, so the max sampling frequency should at least be 350Khz, if what you say is true. Actually, now that i think about it, the 12+ Ghz figure sounds quite silly.Thanks for the comment, is stirred up a lot of thoughts!

author: Marco
author_rank: Super Contributor
timestamp: August 09, 2013, 07:58:20 pm
content: Just because you need a digital delay of X seconds resolution doesn't mean you need 1/X sampling frequency ... shifting a sampled signal by fractions of the sample time is perfectly possible.I'm pretty sure the inverse tangent really gives an angle as a result ... it does not give the length difference between the hypothenuse and the leg between which that angle occurs. It certainly doesn't come out to the same number as my calculation.

author: vtkkorhanjoh
author_rank: Contributor
timestamp: August 12, 2013, 07:00:04 pm
content: It may be, I did all the calculations at two Am... But are you sure i can use like a 512kS/s or less adc? If so, digital is back in concideration!

author: Hideki
author_rank: Frequent Contributor
timestamp: August 13, 2013, 01:32:28 am
content: You need to sample at twice the highest frequency that is present, to avoid aliasing. You don't need to sample any faster than that. For general audio, that means 44.1 or 48 kHz is perfectly fine, and even less if it's only for speech.All this confusion seems to come from the assumption that you MUST change the delay in single-sample increments, but that's not true. Maybe it's time to learn about digital signal processing? There is tons of information out there about how to do fractional delay filters that will let you delay the signal 0.5 samples or 13.987234 samples or anything you like.A certain degree of oversampling (sampling faster than you really have to) can be helpful for signals close to nyquist (since the interpolator doesn't have to be as perfect) but not the insane amounts you have come up with. It depends on how much processing power you can throw at it.If you insist on single sample delays, the ADC could still run at a lower rate and then be upsampled to a higher rate using software.

author: vtkkorhanjoh
author_rank: Contributor
timestamp: August 13, 2013, 11:34:19 am
content: It probably is time for that, yeahI have not really dribbled much around in it, as you can probably tell. But i will lokk into it, and thanks for the reply!