sensors - robotics research and education€¦ · these devices are potentiometer, tachometers,...

85
Sensors

Upload: hoangdat

Post on 02-Apr-2018

226 views

Category:

Documents


5 download

TRANSCRIPT

Page 1: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Sensors

Page 2: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

What is Sensing ?• Collect information about the world• Sensor - an

electrical/mechanical/chemical device that maps an environmental attribute to a quantitative measurement

• Each sensor is based on a transduction principle - conversion of energy from one form to another

Page 3: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Transduction to electronics

• Thermistor: temperature-to-resistance• Electrochemical: chemistry-to-voltage• Photocurrent: light intensity-to-current• Pyroelectric: thermal radiation-to-voltage• Humidity: humidity-to-capacitance• Length (LVDT: Linear variable differential

transformers) : position-to-inductance• Microphone: sound pressure-to-<anything>

Page 4: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Human sensing and organs (Haptic or tactile)

• Vision: eyes (optics, light)• Hearing: ears (acoustics, sound)• Touch: skin (mechanics, heat)• Odor: nose (vapor-phase chemistry)• Taste: tongue (liquid-phase chemistry)

Page 5: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Extended ranges and modalities• Vision outside the RGB spectrum

– Infrared Camera, see at night• Active vision

– Radar and optical (laser) range measurement

• Hearing outside the 20 Hz – 20 kHz range– Ultrasonic range measurement

• Chemical analysis beyond taste and smell

• Radiation: α, β, γ-rays, neutrons, etc

Page 6: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Electromagnetic SpectrumVisible Spectrum

700 nm 400 nm

Page 7: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Sometimes you can substitute sensors to measure other values

• Voltage Regulator acting as a temperature sensor (Models LM234, LM 235)– Manufactured by ST (www.st.com)

• Photo transistor acting as a light sensor (Model LM135)– Manufactured by Fairchild Semiconductors

(www.fairchildsemi.com)

Page 8: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Sensors used in robot navigation• Resistive sensors

– bend sensors, potentiometer, resistive photocells, ...

• Tactile sensors– contact switch, bumpers…

• Infrared sensors – Reflective, proximity, distance sensors…

• Ultrasonic Distance Sensor• Inertial Sensors (measure the second derivatives of position)

– Accelerometer, Gyroscopes,

• Orientation Sensors– Compass, Inclinometer

• Laser range sensors• Vision• Global Positioning SystemMost are inductive, capacity, resistive, ultrasonic or photoelectric

Page 9: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Classification of Sensors• Internal state vs.. external state

i. Internal state sensors - device being used to measure the position, velocity and acceleration of the robot joint and/or end-effector. These devices are potentiometer, tachometers, synchros, resolvers, differential transformers, optical interrupters, optical encoders and accelerometer. Even battery level indicators.

ii. External state sensors – device being used to monitor the relationship between the robot kinematics and/or dynamics with its task, surrounding, or the object being manipulated.

• Active vs.. non-active – emitting energy into the environment, e.g., radar, sonar– passively receive energy to make observation, e.g.,

camera

• Contact vs.. non-contact• Visual vs.. non-visual

– vision-based sensing, image processing, video camera

Page 10: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Sensors used in the CRS LabThe NPN names is referred to the transistor logic that the controller has

Sinking and Sourcing the current.Sinking Example-> 10

Page 11: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Sensor Selection/Sensing Taxonomy• There are many different types of robot sensors

available and there are many different parameter measured by these sensors.

• The application process, should be carried out in a top down manner, starting with task requirements, and going through several levels of analysis, eventually leading to the selection of a specific device.

• A taxonomy for sensing to aid this process consists of five levels of refinement leading to sensor selection:

1. Specification of task requirements :eg localization, slippage detection, size confirmation, inspection, defect testing.

2. Choice of modality :eg,vision, force, tactile3. Specification on sensor attributes :eg,output, complexity,

discrete or continuous variable, imaging or non-imaging, local or global – NPN /PNP

4. Specification of operational parameters :eg size, accuracy, cost5. Selection of mechanism :eg switching devices, inductive

