I have a circuit built using a Piezo vibration sensor large Meas with mass weight. I used the code similar to the knock sensor.
val=analogRead(0);//Connect the sensor to analog pin 0
float rating = val*(500/1023.0);
It works very well and gives me streaming data to the serial monitor. What I can't figure out is a way to make it print just the highest value per impact. Each impact will occur and be followed by no activity for a couple seconds. Currently I am seeing pretty reliable data but I can't figure out what to do. I tried to change the delay and I tried to assign a value to different ranges without success.