Changes between Version 4 and Version 5 of ControlSystems/Electrical/Training/Arduino/Lesson3


Ignore:
Timestamp:
Sep 28, 2015, 1:45:49 AM (10 years ago)
Author:
David Albert
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ControlSystems/Electrical/Training/Arduino/Lesson3

    v4 v5  
    4444A variable resistor changes its resistance according to some external stimulus (such as turning a knob).  You can make a variable resistor yourself using a pencil.
    4545**Exercise**: draw a line on a piece of paper with a pencil; then go back and forth over it with the pencil **many** times so that you have deposited a great deal of graphite on that line.  Place one lead of your multimeter at one end of the line (touching the graphite) and place the other lead somewhere in the middle of the line; measure the resistance of the graphite between the leads, then slide the lead in the middle closer and further from the other lead and watch the resistance change on the multimeter.
     46[[Image(http://www.criticalvelocity.com/products/pot02_side.jpg, align=right)]]
    4647
    47 A potentiometer is very similar to the resistor you just made.  A potentiometer has three leads: one at either end of the resistor and a lead that connects somewhere between the two based on the position of a mechanical knob.  See this [https://search.yahoo.com/yhs/search?p=Potentiometer+tutorial&ei=UTF-8&hspart=mozilla&hsimp=yhs-001 tutorial]
     48A potentiometer is very similar to the resistor you just made.  Your kit contains a potentiometer with a black knob and three leads: one at either end of the resistor and a lead that connects somewhere between the two based on the position of a mechanical knob.  See this [https://search.yahoo.com/yhs/search?p=Potentiometer+tutorial&ei=UTF-8&hspart=mozilla&hsimp=yhs-001 tutorial]
     49
    4850**Exercise**: measure the resistance between leads of the potentiometer as you turn the knob.
    4951
    5052A common configuration for a potentiometer is to connect the lead at one end to +5V, the lead at the other end to Gnd, and then as the knob is turned, the voltage at the middle lead varies from 0v to 5v.
     53
    5154**Exercise**:connect your potetiometer as described above and measure the voltage at the center lead as you turn the knob.
    5255
    5356Your Arduino computer has analog input pins that can be used to measure a voltage.  See this [https://www.arduino.cc/en/Tutorial/Potentiometer example] and [http://www.instructables.com/id/Arduino-Basics-Using-potentiometers-I-made-it-a/ this one].
     57
    5458**Exercise**:use your Arduino to turn an LED on when the voltage at an analog input pin exceeds a threshold (see above example)
     59
    5560**Exercise**:use your Arduino to vary the blinking speed of an LED based on the position of a potentiometer
    5661