sensors, CCD vision imaging 11

Page 12: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Thermal• temperature sensors: thermometers, thermocouples,

temperature sensitive resistors (thermistors and resistance temperature detectors), bi-metal thermometers and thermostats

• heat sensors: bolometer, calorimeter

Electromagnetic• magnetism sensors: magnetic compass, fluxgate compass,

magnetometer, Hall effect device, • Ex. metal detectors

Mechanical• pressure sensors: altimeter, barometer, barograph, pressure

gauge, air speed indicator, rate of climb indicator• gas and liquid flow sensors: flow sensor, anemometer, flow

meter, gas meter, water meter, mass flow sensor • mechanical sensors: acceleration sensor, position sensor,

inclinometer, switch, strain gauge

Page 13: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

infra-red sensor, especially used as occupancy sensor for lighting and environmental controls.

proximity sensor- A type of distance sensor but less sophisticated. Only detects a specific proximity. May be optical - combination of a photocell and LED or laser. Applications in cell phones, paper detector in photocopiers, auto power standby/shutdown mode in notebooks and other devices. May employ a magnet and a Hall effect device.

Page 14: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Acoustic• sound sensors: microphones, hydrophones,

seismometers.

Quadrature wheel- An disk-shaped optical mask is driven by a gear train. Two photocells detecting light passing through the mask can determine a partial revolution of the mask and the direction of that rotation.

Whisker sensor- A type of touch sensor and proximity sensor. A basic mechanical contraption that acts as a switch.

Page 15: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Considerations• Cost: can this sensor be replaced with cost

effective parts?• Size: depends on space, power requirements• Weight: this can reduce performance, payload

capacity for example if attached to an arm• Type of Output (digital-analog): you may need

ADC or DAC depending on processor• Interfacing: RS232? BlueTooth? WiFi, I2C• Resolution: minimum step size whithin the

range of measurement of the sensor. In a digital sys with n bits, resolution =full range/2^n. Arduino reads 10bit analog signals

Page 16: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

• Sensitivity: ratio of change in output in response to a change in input.

• Linearity: represents relationship between input variations and output variations, i.e.. a change in input produces same change in output. Remember PID?

• Range: difference in smallest and largest output a sensor can produce.

• Response Time: time required for a sensor to reach a certain percentage of the total change.

Considerations

Page 17: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

• Reliability: ratio of how many times a system operates properly/how many times it is used.

• Accuracy: how close the output of the sensor is to the expected value.

Considerations

Page 18: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Output is always Digital

Using a Digital signal that pretends to be an Analog signal is called Pulse Width Modulation

Use Pulse Width Modulation, or P.W.M., for anything that requires a signal between HIGH and LOW

P.W.M. is available on Arduino pins # 3, 5, 6, 9, 10, and 11

Page 19: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Sensors and Components

Name Image Type Function Notes

Button Digital Input Closes or opens circuit

Polarized, needs resistor

Trimpot Analog Input Variable resistor

Photoresistor Analog Input Variable resistor

Relay Digital Output & Input

Switches between circuits

Used to control larger voltages

Temp Sensor Analog Input Variable resistor

Flex Sensor Analog Input Variable resistor Only bends one way

Soft Trimpot Analog Input Variable resistor Careful of shorts

RGB LED Dig. & Analog Output

16,777,216 different colors

Ooh... So pretty.

Page 20: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Bend Sensors• Resistance = 10k to 35k• As the strip is bent, resistance increases

Potentiometers• Can be used as position sensors for sliding mechanisms or rotating shafts • Easy to find, easy to mount

Light Sensor (Photocell)• Good for detecting direction/presence of light • Non-linear resistance• Slow response to light changes

Resistive Sensors

Resistive Bend Sensor

Photocell

Potentiometer

R is small when brightly illuminated

Page 21: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Sensor

Measure bend of a joint

Wall Following/Collision Detection

Weight Sensor

Sensors

Sensor

Applications

Page 22: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Infrared Sensors• Intensity based infrared

– Reflective sensors – Easy to implement– susceptible to ambient light

