Hello, I'm trying to build automatic target detection system for .22 Long Rifle ammunition, the hit plate is gonna be made of stainless steel and the ammunition is lead
The idea is to use some kind of sensor to detect impact on the hitPlate which you can on the picture here
IIRC there is a "knock sensor" sketch for the use of piezo sensors.
But as Idaho states you need to give the specs of the sensor as there are a lot of variations out there.
I can read the values, but sometimes I get high value sometimes I get low value, even I'm hitting the plate the almost the same way, I'm not trying to make it too sensitive since I only wanna detect an ammo hitting it
Piezo disks can generate some high values albeit for short period of time. I wouldn't use an opto isolator as I don't see a piezo reliably powering the required input.
What you need to do is limit the voltage from the Piezo to the Arduino with a 5V TVS or Zener, then add a 10k between the zener and the Arduino digital input.
I cannot imagine a .22 hitting the disk and not getting a huge voltage spike from the piezo.
One could add a mass on the back side of the piezo but I doubt it will be needed.
Mounting: I can't see what holds the piezo to the disk. The best attachment would be a relatively hard epoxy.
Whereas I Have Done This and it's not a problem at all. Others have put videos up connecting leds directly to show. --- Semiconductor junctions flatten the spikes. --- I went as far as repeatedly smacking the disk with the butt of a screwdriver handle to get longer pulses. I tested one disk to destruction and no other parts smoked hard as I went for smoke.
I can't imagine a fry pan stainless steel disk that will stop a .22 long rifle bullet yet be so light that the transferred momentum shock will be as hard on a disk as the whole force of my screwdriver handle directly on the disk.
My experience with .22 LR is a few 1000 rounds spent target shooting to collect NRA medals for 3 years or so. I don't have to dream about them, I have ballistics tables.
I'm planning on squeezing it between the plate and another pice of metal that will be screwed to the plate to give it stability and get the full power of the hit is it logical ?