Arduino and SW-420 Vibration Sensor

posted in: Arduino | 19

In this Arduino Tutorial SW-420 vibration sensor was used. It can detect vibrations from various sources.

Download # Arduino Code (*.ino file)

or

Upload Arduino code directly to your Microcontroller from website


If you want to integrate Arduino IDE into your website (as above) sign up here: codebender

Follow me:

19 Responses

  1. Hi, thousand thanks for your code! i tried several not working but this works so perfectly!
    Btw, I will need to interface with two sensor, I dont know how to change the code to measure for two, could you please help me please?

    Thank you so much in advance..Have a great day!

    Sincerely,
    Caryn

    • I’m glad it works. The code is not complicated at all in order to add additional sensor, try to sort it out by yourself.

      • may I know what am I measuring in the code? is it vibration amplitude or vibration time ?

      • tell me if measure 8 sensor output value ….???

  2. azriel

    how to use this with arduino uno

    • The same way as nano, just connect to a proper pins, which is also written in the code itself.

  3. Is that the measurement is a frequency?

  4. Souvik

    HI, I had a quick question, according to my understanding, this is a digital sensor, in the sense that, the output from it is going to be only 0 or 1 based on the set threshold, (which you set by turning the potentiometer screw on board). How come your measurement output is showing values greater than 1?

  5. nanik alviandari

    thankyou so much. it works on my Arduino Uno with SW-18051P NO Vibration Sensor Module Arduino :)

  6. can you please suggest me which vibration sensor to use on car window to detect any vibration on window for my project vehicle antitheft system and which will be integrated to arduino uno

  7. Hi, what if I want to put more than 1 vibration sensor, may I know how’s the coding may look like?

  8. i would like put 8 sensor and how can i control these through arduino and and every sensor output must be display at computer individually and separately.so plz tell me if it is possible .

  9. Saved me some frustation… A million Thanks.

  10. What is unit for measurement ?

Leave a Reply