• Modulated Infrared– Proximity sensors– Requires modulated IR signal– Insensitive to ambient light

• Infrared Ranging– Distance sensors– Short range distance measurement– Impervious to ambient light, color and reflectivity

of object

Page 23: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Intensity Based Infrared

• Easy to implement (few components)• Works very well in controlled environments• Sensitive to ambient light time

volta

getime

volta

ge

Increase in ambient light raises DC bias

Break-Beam sensor

Reflective Sensor

Page 24: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

IR Reflective Sensors• Reflective Sensor:

– Emitter IR LED + detector photodiode/phototransistor– Phototransistor: the more light reaching the phototransistor, the

more current passes through it– A beam of light is reflected off a surface and into a detector– Light usually in infrared spectrum, IR light is invisible

• Applications:– Object detection, – Line following, Wall tracking– Optical encoder (Break-Beam sensor)

• Drawbacks:– Susceptible to ambient lighting

• Provide sheath to insulate the device from outside lighting – Susceptible to reflectivity of objects– Susceptible to the distance between sensor and the object

Page 25: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Modulated Infrared• Modulation and Demodulation

– Flashing a light source at a particular frequency– Demodulator is tuned to the specific frequency of light

flashes. (32kHz~45kHz)– Flashes of light can be detected even if they are very week – Less susceptible to ambient lighting and reflectivity of objects– Used in most IR remote control units, proximity sensors

Negative true logic:

Detect = 0v

No detect = 5v

Page 26: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

IR Proximity Sensors

• Proximity Sensors: – Requires a modulated IR LED, a detector module with built-in

modulation decoder– Current through the IR LED should be limited: adding a series

resistor in LED driver circuit– Detection range: varies with different objects (shiny white card

vs. dull black object)– Insensitive to ambient light

• Applications:– Rough distance measurement – Obstacle avoidance– Wall following, line following

limiter demodulatorbandpass filteramplifier

comparatorintegrator

Page 27: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

IR Distance Sensors• Basic principle of operation:

– IR emitter + focusing lens + position-sensitive detector

Location of the spot on the detector corresponds to the distance to the target surface, Optics to covert horizontal distance to vertical distance

Modulated IR light

Page 28: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

IR Distance Sensors• Sharp GP2D02 IR Ranger

– Distance range: 10cm (4") ~ 80cm (30").– Moderately reliable for distance measurement – Immune to ambient light – Impervious to color and reflectivity of object– Applications: distance measurement, wall

following, …– Lost cost $12-$40

Page 29: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Sharp Infrared Sensors• Analog and Digital with varying distance

measurements• The photo sensors are built with a daylight

filter that prevents most visible light in the environment from reaching the detector chip

Page 30: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

// Code to read Sharp IR sensorint IRpin = 1; // analog pin for reading the IR sensorvoid setup() {Serial.begin(9600); // start

the serial port}void loop() {float volts =

analogRead(IRpin)*0.0048828125; // value from sensor * (5/1024) - if running 3.3.volts then change 5 to 3.3float distance = 65*pow(volts, -1.10);

// worked out from graph 65 = theretical distance / (1/Volts)SSerial.println(distance); // print the distancedelay(100); // arbitary

wait time.}

Page 31: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Triangulation• In trigonometry and geometry, triangulation

is the process of finding coordinates and distance to a point by calculating the length of one side of a triangle, given measurements of angles and sides of the triangle formed by that point and two other known reference points, using the law of sines.

Page 32: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors
Page 33: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Since the output is a voltage you can read it with a voltmeter in mV

Page 34: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors
Page 35: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Navigating with Infrared Headlights

Page 236

Page 237

Page 36: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

• tone(irLedPin, frequency, 8); // IRLED 38 kHz for at least 1 ms

• tone(2, 38000, 8); // IRLED 38 kHz for at least 1 ms

Pulsing the signal out of an IR LED at 38Khz

Page 37: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Range Finder• Time of Flight• The measured pulses typically come form

ultrasonic, RF and optical energy sources.– D = v * t– D = round-trip distance– v = speed of wave propagation– t = elapsed time

