Difference between revisions of "Sensors"

From CCRMA Wiki
Jump to: navigation, search
Line 16: Line 16:
  
 
There are many other types of switches, mechanical, electrical (transistors, photo-transistors ...), and combinations of the two (solenoids ...).
 
There are many other types of switches, mechanical, electrical (transistors, photo-transistors ...), and combinations of the two (solenoids ...).
 
 
 
Contents
 
 
    * Pushbuttons and Switches
 
    * Potentiometers
 
    * Optical/IR sensors
 
    * Quadrature Encoders
 
    * Bend Sensors
 
    * Accelerometers
 
    * Capacitive Sensing
 
    * References
 
 
PushButtons and Switches
 
 
Buttons are the simplest group of discrete sensors. They act as a valve, opening or closing the flow of electrons through a branch of your circuit.
 
 
Buttons can be interfaced directly to a microcontroller's digital input requiring only a pull-up resistor.
 
 
Button nomenclature:
 
 
    * SPDT - Single Pole, Double Throw. Has three contacts, signal of interest would normally go in the middle and is connected to one of the two other contact depending on the switch position.
 
    * DPDT - Double Pole, Double Throw. Has the same structure as the SPST but with a second set of contact so two signal can be switched together.
 
    * Normally Open - The contacts are connected only while the button is actuated. aka. Momentary Contact
 
    * Normally Closed - The contacts are connected except while the button is actuated.
 
    * Toggle - Toggles between closed and open with each actuation
 
 
      There are many other types of switches, mechanical, electrical (transistors, photo-transistors ...), and combinations of the two (solenoids ...).
 
 
 
<top>
 
  
  
Line 58: Line 27:
  
 
* '''trim pot''' - A small potentiometer often used for calibrating a circuit. It usually requires a screw driver to turn and is intended to be set and left alone.
 
* '''trim pot''' - A small potentiometer often used for calibrating a circuit. It usually requires a screw driver to turn and is intended to be set and left alone.
* turns - Some pots cover their range of resistance with only one turn while other can take ten or more turns. The multi-turn pots afford greater precision, but normally cost more and obviously take longer to turn!
+
* '''turns''' - Some pots cover their range of resistance with only one turn while other can take ten or more turns. The multi-turn pots afford greater precision, but normally cost more and obviously take longer to turn!
* taper - The "taper" of a pot refers to the curve formed by plotting the rotation (for a rotary pot) or displacement (for a slide pot) on the X-axis and resistance between the pin 1 and the wiper (R1 above) on the Y-axis. A "linear" taper would have a straight line, such that at 180 degrees rotation, the resistance is half of the total resistance. In "Logarithmic" (or "Log" or  "Audio") taper pots the resistance changes logarithmically with rotation. These pots are commonly used in analog audio mixers because humans perceve logarithmic changes in loudness roughly linearly.
+
* '''taper''' - The "taper" of a pot refers to the curve formed by plotting the rotation (for a rotary pot) or displacement (for a slide pot) on the X-axis and resistance between the pin 1 and the wiper (R1 above) on the Y-axis. A "linear" taper would have a straight line, such that at 180 degrees rotation, the resistance is half of the total resistance. In "Logarithmic" (or "Log" or  "Audio") taper pots the resistance changes logarithmically with rotation. These pots are commonly used in analog audio mixers because humans perceve logarithmic changes in loudness roughly linearly.

Revision as of 15:44, 24 June 2007

PushButtons and Switches

Switches are the simplest group of discrete sensors. They act as a valve, opening or closing the flow of electrons through a branch of your circuit.

Button led.png

Switches can be interfaced directly to a microcontroller's digital input requiring only a pull-up resistor.

Switch nomenclature:

  • SPDT - Single Pole, Double Throw. Has three contacts, signal of interest would normally go in the middle and is connected to one of the two other contact depending on the switch position.
  • DPDT - Double Pole, Double Throw. Has the same structure as the SPST but with a second set of contact so two signal can be switched together.
  • Normally Open - The contacts are connected only while the button is actuated. aka. Momentary Contact
  • Normally Closed - The contacts are connected except while the button is actuated.
  • Toggle - Toggles between closed and open with each actuation

There are many other types of switches, mechanical, electrical (transistors, photo-transistors ...), and combinations of the two (solenoids ...).


Potentiometers

Potentiometers (Pots) are the simplest group of continuous sensors. A potentiometer is a special resistor with a third movable contact, called a wiper. A pot has a fixed resistance from one end to the other as does a normal resistor, but the resistance between the wiper and the ends changes as the wiper is moved (one gets smaller as the other gets larger - the always add up to the fixed resistance between the fixed ends). For rotary pots, the wiper moves as the shaft turns. For linear or slide pots, the wiper moves with the slider.

A potentiometer is normally interfaced to a microcontroller by digitizing the voltage found across it using an ADC( Analog to digital converter ). An alternate method for determining the value of a potentiometer is to place it in an RC circuit and measure the decay time

Potentiometer nomenclature:

  • trim pot - A small potentiometer often used for calibrating a circuit. It usually requires a screw driver to turn and is intended to be set and left alone.
  • turns - Some pots cover their range of resistance with only one turn while other can take ten or more turns. The multi-turn pots afford greater precision, but normally cost more and obviously take longer to turn!
  • taper - The "taper" of a pot refers to the curve formed by plotting the rotation (for a rotary pot) or displacement (for a slide pot) on the X-axis and resistance between the pin 1 and the wiper (R1 above) on the Y-axis. A "linear" taper would have a straight line, such that at 180 degrees rotation, the resistance is half of the total resistance. In "Logarithmic" (or "Log" or "Audio") taper pots the resistance changes logarithmically with rotation. These pots are commonly used in analog audio mixers because humans perceve logarithmic changes in loudness roughly linearly.