1 / 12

CSC-2700 – (3) Introduction to Robotics

CSC-2700 – (3) Introduction to Robotics. Robotics Research Laboratory Louisiana State University. What we learned in last class. Pulse-width Modulation What for How it works Applications How to make it Servo Motor Control What is servo motor How it works Set position of servo head

parley
Download Presentation

CSC-2700 – (3) Introduction to Robotics

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CSC-2700 – (3) Introduction to Robotics Robotics Research Laboratory Louisiana State University

  2. What we learned in last class • Pulse-width Modulation • What for • How it works • Applications • How to make it • Servo Motor Control • What is servo motor • How it works • Set position of servo head • Simple Hexabot • Walking • Turning • Control hexbot

  3. Pulse-width Modulation • How to make it? • Digital Out (PINx) • Special Function I/O Regiser (SFR/SFIOR) • Using a main program • ns_spin( intdelay_time ) ; TOGGLE_PIN(PINxx) • Using interrupts • Timers • PORTB – PINB5 (OCA1), PINB6 (OC1B), PINB7 (OC2) • PORTE – PINE3 (OC3C), PINE4 (OC3B), PINE5 (OC3A)

  4. Servo Motor Control • What is it? • Robotic Arms, RC-Airplane, etc. • Mechanical position change • How does it work? • Position Reader (Potentiometer) • DC-Motor • PWM DC-Motor Controller • Body Frame • Gears • Servo Head

  5. Servo Motor Control • How to set position of a servo head • /home/csc2700/csc2700/10-PWM-Servo-01 intcount = 0; while (1){ switch (count++ % 4){ case(0): OCR3A = 1000; break; // OCR3A is PINE3 , 1000 is 1ms == left (0 degree) case(1): OCR3A = 3000; break; // OCR3A is PINE3 , 3000 is 3ms == middle (90 degree) case(2): OCR3A = 5000; break; // OCR3A is PINE3 , 5000 is 5ms == right (180 degree) case(3): OCR3A = 3000; break; // OCR3A is PINE3 } ms_spin(1000); }

  6. DC Motor Controller (TB6612FNG) MOSFET-based H-bridges

  7. TB6612FNG Specifications • MOSFET-based H-bridges • Recommended motor voltage (VMOT): 4.5 – 13.5 V • Logic voltage (VCC): 2.7 – 5.5 V • Output current maximum: 3 A per channel • Output current continuous: 1 A per channel (can be paralleled to deliver 2 A continuous) • Maximum PWM frequency: 100 kHz • Built-in thermal shutdown circuit • Filtering capacitors on both supply lines • Reverse-power protection on the motor supply

  8. MOSFET-based H-bridges • The metal–oxide–semiconductor field-effect transistor

  9. H- Bridge • An H bridge is anelectronic circuit that enables a voltage to be applied across a load in either direction

  10. H- Bridge

  11. Let’s make a simple DC-motor control program int main(void){ InitHardware(); initPWM(); MC_HI(STANBY); MC_LO(LEFT0); MC_LO(LEFT1); MC_LO(RIGHT0); MC_LO(RIGHT1); int speed = 1000; int delay = 100; while (1){ MC_LO(LEFT0);MC_HI(LEFT1); SetPWM( PWM_PINE3, speed); SetPWM( PWM_PINE4, speed); ms_spin(delay); MC_LO(RIGHT0);MC_HI(RIGHT1); SetPWM( PWM_PINE3, speed); SetPWM( PWM_PINE4, speed); ms_spin(delay); speed += 1000; if (speed > 40000){ speed = 1000; } } }

  12. Homework- 6 • Create a DC motor speed control program, which has a clockwise button, an anti-clockwise button, and a stop button • The clockwise button is for increasing speed of Motor controller toward clockwise (speed down for anti-clockwise) • The anti-clockwise button is for increasing speed of Motor controller toward anti-clockwise (speed down for clockwise) • The stop button is for stop DC motor

More Related