• Sound = 0.3 meters/msec• RF/light = 0.3 meters / ns (Very difficult to

measure short distances 1-100 meters)

Page 38: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Ultrasonic Sensors• Basic principle of operation:

– Emit a quick burst of ultrasound (50kHz), (human hearing: 20Hz to 20kHz)

– Measure the elapsed time until the receiver indicates that an echo is detected. Determine how far away the nearest object is from the sensor

D = v * tD = round-trip distancev = speed of propagation(340 m/s)t = elapsed time

Bat, dolphin, …

Page 39: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Ultrasonic Sensors

• Ranging is accurate but bearing has a 30 degree uncertainty. The object can be located anywhere in the arc.

• Typical ranges are of the order of several centimeters to 30 meters.

• Another problem is the propagation time. The ultrasonic signal will take 200 msec to travel 60 meters. ( 30 meters roundtrip @ 340 m/s )

Page 40: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Ultrasonic Sensors• Polaroid ultrasonic ranging system

– It was developed for auto-focus of cameras.– Range: 6 inches to 35 feet

Ultrasonic transducer

Electronic boardTransducer Ringing: transmitter + receiver @

50 KHz Residual vibrations or

ringing may be interpreted as the echo signal

Blanking signal to block any return signals for the first 2.38ms after transmission

http://www.acroname.com/robotics/info/articles/sonar/sonar.html

Page 41: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Ultrasonic Sensors• Applications:

– Distance Measurement– Mapping: Rotating proximity scans (maps the

proximity of objects surrounding the robot)

Page 42: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors
Page 43: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors
Page 44: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Noise Issues

Page 46: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

The HC-SR04 uses sound instead of light as the GP2D12 module does. The HC-SR04 sends a ping as a submarine does and measure the time between sending and receiving anything back when an object is in front of the sensor. Because using sound for its measurements we can reach up to 4 meters. The module is about 45x20x15 mm in size and has a 4 pin connection. Two pins are needed to power the module with 5 Volts. The working current is about 15 mA. One pin is the trigger ping and the last one is used to read the result of the measurements, the echo pin. The measuring angle from the HC-SR04 is 15 degree. At 4 meter distance this should be a beam of about 1 meter. At 1 meter this is 26 cm.

One ping of the HC-SR04 actually consists of 8 pulses at 40 kHz to do the measurement. To start a ping you need to provide a 10us pulse on the trigger input. When the distance is measured by the 8 pulses the HC0SR04 puts a pulse on the echo pin. You can calculate the distance with the length of the echo pulse and the speed of sound. The speed of sound is 340 m/s or 2.9 micro seconds per mm. We have to divide the length of the pulse by 2.9 to get the result in mm. The ping is traveling towards an object and back to the sensor again. Because of this we need to divide the result by two. Between two pings we need to keep a 60ms measurement cycle.

The connection of the HC-SR04 to an Arduino is really straight forward. Just connect the 5 volt and the ground to the outer pins.

Other SR04 specs

Page 47: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors
Page 48: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

The sensor sends a ping at time t1 and receives the bouncing ping

at a time t2.

Δt = t2 - t1 can give us an idea of the distance of an object.

c (speed of sound) = 0.03435 cm/ųs

The distance is therefore, D = (Δt/2) * c or distance=timeXspeed

Example, if Δt = 500 microseconds, we know it took 250 microseconds for the ping to hit an object and another 250 microseconds to come back.

The distance is therefore, D = (Δt/2) * cor D = 250 * 0.03435 = 8.6 cm

5 volt, 15mA, trigger and echo

Page 49: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

int TrigPin = 5;// connect Trigger to pin 5int EchoPin = 6; //connect Echo to pin 6void setup(){

