INFOSTATION CORP
  • Home
  • Gallery
  • Contact
  • About
  • Digital Goods
  • Home
  • Gallery
  • Contact
  • About
  • Digital Goods
Search

Tap! Tap!  using the Knock Switch Sensor Module

20/6/2019

Comments

 
The Knock Switch Sensor Module (also known as Tap Module) is a mechanical sensor that detects knock or tap or vibration.  It is almost the same behavior with our previous article using the Shock Switch Module.  The only difference is that you have to apply more pressure or knock the module to trigger the desired output. The default desired output is LOW level (same with Shock Switch Module).  This mechanical knock sensor in the module contains a coiled spring in a clear plastic housing and a pull-up resistor.

Note: If you want to reverse the desired output, from LOW level to HIGH level, you just interchange the connection of the GND and the power line (middle pin).
Picture
Connection
The module contains three pins with 10k ohms resistor. Connect the "-" pin to GND of Arduino, the middle pin to 5V of Arduino and the "S" pin to any digital pin of Arduino (ex. pin 4 of Arduino as an example to our code below)
​
Module
Arduino
"-"
GND
middle pin
"S"
4
Picture
Code example for Knock Sensor Module

    
Upload the code to Arduino and test the knock sensor module. Tap harder. Once it detects the impact, the LED will turn on.
Comments

    Noel Anonas

    Author, coder, Innovator
    email:
    ​noelqanonas@gmail.com
    My Resume
    ​Couse Outline for Java

    Picture

    Archives

    July 2019
    June 2019
    May 2019
    June 2017

    Categories

    All

    RSS Feed

    View my profile on LinkedIn
  • Home
  • Gallery
  • Contact
  • About
  • Digital Goods