Pin-Pointer Metal Detector - Arduino

23,409

162

31

Introduction: Pin-Pointer Metal Detector - Arduino

About: I love the challenge of building unique things. My goal is to make technology fun and help individuals build the skills and the curiosity to experiment with some of the amazing technologies we have available t…

If you are a Metal Detector enthusiast or just looking for a handy workshop tool then you'll like this unique handheld pinpointer for narrowing down the specific location of a metal target.

Using four independent search coils, cool LED colors for signal strength and haptic feedback you can easily discriminate between multiple metal objects.

Step 1: Gather Materials

There are multiple variations of Metal Detector designs. This particular type of metal detector is a Pulse Induction detector which uses separate transmit and receive coils. Note: The circuit has just been simplified to reduce the need for signal diodes and improve sensitivity by employing 2N7000 FET devices on the TX coil.

  1. Arduino Pro Mini
  2. USB to Serial Module for Programming the Mini Pro
  3. LM339 Quad Differential Comparator Integrated Circuit
  4. Vero Board - 2 pieces (16x11 holes and 34x11) see photo for orientation
  5. BC548 NPN Transistor x 4
  6. 2N7000 MOSFET Switch x 5
  7. Piezo Buzzer
  8. Coin Vibration Motor for Haptic Feedback
  9. WS2812 RGB LED Module x 4
  10. 1k Resistor x 4
  11. 10k Resistor x 4
  12. 47 Ohm Resistor x 4
  13. 2.2K Resistor x 4
  14. 330pf Ceramic Capacitor
  15. 0.15uF Polyester capacitors
  16. Roll of 0.3mm Enamel Copper Wire (normally come in rolls approx 25g Weight)
  17. Push Button Switch
  18. 4 x Bamboo Kebab sticks 2mm Diameter
  19. Electrical Conduit Pipe 20mm diameter length 15cm
  20. Flexible Electrical Conduit Ducting 32mm Diameter length 15cm
  21. Electrical Conduit Reducer 25/20mm
  22. Electrical Conduit Reducer 32/25mm
  23. Plastic Waste Pipe 32mm Standard Size (32mm inside measurement)
  24. Electrical Conduit End Stop 25mm
  25. Waste pipe termination fitting 32mm
  26. Glue Stick
  27. Hot Glue Gun
  28. 2mm and 3mm Drill Bit
  29. Handheld Drill
  30. Label Gun or Sticky Tape suitable to label 16 separate wires
  31. Hookup wire
  32. 2200mha USB Rechargeable Power Bank
  33. USB Cable suitable to be modified

Step 2: Build Search Coils

The first Photo shows a finished Search Coil with 8 coils and 16 labeled wires extending down the center of the Coil Assembly. This may look daunting however is quite simple as I have provided a template and a method to easily construct.

The first coil is located at the end of the Coil Assembly so that you can pinpoint the target more easily. There are three separate pairs of coils on the side of the Coil Assembly.

1. Prepare the Coil Assembly

Cut a 15cm length of 20mm Electrical Conduit Pipe. Download the template provided, print out on A4 paper and then cut out and glue to the outside of the pipe. Take care to ensure the arrow is at one extreme end of the pipe.

2. Drill the Holes

Use a 2mm drill bit to drill the 16 holes marked on the template for holding the Coils in place. The diameter of these holes should be just big enough to hold a Bamboo Kebab Skewer as per the photos.

3. Channel 1 Search Coil

The first pair of search coils is located at the end of the Coil Assembly so that you can pinpoint the target more easily. This consists of an Outer and Inner coil as per the photo. The inner coil is 12mm diameter wound with 20 turns of copper wire. This is glued into place with hot glue. The two wires are passed down the tube with an additional 10cm length extending past the end of the tube. MAKE SURE YOU LABEL THE ENDS OF THE COILS SO THEY CAN BE IDENTIFIED EASILY WHEN CONNECTING UP TO CIRCUIT BOARD.

The Outer Coil is simply wound around the end of the 20mm Conduit with 20 turns of copper wire and the ends passed through the hole marked on the template.