Serial.begin(9600);pinMode(TrigPin,OUTPUT); set pin 5 to be an output signal portpinMode(EchoPin,INPUT); set pin 6 to be an input port

}void loop(){

int distance,duration;digitalWrite(TrigPin,HIGH); //TrigPin prepare high of more than 10usdelayMicroseconds(11);digitalWrite(TrigPin,LOW);duration = pulseIn(EchoPin, HIGH);

//EchoPin received high start counting until the receiver to the low,return to the count valueduration = duration/29/2; //Calculating the distance cm

// The speed of sound is 340 m/s or 29 microseconds per centimeter.Serial.print(duration);//Serial display distanceSerial.print("cm");Serial.println();delay(1000); }

Page 50: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Laser Ranger Finder• Range 2-500 meters• Resolution : 10 mm• Field of view : 100 - 180 degrees• Angular resolution : 0.25 degrees• Scan time : 13 - 40 msec.• These lasers are more immune to Dust and Fog• http://www.youtube.com/watch?v=RN7WkRaOC

uU&feature=relatedhttp://www.sick.de/de/products/categories/safety/

Page 51: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Laser Range Finder

• The Nikon LaserCaddy is a highly compact laser rangefinder that will accurately measure distance from 11 yards to over 500 yards with unparalleled precision

• Nikon’s advanced digital processor and high grade optics.• Laser Range Finder SICK 200 is a very precise laser that

produce high quality map. The drawback of this sensor is the weight (10 pounds !!!) and the power consumption (12V at 1.6A).

Page 52: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Laser range finders are sensors that measure the distance to objects in the closer surrounding by evaluating the time of flight of an emitted laser pulse. The Sick LMS 200 is very common in the robotics community. Its horizontal field of view is 180°, and it can sense objects in distances of up to 40 to 60 meters, depending on the object's reflectivity. There is a rotating mirror inside. Although the horizontal resolution of 1° or .5° is quite large, Sick laser range finders have one important drawback: They can only scan in horizontal dimension, in a plain. A real 3D scanner would be worthwhile, especially in outdoor terrain where the robot moves in 3D. Addition of laser arrays. Robot Vacuum video (mini LIDAR)

Page 53: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

More LIDAR Applications

Page 54: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

• Tactile sensing includes any form of sensing which requires physical touching between the sensor and the object to be sense.

• The need for touch or tactile sensors occurs in many robotic applications, from picking oranges to loading machines. Probably the most important application currently is the general problem of locating, identifying, and organizing parts that need to be assembled.

• Tactile sensor system includes the capability to detect such things as:1. Presence2. Part shape, location, orientation, contour examination3. Contact are pressure and pressure distribution4. Force magnitude, location, and direction5. Surface inspection : texture monitoring, joint checking, damage detection6. Object classification : recognition, discrimination

Gi ifiti ti (li iti itti)

54

Page 55: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Touch Sensors

• Bumper Switches– designed to run into

walls…

• Limit Switches– designed to detect

mechanical arms…

Page 56: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Linear Variable Differential Transformer (LVDT)

• LDVT is a robust and precise device which produce a voltage output proportional to the displacement of a ferrous armature for measurement of robot joints or end-effectors. It is much expensive but outperforms the potentiometer transducer.

Linear Variable Differential Transformer (LVDT)

56

Page 57: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Force & Torque Sensors

• Force can be measured using piezoelectric principle.

• Figure shows a load washer type piezoelectric force transducer. It is designed to measure axial forces. It is preloaded when manufactured and can measure both tensile and compressive forces.

57

Page 58: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Incremental Optical Encoders

- direction

- resolution

grating

light emitter

light sensor

decode circuitry

A

B A leads B

• Incremental Encoder:

• It generates pulses proportional to the rotation speed of the shaft.• Direction can also be indicated with a two phase encoder:

Page 59: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

59

Page 60: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

60

Page 61: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

61

Page 62: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors
Page 63: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors
Page 64: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Absolute Optical Encoders

Gray Code

• Used when loss of reference is not possible.• Gray codes: only one bit changes at a time ( less uncertainty).• The information is transferred in parallel form (many wires are necessary).

000

001

011

010

110

111

101

100

000

001

010

011

100

101

110

111

Binary

Page 65: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

• What is an accelerometer?An accelerometer measures acceleration (change in speed) of anything that it's mounted on. How does it work? Inside an accelerator MEMS (Micro Electro-Mechanical System) device are tiny micro-structures that bend due to momentum and gravity. When it experiences any form of acceleration, these tiny structures bend by an equivalent amount which can be electrically detected.

Page 66: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Accelerometers

• They measure the inertia force generated when a mass is affected by a change in velocity.

• This force may change – The tension of a string – The deflection of a beam – The vibrating frequency of a mass

Page 67: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Accelerometers

• Measure acceleration • Typically used to measure

the tilt of a robot.

Page 68: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Accelerometer• Main elements of an accelerometer: 1. Mass 2. Suspension mechanism 3. Sensing element

High quality accelerometers include a servo loop to improve the linearity of the sensor.

kxdtdxc

tdxdmF ++= 2

2

Page 69: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Typical Specs for Accelerometers• Product Description• The DE-ACCM3D is the most advanced analog accelerometer

solution to date, featuring a triple axis ±3g accelerometer chip. It also has integrated op amp buffers for direct connection to a microcontroller's analog inputs, or for driving heavier loads.

• The ACCM3D has an onboard 3.3V LDO regulator, allowing you to power the board with 3.5V to 15V sources. You can also use this regulator to power an external microcontroller with up to 50mA. For operation as low as 2.0V, you can bypass the voltage regulator and choose your own operating voltage.

• It is designed to fit in the DIP-16 form factor, making the DE-ACCM3D suitable for breadboarding, perfboarding, and insertion into standard chip sockets. To keep things as simple as possible, there are only 5 pins - two for power, and three for the X, Y and Z analog outputs.

Additional circuitry ensures that the product won't be damaged by reversed power connections.

Page 70: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

• Possible uses for accelerometers in robotics:

• Self balancing robots • Tilt-mode game controllers • Model airplane auto pilot • Alarm systems • Collision detection • Human motion monitoring • Leveling sensor, inclinometer • Vibration Detectors for Vibration Isolators • G-Force Detectors • iPad• iPhone• Smart phones• Car automatic active suspension systems

Page 71: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

accelerometer

Two sensors in one <– gyroscope and accelerometer in one board

Page 73: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

const int groundpin = 18; // analog input pin 4 -- groundconst int powerpin = 19; // analog input pin 5 -- voltageconst int xpin = A3; // x-axis of the accelerometerconst int ypin = A2; // y-axisconst int zpin = A1; // z-axis (only on 3-axis models)void setup(){

// initialize the serial communications:Serial.begin(9600);

pinMode(groundpin, OUTPUT);pinMode(powerpin, OUTPUT);digitalWrite(groundpin, LOW); digitalWrite(powerpin, HIGH);

}

