Introduction: Arduino Metal Detector +

About: Wanderer extraordinaire. Writing reflects thought and vice versa!

This Instructable is a hodge-podge of bits 'n' bobs gleaned from the Internet including others' far more talented Instructables plus my own less-than-talented additions. It should be viewed as a work-in-progress especially since it is my very first Instructable. So please do be kind?

It is basically a metal detector using an Arduino. This was covered very well elsewhere so top job to that contribution. My own addition is to tweak the software slightly and add a further associated step (notably a method to simply calculate a mean value) . Furthermore, instead of relying upon a factory ready Arduino, I will run this on a bare bones version I made myself. Of course, there's nothing wrong with the former approach, I just like to make life difficult for myself. You can go your own way!

I will point to others' influences - give credit where its due (as much as humanly possible) - in the spirit of collaborative openness which for me is the hacker/maker ethic.

So, it's a "Frankenstein's Monster" because of the numerous sources involved to arrive at the final monstrous piece!

Supplies

Supplies are covered elsewhere and pointed to within the steps...this Instructable additionally requires access to a Spreadsheet - any will do.

Step 1: Assembling Parts.

The main place I turned to when constructing my own Arduino was the Arduino pages on constructing your own Arduino! It was fairly straightforward. Personally I power these kinds of projects from either a USB Power Bank or a USB socket usually. I have a tiny micro USB socket that plugs into the breadboard which then (sometimes) links to a small board producing either USB levels or 3.3 volts as necessary. My own ATMega chip had a bootloader installed already but if your's doesn't the previous link helps you do that.

In the photograph above you can see the current 'construction'. Ideally I'd trim component legs and perhaps use a better layout but hey ho...

The ATMega "DIY Arduino" is powered from the FTDI programmer board. That board converts USB (from your computer) to serial (to program the ATMega chip).

Additionally in the photo you can see the DIY coil and a resistor plugged into the ATMega chip pins. Be sure to choose the correct pins by following the pinout diagram in the first link.

So, this is basically the metal detector and a DIY Arduino all together on one breadboard.

Step 2: Tweaking Software.

I made a few additions to the original software to suit my own purposes. I tried to add those after comments in the code in UPPER CASE to distinguish them.

I didn't wish to hear the tone on the speaker (I don't use one) and I preferred a simple on/off of the LED hence calculating the Standard Deviation in a spreadsheet. At the moment that's hard coded.

I am including both my version of the software and my spreadsheet again in the spirit of openness. Feel free to critique! I was a little out of my depth here! :)

Any spreadsheet will do. Just use the inbuilt Standard Deviation (SD) function.

Step 3: Systems Testing.

In terms of testing I tested the coil by measuring both resistance (so that it was within the range specified), the number of LED flashes (that the original software amazingly produces) and the continuity to ensure the connections were sound. For the first and last tests just use a multi meter.

It is all kind of cobbled together for the time being but, again, it does seem to work!

Testing software is another matter altogether. The values produced in the Serial Monitor are very useful. I also tried using the Serial Plotter though I'm unsure what it told me really.

So, metal objects are detected. The LED flashes around once/twice/three times before settling down again.

Step 4: Worldly Applications.

Why go to all this trouble? Well, I'd really like an input to a micro controller. I dream of a tiny metal detecting robot that fits in a tobacco tin. This was all an experiment to work towards achieving this dream. Its one 'solution' out of several currently being attempted.

Other solutions include a custom designed Printed Circuit Board using a CS209A Integrated Circuit "chip". However, that coil additionally employs decent Litz wire instead of enameled wire used here and a half pot core. That's yet to be finalised.

A further alternative which hasn't yet got off the drawing board employs a TD0161 chip and there are plenty of tutorials online for that.

Overall, its a fun and amusing quest. You won't necessarily get to detect to great depths - that all depends on many factors - but for testing out my kind of ideas this works just fine.