Topics: Introduction to Robotics CS 491/691(X) Lecture 5 Instructor: Monica Nicolescu.

Slides:



Advertisements
Similar presentations
P3 Revision. How do forces have a turning effect? The turning effect of a force is called the moment. Distance from force to pivot – perpendicular to.
Advertisements

November 12, 2013Computer Vision Lecture 12: Texture 1Signature Another popular method of representing shape is called the signature. In order to compute.
Add and Use a Sensor & Autonomous For FIRST Robotics
Rotary Encoder. Wikipedia- Definition  A rotary encoder, also called a shaft encoder, is an electro- mechanical device that converts the angular position.
We deal with voltage signals Sensors convert environment data to electrical signals Output: Voltage Input: Time/Distance/Whatever Move Receiver around.
Tachometers – An Overview
April 3, What we call “light” is merely a small fraction of the total electromagnetic spectrum. The electromagnetic spectrum Consists of transverse.
Sensors For Robotics Robotics Academy All Rights Reserved.
Last time we saw: DC motors – inefficiencies, operating voltage and current, stall voltage and current and torque – current and work of a motor Gearing.
Autonomous Mobile Robots CPE 470/670 Lecture 5 Instructor: Monica Nicolescu.
December 5, 2013Computer Vision Lecture 20: Hidden Markov Models/Depth 1 Stereo Vision Due to the limited resolution of images, increasing the baseline.
Introduction to Control: How Its Done In Robotics R. Lindeke, Ph. D. ME 4135.
Topics: Introduction to Robotics CS 491/691(X)
Topics: Introduction to Robotics CS 491/691(X) Lecture 6 Instructor: Monica Nicolescu.
Autonomous Mobile Robots CPE 470/670 Lecture 4 Instructor: Monica Nicolescu.
Autonomous Mobile Robots CPE 470/670 Lecture 5 Instructor: Monica Nicolescu.
Autonomous Mobile Robots CPE 470/670 Lecture 6 Instructor: Monica Nicolescu.
Autonomous Mobile Robots CPE 470/670
CS274 Spring 01 Lecture 5 Copyright © Mark Meyer Lecture V Higher Level Motion Control CS274: Computer Animation and Simulation.
Basics of Sensors. A sensor is a device which is used to sense the surroundings of it & gives some useful information about it. This information is used.
Vision Our most dominant sense
N.B. Please register for the course with the ITO Please attend a practical in the coming week: –Either 10:00, 13:05 Tuesday –Or 10:00, 13:05 Friday If.
Sensors Chris Davidson Ari Kapusta Optical Encoders and Linear Variable Differential Transformers.
Applied Control Systems Robotics & Robotic Control
1 Perception, Illusion and VR HNRS 299, Spring 2008 Lecture 19 Other Graphics Considerations Review.
Sensors. Sensors are for Perception Sensors are physical devices that measure physical quantities. – Such as light, temperature, pressure – Proprioception.
Juhana Leiwo – Marco Torti.  Position and movement  Direction of acceleration (gravity) ‏  Proximity and collision sensing  3-dimensional spatial.
Sensing self motion Key points: Why robots need self-sensing Sensors for proprioception in biological systems in robot systems Position sensing Velocity.
Programming Concepts Part B Ping Hsu. Functions A function is a way to organize the program so that: – frequently used sets of instructions or – a set.
A Mathematical Analysis of a Sun Tracking Circuit for Photovoltaic Systems Dr. S. Louvros and Prof. S. Kaplanis T.E.I. of Patra, Greece.
Robotica Lecture 3. 2 Robot Control Robot control is the mean by which the sensing and action of a robot are coordinated The infinitely many possible.
Programming Concepts (Part B) ENGR 10 Introduction to Engineering 1 Hsu/Youssefi.
Perception Introduction Pattern Recognition Image Formation
CS-424 Gregory Dudek Today’s Lecture Computational Vision –Images –Image formation in brief (+reading) –Image processing: filtering Linear filters Non-linear.
Brief Review of Control Theory
December 4, 2014Computer Vision Lecture 22: Depth 1 Stereo Vision Comparing the similar triangles PMC l and p l LC l, we get: Similarly, for PNC r and.
Robotica Lecture 3. 2 Robot Control Robot control is the mean by which the sensing and action of a robot are coordinated The infinitely many possible.
Robot sensors MVRT 2010 – 2011 season. Analog versus Digital Analog Goes from 0 to 254 Numerous values Similar to making waves because there are not sudden.
CS 478: Microcontroller Systems University of Wisconsin-Eau Claire Dan Ernst Feedback Control.
1 Perception, Illusion and VR HNRS 299, Spring 2008 Lecture 2 Introduction, Light Course webpage:
Intelligent Vision Systems Image Geometry and Acquisition ENT 496 Ms. HEMA C.R. Lecture 2.
Autonomous Mobile Robots CPE 470/670 Lecture 6 Instructor: Monica Nicolescu.
December 9, 2014Computer Vision Lecture 23: Motion Analysis 1 Now we will talk about… Motion Analysis.
Low Level Control. Control System Components The main components of a control system are The plant, or the process that is being controlled The controller,
University of Windsor School of Computer Science Topics in Artificial Intelligence Fall 2008 Sept 11, 2008.
Autonomous Robots Vision © Manfred Huber 2014.
PHY 235 Robotics Workshop Day 5 Distance Sensing Using The Ultrasonic Ping Sensor.
Light. Photon is a bundle of light related to the amount of energy Light travels in straight line paths called light rays
Colour and Texture. Extract 3-D information Using Vision Extract 3-D information for performing certain tasks such as manipulation, navigation, and recognition.
1Ellen L. Walker 3D Vision Why? The world is 3D Not all useful information is readily available in 2D Why so hard? “Inverse problem”: one image = many.
Intelligent Vision Systems Image Geometry and Acquisition ENT 496 Ms. HEMA C.R. Lecture 2.
Instructor: Mircea Nicolescu Lecture 5 CS 485 / 685 Computer Vision.
1 Computational Vision CSCI 363, Fall 2012 Lecture 2 Introduction to Vision Science.
I NTRODUCTION TO R OBOTICS Basics of Sensors Md. Khalilur Rhaman Lec Reff.: Dr. M. Rokonuzzaman 1.
Vision Our most dominant sense. Our Essential Questions What are the major parts of the eye? How does the eye translate light into neural impulses?
Physics: light waves. Properties and Sources of Light Key Question: What are some useful properties of light?
Introduction to Robots and the Mind - Sensors - Bert Wachsmuth & Michael Vigorito Seton Hall University.
Robot Control. Open Loop Control Sends commands to make a robot preform some movement without attempting to check if it is doing things properly. For.
Programming & Sensors.
Light.
Sensors For Robotics Robotics Academy All Rights Reserved.
Sensors For Robotics Robotics Academy All Rights Reserved.
Pulse Width Modulation (PWM) Motor Feedback - Shaft Encoder
Programming Concepts (Part B) ENGR 10 Introduction to Engineering
Common Classification Tasks
Day 32 Range Sensor Models 11/13/2018.
Range Imaging Through Triangulation
Distance Sensor Models
Experiencing the World
Programming Concepts (Part B) ENGR 10 Introduction to Engineering
Presentation transcript:

