Hardware Reference
In-Depth Information
Discussion
The analog-in pins on the Bone read a voltage between 0 and 1.8 V. (This is different from
the digital-in pins, which read either 0 or 3.3 V.) A variable resistor (as shown in Fig-
ure 2-10 ) has a fixed resistor between two terminals and a wiper that can be moved
between them. As the wiper moves, the resistance between it and the ends changes — that
is, the resistance drops between the wiper and the end to which it is getting closer.
Figure 2-10. Schematic for a variable resistor
This example puts the analog 1.8 V reference voltage (which appears on P9_32 ) and the
analog ground (which appears on P9_34 ) across the fixed resistor. As the resistor is
turned, the voltage read on the wiper varies from 0 to 1.8 V, which is read by the analog-in
pin on P9_36 .
The flex sensor has no fixed resistor; rather, it has only two terminals whose resistance
across them will vary when it is flexed. In Figure 2-9 , a 22 kΩ resistor is used to form the
circuit needed to get a variable voltage to read.
Search WWH ::




Custom Search