4. Channel 2-4 Search Coil
The next 3 coils are located on the side of the Coil Assembly. Use 4 Bamboo Kebab Skewers to provide a stable point to wind the coils in place until they are glued and labeled. These are clearly marked on the template and are wound with 20 turns of copper wire then glued into place with hot glue.

Start with the inner coil first so that it won't interfere with the winding process when you come to the next coil.

The two wires are passed down the tube with an additional 10cm length extending past the end of the tube. MAKE SURE YOU LABEL THE ENDS OF THE COILS SO THEY CAN BE IDENTIFIED EASILY WHEN CONNECTING UP TO CIRCUIT BOARD.

Step 3: Build the Circuit

The outcome of this step is to produce the two circuit boards ready to connect to the search coils. This consists of two circuit boards to minimise size. I've attempted to provide multiple photos of both sides of each board to enable easier construction. I will attempt to produce a component layout in the next few week.

Step 4: Add LEDs to Coil Assembly

Print out an additional copy of the Coil Assembly template provided and use this as a stencil to get the LED spacing correct. Follow the method in the photos for positioning and carefully soldering the LEDs.

I used a strip of Duct Tape to hold the LEDs in place while cutting and soldering the wires. Take care not to overheat the LEDs and ensure that each LED connection is oriented as per the circuit diagram.

The WS2182 LEDs have a built in IC which enables them to be addressed by the Arduino using three separate wires however a broad range of colors and brightnesses color can be created by sending a command to the LED.This is done through a special library loaded into the Arduino IDE covered in the testing section.

Once the four LEDs are p\lace solder 3 wires for the Data, Positive and Negative connection to the PCB. Drill a 3mm hole in the Assembly and pass this back through the center of the tube as with the other wires. Ensure you label the wires correctly.

Step 5: Preparing the Enclosure

The construction of the enclosure has been made from parts that can be sourced from any good hardware store.

The photos lay out the approach to connecting the enclosure together using the provided materials.

The USB Power Pack is mounted inside the 32mm Tube and held in place with Hot Glue. The position of the USB ports enables you to connect a USB cable to supply the Arduino and at the same time provide access for charging through the removable end cap. See photos.

Step 6: Putting It All Together

1. Physical Assembly

The final step is the connect the circuit boards to the coils, LEDs, Power Pack and Power Switch as per the circuit diagram. The LED and Vibrating motor will not function when connected to the USB as they are powered from the Raw supply. However, this can be tested with the battery connected.

2. Loading Arduino Code and Testing

Before loading the Arduino code you will need to add the Library "FastLED.h" as a library to drive the WS2182 LEDs.

A series of Oscilloscope Traces have been provided for troubleshooting if there are issues.

3. Operating the Unit

The unit operates by calibrating after pushing and holding the power button. All of the LEDs will flash when the unit is ready to be used. Keep the push button down while searching. The LEDs change from Blue-Green, Red, Purple based on strength of target object. The haptic feedback occurs when the LEDs turn purple.

Now go and find some treasure!!

LED Contest 2017

Second Prize in the
LED Contest 2017

Arduino Contest 2017

Participated in the
Arduino Contest 2017

Epilog Challenge 9

Participated in the
Epilog Challenge 9