Topics: Introduction to Robotics CS 491/691(X) Lecture 5 Instructor: Monica Nicolescu

CS 491/691(X) - Lecture 52 Review

CS 491/691(X) - Lecture 53 Ambient light Ambient / background light can interfere with the sensor measurement To correct it we need to subtract the ambient light level from the sensor measurement This is how: –take two (or more, for increased accuracy) readings of the detector, one with the emitter on, one with it off, –then subtract them The result is the ambient light level

CS 491/691(X) - Lecture 54 Calibration The ambient light level should be subtracted to get only the emitter light level Calibration: the process of adjusting a mechanism so as to maximize its performance Ambient light can change  sensors need to be calibrated repeatedly Detecting ambient light is difficult if the emitter has the same wavelength –Adjust the wavelength of the emitter

CS 491/691(X) - Lecture 55 Infra Red (IR) Light IR light works at a frequency different than ambient light IR sensors are used in the same ways as the visible light sensors, but more robustly –Detect presence of objects and distance to objects Sensor reports the amount of overall illumination, –ambient lighting and the light from light source More powerful way to use infrared sensing –Modulation/demodulation : rapidly turn on and off the source of light

CS 491/691(X) - Lecture 56 Modulation/Demodulation Modulated IR is commonly used for communication Modulation is done by flashing the light source at a particular frequency This signal is detected by a demodulator tuned to that particular frequency Offers great insensitivity to ambient light –Flashes of light can be detected even if weak

