Electronic Components Datasheet Search
  English  ▼

X  

DFR0027 Datasheet(PDF) 4 Page - DFROBOT

Part # DFR0027
Description  DFRobot Digital Vibration Sensor V2 SKU:DFR0027
PDF  4 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  DFROBOT [DFROBOT]
Direct Link  https://www.dfrobot.com/
Logo DFROBOT - DFROBOT

DFR0027 Datasheet(HTML) 4 Page - DFROBOT

  DFR0027 Datasheet HTML 1Page - DFROBOT DFR0027 Datasheet HTML 2Page - DFROBOT DFR0027 Datasheet HTML 3Page - DFROBOT DFR0027 Datasheet HTML 4Page - DFROBOT  
Zoom Inzoom in Zoom Outzoom out
 4 / 4 page
background image
2 //Connect the sensor to digital Pin 3 which is Interr
upts 1.
3 #define SensorINPUT
3
4
5 unsigned char state = 0;
6
7 void setup() {
8
pinMode(SensorLED, OUTPUT);
9
pinMode(SensorINPUT, INPUT);
10
//Trigger the blink function when the falling edge
is detected
11
attachInterrupt(1, blink, FALLING);
12 }
13
14 void loop() {
15
if (state != 0) {
16
state = 0;
17
digitalWrite(SensorLED, HIGH);
18
delay(500);
19
}
20
else
21
digitalWrite(SensorLED, LOW);
22 }
23
24 //Interrupts function
25 void blink() {
26
state++;
27 }
Result
As shown in figure connection , plug LED and lay a finger on Digital Vibration Sensor , LED will be
lightened
Trouble shooting
More question and cool idea, visit DFRobot Forum
Powered By DFRobot © 2008-2017



Html Pages

1 2 3 4


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com