PIC Based Imaging Sonar

PIC Based Imaging Sonar

Matt Bennett

PIC Sonar Image I've wanted to build a sonar for a while now, and I was hoping to be able to do it with a design someone else had made, but alas, I've never had much luck. I've done many searches of web pages, and all that ever comes up are sonars that give a single range to one object. Nothing that would be useful for my purposes: an imaging sonar.

Over 10 years ago, I'd guess, there was an article in Radio-Electronics magazine about an imaging sonar that was using one of the Polaroid sonar modules and a stepper motor for azimuth. This only gave one range per azimuth step- still not what I really wanted.

So it ends up that I've built my own. I have two 40KHz ultrasonic transducers, one for transmit, one for receive. These transducers are steered by an R/C servo over 180 degrees of azimuth. I'm using 2 Microchip PIC microcontrollers, a 16C71 for the sonar portion, and a 16F84 for the servo control. There are two microswitches that sense the ends of travel of the servos, and this information is stored in non-volatile memory on the 'F84. It can scan the full 180 degrees, or it will scan just a sector, or it will give multiple readings in a single direction. All control and output is over a single 19.2 Kbps serial port.

The analog portion of this is pretty involved- I need to receive, amplify, detect and filter the signal before I put it into the 'C71. I built an extremely wide dynamic range full wave rectifier which rectifies the 40KHz signal without (much) distortion from 10mV P-P to about 3V P-P. I also incorporated a receiver protector circuit that shorts out the receiving transducer during the outgoing pulse and for 1ms afterwards.

The range right now is somewhat limited: about 6 inches to about 4 feet. The near range is limited by the ringing of the receiver caused by the coupling between the tansmitting and receiving transducer. I could have used just one transducer, but that would have extended the close-in blind period, because the ringing would have been harder to quiet. The far range is limited by the RAM of the 'C71. I'm hoping to get a 16C711 which has more RAM, which will let me double the range.

As it is, the transducers have a response that is much too wide in azimuth. I do need to figure out a way to focus the signal. I'm exploring the possibility of a phased array or a parabolic reflector.

The image you see above was an image of the junk on my workbench. Yeah, you can't see much detail, but it does demonstrate that I'm not just looking at noise. This image was done with a logarithmic response to bring out the detail in the low level returns. There is no sensitivity time control (STC) so the response still has to be scaled by 1/r4 (two way 1/r2 losses). I generated the image with Matlab, the raw data would not be very interesting to most. I'm hoping to write some code so I can generate images with one of my Linux computers, and place it live on a web-page.


Front View Another
Front View
Side View
of Sensor

Oblique View
of Circuit Board
Top View of
Circuit Board
Top View of
Sensor and Mount
I will be updating this page with more technical details and the theory (radar, DSP, electronics, etc.) behind my design, so stay tuned.

This is a continuting project, if you would like to donate time or materials, I would be very interested in hearing from you.

6/3/99 Update: I tried making a beamformed linear array, but because of the size of the sensors (5/8" diameter) I couldn't get them less than a wavelength apart, so I thought that the whole constuctive/destructive interference thing would still work. Well, it does, but not very well, and ends up with huge sidelobes. I did a little modeling with Matlab to find the pattern that I was getting, and it seems that while you can get very good boresight gains with transducer spacing that is greater than the wavelength, your sidelobes really suck. So, I guess then next thing to try is a parabolic reflector.

1/3/00 Update: In response to a number of requests, I've taken some pictures of the sonar.

Back to projects page
Back to Matt's Page

This page was last modified 516 weeks ago, on Wed Aug 18 2004.

All information contained on this page is © 1999, Matthew J. Bennett, and may not be reproduced, archived, mirrored, bought, sold, or bartered without express written permission of the Author.