CS 491/691(X) - Lecture 57 Infrared Communication Bit frames –All bits take the same amount of time to transmit –Sample the signal in the middle of the bit frame –Used for standard computer/modem communication –Useful when the waveform can be reliably transmitted Bit intervals –Sampled at the falling edge –Duration of interval between sampling determines whether it is a 0 or 1 –Common in commercial use –Useful when it is difficult to control the exact shape of the waveform

CS 491/691(X) - Lecture 58 Proximity Sensing Ideal application for modulated/demodulated IR light sensing Light from the emitter is reflected back into detector by a nearby object, indicating whether an object is present –LED emitter and detector are pointed in the same direction Modulated light is far less susceptible to environmental variables –amount of ambient light and the reflectivity of different objects

CS 491/691(X) - Lecture 59 Break Beam Sensors Any pair of compatible emitter-detector devices can be used to make a break-beam sensor Examples: –Incadescent flashlight bulb and photocell –Red LEDs and visible-light-sensitive photo- transistors –IR emitters and detectors Where have you seen these? –Laser beams and clever burglars in movies –In robotics they are mostly used for keeping track of shaft rotation

CS 491/691(X) - Lecture 510 Shaft Encoding Shaft encoders –Measure the angular rotation of a shaft or an axle Provide position and velocity information about the shaft Speedometers: measure how fast the wheels are turning Odometers: measure the number of rotations of the wheels

CS 491/691(X) - Lecture 511 Measuring Rotation A perforated disk is mounted on the shaft An emitter–detector pair is placed on both sides of the disk As the shaft rotates, the holes in the disk interrupt the light beam These light pulses are counted thus monitoring the rotation of the shaft The more notches, the higher the resolution of the encoder –One notch, only complete rotations can be counted

CS 491/691(X) - Lecture 512 Color-Based Encoders Paint the disk wedges in alternating contrasting colors Use a reflectance sensors to count the rotations Black wedges absorb light, white reflect it and only reflections are counted

CS 491/691(X) - Lecture 513 General Encoder Properties Encoders are active sensors Produce and measure a wave function of light intensity The wave peaks are counted to compute the speed of the shaft Encoders measure rotational velocity and position Where can encoders be used?

CS 491/691(X) - Lecture 514 Uses of Encoders Velocity can be measured –at a driven (active) wheel –at a passive wheel (e.g., dragged behind a legged robot) By combining position and velocity information, one can: –move in a straight line –rotate by a fixed angle Can be difficult due to wheel and gear slippage and to backlash in geartrains

CS 491/691(X) - Lecture 515 Quadrature Shaft Encoding How can we measure direction of rotation? Idea: –Use two encoders instead of one –Align sensors to be 90 degrees out of phase –Compare the outputs of both sensors at each time step with the previous time step –Only one sensor changes state (on/off) at each time step, based on the direction of the shaft rotation  this determines the direction of rotation –A counter is incremented in the encoder that was on

