Analog Rotation Sensor V1 (SKU: DFR0054)
From Robot Wiki
Contents
1 Introduction
2 Specification
3 Pin Definition
4 Connection Diagram
5 Sample Code
Introduction
Analog Rotation Sensor V1 (SKU: DFR0054)
The DFRobot Rotation Sensor V1 is arduino compatible and can be rotated upto 300-degree. It is
based on the potentiometer. With the Arduino sensor expansion board, in combination, it can be
very easy to achieve position-dependent interaction with the rotating effect or produce MIDI
instrument.
Specification
Interface type: Analog
300 degree rotation sensor
Pin Definition
The definition of gas sensor pin is
1. Signal Output
2. GND
3. Power
Analog Sensor Pin Definition
Connection Diagram
Analog sensor connection diagram
Sample Code
// # Editor
: Lauren from DFRobot
// # Date
: 30.12.2011
// #
// # Editor
: Lauren from DFRobot
// # Date
: 17.01.2012
// # Product name: Rotation Sensor v1/v2 or Analog Slide Position Sensor
// # Product SKU : DFR0054/DFR0058/DFR0053
// # Version
: 1.0
// # Description:
// # the sample to drive some analog sensors
// # Connection:
// #
Signal output pin
-> Analog pin 0
// #
void setup()
{
Serial.begin(9600);
//Set serial baud rate to 9600 bps
}
void loop()
{
int val;
val=analogRead(0);
//Read slider value from analog 0
Serial.println(val,DEC);//Print the value to serial port
delay(100);
}
Powered By DFRobot © 2008-2017
很抱歉,暂时无法提供与“DFR0054”相匹配的价格&库存,您可以联系我们找货
免费人工找货- 国内价格
- 1+36.19752
- 3+31.92137
- 10+31.50214
- 国内价格 香港价格
- 1+25.300861+3.03779