Introduction:
The goal of this exercise is to get the external sensor hardware set up properly for the first software exercise. For those of you that have experience with electronics and hardware, this will be extremely easy. For those of you for whom this is your first foray into hardware development, this will also be extremely easy.
You will build a simple voltage divider circuit using your breadboard, bend sensor, 33k resistor and then hook this up to your Sun SPOT by doing the following:
Background information:
According to Wikipedia, a voltage divider is:
General case
A voltage divider referenced to ground is created by connecting two impedances in series, as shown in Figure 1. The input voltage is applied across the series impedances Z1 and Z2 and the output is the voltage across Z2. Z1 and Z2 may be composed of any combination of elements such as resistors, inductors and capacitors.
Applying Ohm's Law, the relationship between the input voltage, Vin, and the output voltage, Vout, can be found:
The transfer function (also known as the divider's voltage ratio) of this circuit is simply:
In general this transfer function is a complex, rational function of frequency.
If you don't understand this, don't worry about it. It works.
Here's a little more about how it works in this case:
The Bend sensor is a resistor. We are also putting another resistor in the circuit. By measuring the difference between the two resistors, we get the amount of bend in the bend sensor. Here's what our circuit will look like when we're done with it:
About Breadboards
A breadboard is a standard prototyping tool used for developing hardware. It allows you to easily make connections between components without soldering, attaching connectors, etc. and is a very useful tool once you understand it.In a typical breadboard the holes of the breadboard are 'connected' underneath to allow you to make connections easily. Different sets of holes are connected to each other in a variety of ways. the underlying connections of the breadboard we will be using are laid out in the following schematic:
The large grid of connections are all interconnected across, and the smaller rows of holes are interconnected.
Install the Resistor and sensor on the bread board:
based on the breadboard schematic above, you will see that the two ends of the resistor will not be connected to one another.
Your Sun SPOT should now look like this:
That completes the hardware development for your Bend Sensor and Sun SPOT.