CS 491/691(X) - Lecture 516 Which Direction is the Shaft Moving? Encoder A = 1 and Encoder B = 0 –If moving to position AB=00, the position count is incremented –If moving to the position AB=11, the position count is decremented State transition table: Previous state = current state  no change in position Single-bit change  incrementing / decrementing the count Double-bit change  illegal transition

CS 491/691(X) - Lecture 517 Uses of QSE in Robotics Robot arms with complex joints –e.g., rotary/ball joints like knees or shoulders Cartesian robots, overhead cranes –The rotation of a long worm screw moves an arm/rack back and fort along an axis Motion of robot wheels –Dead-reckoning positioning Copy machines, printers Elevators

CS 491/691(X) - Lecture 518 Ultrasonic Distance Sensing Sonars: so (und) na (vigation) r (anging) Based on the time-of-flight principle The emitter sends a “chirp” of sound If the sound encounters a barrier it reflects back to the sensor The reflection is detected by a receiver circuit, tuned to the frequency of the emitter Distance to objects can be computed by measuring the elapsed time between the chirp and the echo Sound travels about 0.89 milliseconds per foot

CS 491/691(X) - Lecture 519 Sonar Sensors Emitter is a membrane that transforms mechanical energy into a “ping” (inaudible sound wave) The receiver is a microphone tuned to the frequency of the emitted sound Polaroid Ultrasound Sensor –Used in a camera to measure the distance from the camera to the subject for auto-focus system –Emits in a 30 degree sound cone –Has a range of 32 feet –Operates at 50 KHz

CS 491/691(X) - Lecture 520 Echolocation Echolocation = finding location based on sonar Numerous animals use echolocation Bats use sound for: –finding pray, avoid obstacles, find mates, communication with other bats Dolphins/Whales: find small fish, swim through mazes Natural sensors are much more complex than artificial ones

CS 491/691(X) - Lecture 521 Specular Reflection Sound does not reflect directly and come right back Specular reflection –The sound wave bounces off multiple sources before returning to the detector Smoothness –The smoother the surface the more likely is that the sound would bounce off Incident angle –The smaller the incident angle of the sound wave the higher the probability that the sound will bounce off

CS 491/691(X) - Lecture 522 Improving Accuracy Use rough surfaces in lab environments Multiple sensors covering the same area Multiple readings over time to detect “discontinuities” Active sensing In spite of these problems sonars are used successfully in robotics applications –Navigation –Mapping

CS 491/691(X) - Lecture 523 Laser Sensing High accuracy sensors Lasers use light time-of-flight Light is emitted in a beam (3mm) rather than a cone Provide higher resolution For small distances light travels faster than it can be measured  use phase-shift measurement SIC LMS200 –360 readings over an 180-degrees, 10Hz Disadvantages: cost, weight, power, price, mostly 2D

CS 491/691(X) - Lecture 524 Visual Sensing Cameras try to model biological eyes Machine vision is a highly difficult research area –Reconstruction –What is that? Who is that? Where is that? Robotics requires answers related to achieving goals –Not usually necessary to reconstruct the entire world

CS 491/691(X) - Lecture 525 Principles of Cameras Cameras have many similarities with the human eye –The light goes through an opening ( iris - lens ) and hits the image plane ( retina ) –The retina is attached to light-sensitive elements ( rods, cones – silicon circuits ) –Only objects at a particular range are in focus ( fovea ) – depth of field –512x512 pixels ( cameras ), 120x10 6 rods and 6x10 6 cones ( eye ) –The brightness is proportional to the amount of light reflected from the objects

CS 491/691(X) - Lecture 526 Image Brightness Brightness depends on –reflectance of the surface patch –position and distribution of the light sources in the environment –amount of light reflected from other objects in the scene onto the surface patch Two types of reflection –Specular (smooth surfaces) –Diffuse (rough sourfaces) Necessary to account for these properties for correct object reconstruction  complex computation

