520 likes | 620 Views
What we learnt in the last session. Line follower. Making a better line follower. More sensors - ????. But how to control it now??. If else conditions Assume 7 sensors and line can have 1/2/3 on it at a time Total conditions - ? 7 + 6 + 5 = 18 conditions. Control algorithm – PID .
E N D
Making a better line follower • More sensors - ????
But how to control it now?? • If else conditions Assume 7 sensors and line can have 1/2/3 on it at a time Total conditions - ? 7 + 6 + 5 = 18 conditions
Control algorithm – PID Works on this principle : Error = Input(How the system is behaving) - Desired Setpoint(What is desired from the system) Try to have an output to control the error - 3 parameters Output = Proportional term + Derivative term + Integral term Proportional term : Help to minimize the deviation from error. Derivative term : Help to minimize the fluctuations. Integral term : Help to reach a steady state.
Control algorithm – PID How to control by minimizing error??? Proportional term = Kp * Error P only system : Output = Kp* Error As Kp increases -System fluctuates a lot Let’s fix this fluctuation
Control algorithm – PID Add a Derivative term to it. Derivative term = Kd*[d(Error)/dt] Now the rate of change of error has an effect on Output. Reduces fluctuations. Output = Kp* Error+Kd*[d(Error)/dt] Leaves a steady state error - When P and D terms cancel each other’s effect .
Control algorithm – PID Let’s fix the steady state error. Integral term = Ki*[Integral(Error) dt] Removes the residual steady state error. Need to optimize Kp, Ki and Kd to get a good system response. Output = Kp* Error + Kd*[d(Error)/dt] + Ki*[Integral(Error) dt]
Make your bots cooler – use a PS2 joystick Use bill porter’s library to interface PS2 with Arduino Use it to control your bots ☺
Make your bots cooler – make it wireless XBEE transceiver module RF transmitter and receiver module WIFI module
Make your bots cooler - Add features Know your location GPS module Control it by your phone GSM module Control it by your phone Bluetooth module
Some sensors • Encoders • SONARs • LIDARs • Ping Sensors • Hall sensors • Compass / IMU
Encoders Linear encoders : Calculate linear distances covered.
Encoders Rotary encoders : Convert rotation of a shaft into electronic signals.
Simple Position Encoder • Position Encoder sensors are used to find position of the wheel. It consists of IR LED and Photodiode mounted facing each other enclosed in plastic body. • When light emited by the IR LED is blocked because of alternating slots of the encoder disc logic level of the photo diode changes. • This change in the logic level can be sensed by the microcontroller or by discrete hardware. This sensor is used to give position feedback to the robot
Drawbacks??? • No information regarding direction of the wheel. • Has high possiblities of error. Since mount can can worn out in time. • Optical sensor is open. So lighting conditions can affect the working of the encoder.
Quadrature Encoders • In Quadrature encoders, There are two sets of IR receiver. • If we wish to monitor the speed of rotation then you can use either output and simply measure the frequency. The reason for having two outputs is that you can also determine the direction of shaft rotation by looking at the pattern of binary numbers generated by the two outputs.
00 = 0 01 = 1 11 = 3 10 = 2 (or) • 00 = 0 10 = 2 11 = 3 01 = 1
Motor controller CFI 2013 projects: Motor controller v1 and Motor controller v2 Current CFI summer project: Motor controller v3 • To build an advanced integrated motor controller that can match industry standards. • Keep the model generic so that it can be applied in various places with minimal modifications.
Motor controller Sensors required : Rotary Encoder How to control : PID control using PWM eg: Velocity control Give motor some pwm if (Reqd speed > Current speed) Give more PWM else if (Reqd speed < Current speed) GIve less PWM
SONAR and Ping sensors Find distance from obstacles using Sound waves SONAR Ping sensor
LIDAR Illuminates a target with a laser and analyzing the reflected light Very computation intensive
Compass, Accelerometer, Gyroscope Aim : See an object’s behaviour in 3-Dimensions Accelerometer : Acceleration of linear movement Gyroscope : Rotational angular velocity Compass : Absolute orientation with respect to earth’s magnetic field.4 IMU : Single sensor which incorporates all 3.
Simple cool projects with Arduino LED cube array Control every LED in the cube separately. Produce cool patterns. Requirements: Arduino LEDs
Simple cool projects with Arduino RC controlled bot Make your bot controlled remotely Requirements: RF module/XBEE module Simple bot Arduino
Complex projects • Quadrotor Uses : Sensors IMU - Control the tilt and angular velocity
Complex projects • Segway Self balancing two wheeled robot Uses: Sensors: Gyroscope for stabilizing Encoders for controlling motors
Different locomotion systems Differential drive Two rear wheels control the motion of the robot. Can be used to trace curves by maintaining proper velocity ratios. Disadvantages: Can’t take sharp turns
Different locomotion systems Track belt drive Suitable for uneven surfaces IITM DRDO robot
Different locomotion systems • Omni wheel drives Omni wheels - Have rollers not in the direction of motion allowing free motion in multiple directions. Mecanum wheels Transwheels Rollers perpendicular to motion Rollers inclined at 45 degrees to motion
Different locomotion systems Transwheel robot IITM Robocon team 3 wheel transwheel
ω V1 V2 Transwheel robot V Advantages: Speed and control - Ability to move in any direction without orientation change. V4 V3
Different locomotion systems Mecanum robot Rollers at 45 degree angle to direction of motion Advantages: Wheels give more traction-> higher torque IITM Robocon team Mecanum robot
AUV AUTONOMOUS UNDERWATER VEHICLE: Important factors: • Structural design - Stable shouldn’t fail • Propulsion - Calculate requirements Ensure stability • Payloads
AUV Propulsion
Controlling AUV: Onboard computer gets sensor inputs from AUV, processes and controls the AUV using a microcontroller. It is connected to an external computer through WIFI for debugging purposes. AUV Electronics Sensors needed: • IMU • Camera • Pressure sensor • Leak detector
Bored with Arduino? Some projects need much more processing power than an Arduino can provide. Linux boards High processing power while offering the same capabilities as a microcontroller Work on Linux based OS eg: Raspberry Pi
Some interesting boards Raspberry Pi CPU: 700 MHz ARM11 family, ARMv6 instruction set) GPU:Broadcom VideoCore IV @ 250 MHz Audio outputs:3.5 mm jack, HDMI SD / MMC / SDIO card slot Low-level peripherals:8 × GPIO, UART, I²C bus, SPI bus Operating systems:Arch Linux ARM, Debian GNU/Linux, Gentoo, Fedora, FreeBSD, NetBSD, Plan 9, Raspbian OS, RISC OS, Slackware Linux
CircuitCo MinnowBoard Specifications • Processor: Intel Atom™ E640 (1GHz, 32 bit) • Integrated Intel Graphics Media Accelerator (GMA) 600 • 1GB DDR2 RAM • Operating System: Open source Angstrom Linux • Video: HDMI • Audio: Analog • I/O: 1 micro SD, SATA2 3Gb/sec, 2 USB Hosts, 1 USB Device (micro USB-B port), 1 Debug Serial to USB conversion (mini USB-B port), 10/100/1000 Ethernet • System boot firmware: UEFI Firmware with Fast Boot capability