Hardware Reference
In-Depth Information
Figure 4-10. The photocell and force sensitive resistors act as variable re-
sistors and can be used as analog inputs.
In order to read sensors like these with Galileo's analog input pins, you'll need
to incorporate a voltage divider circuit.
Voltage Divider Circuit
When you're working with sensors that offer variable resistance, the purpose
of a voltage divider is to convert the variable resistance into a variable voltage,
which is what the analog input pins are measuring. First take a look at a simple
voltage divider.
In Figure 4-11 , you'll see two resistors of the same value in series between the
positive and ground and one wire to analog input 0 from between the two
resistors. Since both resistors are 10K ohms, there's 2.5 volts going to analog
input 0.
Search WWH ::




Custom Search