CS 491/691(X) - Lecture 527 Early Vision The retina is attached to numerous rods and cones which, in turn, are attached to nerve cells ( neurons ) The nerves process the information; they perform "early vision", and pass information on throughout the brain to do "higher-level" vision processing Suppose we have a b&w camera with a 512 x 512 pixel image Each pixel has an intensity level between white and black How do we find an object in the image? Do we know if there is one? The typical first step ("early vision") is edge detection, i.e., find all the edges in the image

CS 491/691(X) - Lecture 528 Edge Detection Edge = a curve in the image across which there is a change in brightness Finding edges –Differentiate the image and look for areas where the magnitude of the derivative is large Difficulties –Not only edges produce changes in brightness: shadows, noise Smoothing –Filter the image using convolution –Use filters of various orientations Segmentation: get objects out of the lines

CS 491/691(X) - Lecture 529 Model-Based Vision Compare the current image with images of similar objects ( models ) stored in memory Models provide prior information about the objects Difficulties –Translation, orientation and scale –Not known what is the object in the image –Occlusion Storing models –Line drawings –Several views of the same object –Repeatable features (two eyes, a nose, a mouth)

CS 491/691(X) - Lecture 530 Vision from Motion Take advantage of motion to facilitate vision Moving system can detect static objects –At consecutive time steps continuous objects move as one –Subtract two consecutive images from each other  the movement between frames –Exact movement of the camera should be known Robots are typically moving themselves –Need to consider the movement of the robot

CS 491/691(X) - Lecture 531 Stereo Vision 3D information can be computed from two images Compute relative positions of cameras Compute disparity –displacement of a point in 3D between the two images Disparity is inverse proportional with actual distance in 3D

CS 491/691(X) - Lecture 532 Biological Vision Similar visual strategies are used in nature Model-based vision is essential for object/people recognition Vestibular occular reflex –Eyes stay fixed while the head/body is moving to stabilize the image Stereo vision –Typical in carnivores Human vision is particularly good at recognizing shadows, textures, contours, other shapes

CS 491/691(X) - Lecture 533 Vision for Robots If complete scene reconstruction is not needed we can simplify the problem based on the task requirements Use color Use a combination of color and movement Use small images Combine other sensors with vision Use knowledge about the environment

CS 491/691(X) - Lecture 534 Feedback Control Feedback control = having a system achieve and maintain a desired state by continuously comparing its current and desired states, then adjusting the current state to minimize the difference Also called closed loop control

CS 491/691(X) - Lecture 535 Goal State Goal driven behavior is used in both control theory and in AI Goals in AI –Achievement goals: states that the system is trying to reach –Maintenance goals: states that need to be maintained Control theory: mostly focused on maintenance goals Goal states can be: –Internal : monitor battery power level –External : get to a particular location in the environment –Combinations of both: balance a pole

CS 491/691(X) - Lecture 536 Error Error = the difference in the current state and desired state of the system The controller has to minimize the error at all times Zero/non-zero error: –Tells whether there is an error or not –The least information we could have Magnitude of error: –The distance to the goal state Direction of error: –Which way to go to minimize the error Control is much easier if we know both magnitude and direction

CS 491/691(X) - Lecture 537 A Robotic Example Use feedback to design a wall following robot What sensors to use, what info will they provide? –Contact: the least information –IR: information about a possible wall, but not distance –Sonar, laser: would provide distance –Bend sensor: would provide distance Control If distance-to-wall is right, then keep going If distance-to-wall is larger then turn (by 45 degrees) toward the wall else turn (by 45 degrees) away from the wall

CS 491/691(X) - Lecture 538 Oscillations What is the behavior of the robot? The robot will oscillate around the optimal distance from the wall, getting either too close or too far In general, the behavior of a feedback system oscillates around the desired state Decreasing oscillations –Adjust the turning angle –Use a range instead of a fixed distance as the goal state