void loop(){

// print the sensor values:Serial.print(analogRead(xpin));

Serial.print("\t");Serial.print(analogRead(ypin));

Serial.print("\t");Serial.print(analogRead(zpin));Serial.println();// delay before next reading:delay(100); }

Arduino code to read values from an analog accelerometer

Page 74: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

GyroscopeA rotating wheel whose axis is free to turn but maintains a fixed direction unless perturbed. Used for stabilization or with the compass in an aircraft, ship, etc. Concise Oxford Dictionary Oxford University Press

Info- Outputs voltage corresponding to degrees /sec- Small voltages can cause interference and

drift effect- These devices return a signal proportional to the

rotational velocity.

Uses:- Accuracy in navigation- Better turns and straight line navigation- When combined with cameras and other

sensor sit can help with dead reckoning

Page 75: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

• A gyroscope in operation with freedom in all three axes. The rotor will maintain its spin axis direction regardless of the orientation of the outer frame.

Page 76: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Gyroscope connected to Arduino

Page 77: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Global Positioning System (GPS)

http://www.cnde.iastate.edu/staff/swormley/gps/gps.html

24 satellites (+several spares)

broadcast time, identity, orbital parameters (latitude, longitude, altitude)

Page 78: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

GPS connected to Arduino

int rxPin = 0; // RX PIN int txPin = 1; // TX TX Serial.println("---------------");

for (int i=0;i<12;i++){switch(i){

case 0 :Serial.print("Time in UTC (HhMmSs): ");break;case 1 :Serial.print("Status (A=OK,V=KO): ");break;case 2 :Serial.print("Latitude: ");break;case 3 :Serial.print("Direction (N/S): ");break;case 4 :Serial.print("Longitude: ");break;case 5 :Serial.print("Direction (E/W): ");break;case 6 :Serial.print("Velocity in knots: ");break;case 7 :Serial.print("Heading in degrees: ");break;case 8 :Serial.print("Date UTC (DdMmAa): ");break;case 9 :Serial.print("Magnetic degrees: ");break;case 10 :Serial.print("(E/W): ");break;case 11 :Serial.print("Mode: ");break;case 12 :Serial.print("Checksum: ");break;

78

Page 79: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Sparkfun’s Gesture (swipe) sensor

Arduino connectivity

Show Robots MIP and Dog

79

Page 80: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Tests the gesture sensing abilities of the APDS-9960. ConfiguresAPDS-9960 over I2C and waits for gesture events. Calculates thedirection of the swipe (up, down, left, right) and displays iton a serial console. To perform a NEAR gesture, hold your hand far above the sensor and move it close to the sensor (within 2 inches). Hold your hand there for at least 1 second and move itaway.To perform a FAR gesture, hold your hand within 2 inches of thesensor for at least 1 second and then move it above (out ofrange) of the sensor.Hardware Connections:IMPORTANT: The APDS-9960 can only accept 3.3V!Arduino Pin APDS-9960 Board Function

3.3V VCC PowerGND GND GroundA4 SDA I2C DataA5 SCL I2C Clock2 INT InterruptResources:Include Wire.h and SparkFun_APDS-9960.hDevelopment environment specifics:Written in Arduino 1.0.5Tested with SparkFun Arduino Pro Mini 3.3VThis code is beerware; if you see me (or any other SparkFunemployee) at the local, and you've found our code helpful, pleasebuy us a round!

80

Page 81: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

#include <Wire.h>#include <SparkFun_APDS9960.h>// Pins#define APDS9960_INT 2 // Needs to be an interrupt pin// Constants// Global VariablesSparkFun_APDS9960 apds = SparkFun_APDS9960();int isr_flag = 0;

void setup() {// Initialize Serial portSerial.begin(9600);Serial.println();

Serial.println(F("SparkFun APDS-9960 - GestureTest"));

// Initialize interrupt service routineattachInterrupt(0, interruptRoutine, FALLING);

// Initialize APDS-9960 (configure I2C and initial values)if ( apds.init() ) {

Serial.println(F("APDS-9960 initialization complete"));} else {

Serial.println(F("Something went wrong during APDS-9960 init!"));}// Start running the APDS-9960 gesture sensor engineif ( apds.enableGestureSensor(true) ) {Serial.println(F("Gesture sensor is now running"));

} else {Serial.println(F("Something went wrong during gesture sensor init!"));

} }81

Page 82: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

void loop() {if( isr_flag == 1 ) {

handleGesture();isr_flag = 0;

} }

void interruptRoutine() {isr_flag = 1; }

void handleGesture() {if ( apds.isGestureAvailable() ) {switch ( apds.readGesture() ) {case DIR_UP:

Serial.println("UP");break;

case DIR_DOWN:Serial.println("DOWN");break;

case DIR_LEFT:Serial.println("LEFT");break;

case DIR_RIGHT:Serial.println("RIGHT");break;

case DIR_NEAR:Serial.println("NEAR");break;

case DIR_FAR:Serial.println("FAR");break;

default:Serial.println("NONE"); } } }

82

Page 83: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Noise Issues

• Real sensors are noisy• Origins: natural phenomena + less-than-

ideal engineering• Consequences: limited accuracy and

precision of measurements• Filtering:

– software: averaging, signal processing algorithm

– hardware tricky: capacitor/filtering

Page 84: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors
Page 85: Sensors - Robotics Research and Education€¦ · These devices are potentiometer, tachometers, synchros, ... magnetometer, Hall effect device, ... • Can be used as position sensors

Industrial Torque Sensors