Be the First to Share

    Recommendations

    • Trash to Treasure Contest

      Trash to Treasure Contest
    • Stick It Challenge

      Stick It Challenge
    • Woodworking Contest

      Woodworking Contest

    31 Comments

    0
    jallall1960
    jallall1960

    6 months ago

    شكرا جزيلا استجبتم لطلبي وكرمتوني اتمني من كل قلبي ان نبقي على اتصال
    ولكم توفيق وسلامة دائمة
    المخلص جلال

    0
    TechKiwiGadgets
    TechKiwiGadgets

    Reply 6 months ago

    No problems. Message me if you have any more questions on my instructables and Im happy t help.

    0
    sthomas55
    sthomas55

    1 year ago

    Since the photos show the diodes, I can assume that the components shown are the BC548 for the 8 on the daughter board. But the circuit diagram is constructed with the 2N7000, and the photos don't work for that. Since the source pin doesn't have the 47 ohm resistor. I attempted to clone what you have visually in the pictures. I think I will need to turn the 7000's around. So that the flat sides of the 548 and the 7000 are facing each other.
    Or did I completely screw this up?

    0
    art30
    art30

    1 year ago

    Hi.....I notice that you removed the flyback diodes when switching to MOSFETS in the transmit coil circuit. Has this posed any issue concerning high voltage kickback and MOSFET burnout? Thanks!

    0
    grovento
    grovento

    Question 1 year ago on Step 6

    HI! Nice device. Can I replace Pro Mini with Nano?

    0
    LongJohnM
    LongJohnM

    3 years ago

    It seems to be a great project. I am working on your other 5coil and 4 coil metal detector projects.

    I have a question about replacing the 2n7000 for the bc548.

    Did you try replacing this on the Rx also ? - it might increase Sensitivity.

    0
    TechKiwiGadgets
    TechKiwiGadgets

    Reply 3 years ago

    hi

    Yes I did try this and there was not a noticeable improvement. I am experimenting with other coil designs to try and improve sensitivity.

    Will keep you posted.

    0
    jont4e
    jont4e

    Question 4 years ago

    Hi,

    I bread-boarded your circuit for just the end coils to start, and loaded the sketch. It seems to be pulsing the coil OK but the leds aren't responding nor the buzzer.

    I uncommented the serial port code and it shows ledthreshold1 always at .97, pcounterA at 12, and calav1 at 81. Is this OK? (The other reported variables are always 1000.)

    I wound the end coils with some bifilar wire I reclaimed from a microwave HV supply transformer. I assumed that was OK?

    Do you have a flow chart or description of how the code works so I can trobleshoot?

    Any help or hints would be greatly appreciated.

    Jon T

    0
    TechKiwiGadgets
    TechKiwiGadgets

    Answer 4 years ago

    The pcounterA value should be much higher 200 to 800 at least. My advice is to focus on one channel. Try reversing the polarity of one of the coils as this often is the problem as the pulseIn function needs to have a clean leading edge to trigger the timing process. Ensure your breadboard connections to the coil are short and well grounded. If this does not work direct message me with a link to some photos of your setup and I will try to assist. Im just building a second unit so your timing is fortuitous as I can provide some test measurements.

    0
    PiruJake
    PiruJake

    Question 4 years ago on Step 1

    What is the size of the 4400mha USB rechargeable Power Pack that you used and can you tell me the maker of it?

    Thanks
    JD

    0
    TechKiwiGadgets
    TechKiwiGadgets

    Answer 4 years ago

    Actually my apologies I double checked and its actually 2200mha Power Bank. Ive updated the parts list with a link to the supplier. I suspect you can get on amazon or aliexpress. I'll update circuit diagram with changes.

    0
    jont4e
    jont4e

    Question 4 years ago on Step 1

    Hi, I like your idea of 2 coils to simplify the electronics. One question: On your schematic you show the comparator + input as well as the BC548 collector pull-up resistor tied to the +5V supply. Does the comparator negative(-) input reach that level during a pulse, allowing the comparator output to go negative? I would have thought you would have created a lower and adjustable reference voltage for the comparator + inputs.
    Regards,
    JT

    0
    allangee
    allangee

    4 years ago

    Have you done any field testing? I'd be interested in seeing, for example, how deep it can pinpoint a dime.

    0
    TechKiwiGadgets
    TechKiwiGadgets

    Reply 4 years ago

    Hey I tried to show depth in the video which is about 30mm from the coils for a small coin. The intention is that you use this to pin point in a small area as opposed to do deep search of objects ts. However I am trying a few different coil confidential to improve depth.

    0
    BrianK208
    BrianK208

    Reply 4 years ago

    Depth would be huge. A populate application would be for finding property pins.

    0
    charles543
    charles543

    4 years ago

    Would this be suitable to detect nails in wood to keep from messing up a saw blade?

    0
    TechKiwiGadgets
    TechKiwiGadgets

    Reply 4 years ago

    Hey, I did a quick test and found the tip of the detector will locate flat head nails and screws in Jib Board and Wood. (Heads are about 5mm diameter) The closer to the coil the object is the more likely it will trigger so I suspect reducing the thickness of outer cover would possibly mean the side coils would detect to make it easier. Hope this helps.

    20180123_155817.jpg