CS 491/691(X) - Lecture 539 Open Loop Control Also called feed-forward control Does not use sensory feedback, and state is not fed back into the system The system executes a command that is fed into it, based on what was predicted in advance –The controller determines set points (sub-goals) ahead of time Feed-forward systems are effective only if –They are well calibrated –The environment is predictable & does not change such as to affect their performance

CS 491/691(X) - Lecture 540 Uses of Open Loop Control Repetitive, state independent tasks Conveyor belt machines use open loop control Biological systems use it as well, in various movements These are called ballistic movements (like a flying bullet) Ballistic movements cannot be corrected while they are executed E.g.: pouncing, reflex reaching & withdrawal, etc.

CS 491/691(X) - Lecture 541 Types of Feedback Control There are three types of basic feedback controllers P: proportional control PD: proportional derivative control PID: proportional integral derivative control

CS 491/691(X) - Lecture 542 Proportional Control The response of the system is proportional to the amount of the error Use both direction and magnitude of error to compensate for the error effectively The output o is proportional to the input i: o = K p  i K p is a proportionality constant (gain) Turn sharply toward the wall sharply if far from it, Turn gently toward the wall if slightly farther from it

CS 491/691(X) - Lecture 543 Gains The gains (K p ) are specific to the particular control system –The physical properties of the system directly affect the gain values – E.g.: the velocity profile of a motor (how fast it can accelerate and decelerate), the backlash and friction in the gears, the friction on the surface, in the air, etc. – All of these influence what the system actually does in response to a command

CS 491/691(X) - Lecture 544 Determining Gains How do we determine the gains? Analytically (mathematics): –require that the system be well understood and characterized mathematically Empirically (trial and error): –require that the system be tested extensively Automatically –by trying different values at run-time

CS 491/691(X) - Lecture 545 Gains and Oscillations Proportional gain = value proportional to that of the error Incorrect gains will cause the system to undershoot or overshoot the desired state  oscillations Gain values determine if: –The system will keep oscillating (possibly increasing oscillations) –The system will stabilize Damping: process of systematically decreasing oscillations A system is properly damped if it does not oscillate out of control ( decreasing oscillations, or no oscillations at all )

CS 491/691(X) - Lecture 546 Proportional Control P gain =10: –System overshot the zero point, and had to turn around –Offset Error: System did not stabilize at the goal. Power command too small to activate the motor P gain =20: should ameliorate the offset problem –Offset error is solved –Oscillation: the system overshoots three times—twice beyond the setpoint and once before it P gain = 10 P gain = 20

CS 491/691(X) - Lecture 547 Proportional Control P gain =30: –Oscillation problem is more pronounced; there are a total of five oscillatory swings P gain =50: Oscillation behavior has taken over –System cannot stabilize at the setpoint –A small error generates a power command that moves the system across the setpoint P gain = 30 P gain = 50

CS 491/691(X) - Lecture 548 Derivative Control Setting gains is difficult, and simply increasing the gains does not remove oscillations The system needs to be controlled differently when it is close to the desired state and when it is far from it Otherwise, the momentum of the correction carries the system beyond the desired state, and causes oscillations Solution: correct the momentum as the system approaches the desired state Momentum = mass  velocity

CS 491/691(X) - Lecture 549 Controlling Velocity Momentum and velocity are directly proportional  we can control the momentum by controlling velocity As the system nears the desired state, we subtract an amount proportional to the velocity: - (gain  velocity) This is called the derivative term, because velocity is the derivative of position A controller that has a derivative term is called a derivative (D) controller

CS 491/691(X) - Lecture 550 Derivative Control A derivative controller has an output o proportional to the derivative of its input i: o = K d * di/dt K d is a proportionality constant The intuition behind derivative control: –Controller corrects for the momentum as it approaches the desired state Slow down a robot and decrease the turning angle while getting closer to the desired state

CS 491/691(X) - Lecture 551 Readings F. Martin: M. Matarić: