Introduction
A rotary switch is a switch operated by rotation. These are often chosen when more than 2 positions are needed, such as multi-speed control. The Rotary Switch uses an analog input to read the 12 state which saves IO resource for the Arduino. This Rotary Switch Module has most 12 position. Each position has the approprite indicator.You can also adjust metal buckle inside the switch to change position number.So, it's very flexible for you to use.
A rotary switch consists of a spindle or "rotor" that has a contact arm or "spoke" which projects from its surface like a cam. It has an array of terminals, arranged in a circle around the rotor, each of which serves as a contact for the "spoke" through which any one of a number of different electrical circuits can be connected to the rotor. Thus a rotary switch provides greater pole and throw capabilities than simpler switches do.
Specifications
- Supply voltage: 3.3-12V
- Interface: Analog
- Size: 43mm*38mm
How to Change Position Number
Regulating metal buckle among differrnt fixing hole can change position number.
Wiring Diagram
Sample Code 1
Sample Code 2
The same position value of each switch is different.So, by sample code 1, the each position value can be read, and modify the appropriate reference value in the following code.
FAQ
For any questions, advice or cool ideas to share, please visit the DFRobot Forum.