Interfacing Key Switch Module with evive

About This Tutorial
The tutorial will show how to interface key switch module with evive and display the state of the switch on TFT Display.
Tutorial Info
Programming Platform:
Difficulty:
Estimated Time (hrs):
2

Components Required

ImageComponentQuantityAvailable in Kit
evive1
USB A-B Cable1

Introduction 

The key Switch module work as switch which is on when button is pressed and off when it’s not , so when the button is not pressed  high signal is received at the digital pin and when the button is pressed the current passes through the switch and a low signal is received at the digital pin ,advantage of using key switch module is ,  it has in built pull up resistor which will pull digital pin high when switch is not pressed.

 

Before proceeding further in to this tutorial go through  evive digital input and Tactile switch tutorials which will give you some idea about digital input and why we use pull-up and pull-down resistors.

Circuit Diagram

  • Connect signal pin of key switch module to pin number 10 of evive
  • Connect middle pin to VCC
  • Connect pin having ‘-‘ sign on board to GND 

 

Code

So when switch of the key switch module  is pressed , digital pin will read low signal and high when switch is not pressed  , also the state of the digital pin will be displayed on TFT display.

This Helped
This didn't help
Close Menu
×

Cart