PWM Test 2 UNIT 20 로봇 SW 교육원 조용수. 학습 목표 PWM Servo 제어 2.

Slides:



Advertisements
Similar presentations
UNIT 10 GPIO Test 로봇 SW 교육원 조용수.
Advertisements

Interrupt Test UNIT 14 로봇 SW 교육원 조용수. 학습 목표 Button Interrupt Uart Interrupt 2.
Microcontroller Programming II MP6-1
C Examples 1.
Robotics Research Laboratory Louisiana State University.
AD Converter UNIT 19 로봇 SW 교육원 조용수. 학습 목표 AD Converter AD Converter Register 2.
UNIT 20 AD Converter Test 로봇 SW 교육원 조용수.
EET 2261 Unit 13 Controlling Stepper Motors and Servos  Read Almy, Chapter 21.  Lab #13 due next week.  Final Exam next week.
8-Bit Timer/Counter 0 Counter/Timer 0 and 2 (TCNT0, TCNT2) are nearly identical. Differences: -TCNT0 can run off an external 32Khz clock (Tosc) or the.
Infineon Technologies Corp. June 99 1 HOT167-1 Version 2.0 F PWMmax = x 50ns = 78 kHz Pulse Width Modulation Unit (PWM) (20 MHz)  4 independent.
DC-DC Converters Convert a fixed DC Source into a Variable DC Source
Timers and Interrupts Shivendu Bhushan Summer Camp ‘13.
1 Eric Taseski, Yihe Huang, Ronak Mehta H-Bridges and Stepper Motors 2.
I2C UNIT 23 로봇 SW 교육원 조용수. 학습 목표 I2C I2C Protocol 구조 N051 I2C 동작 I2C Register 2.
UART Test UNIT 14 로봇 SW 교육원 조용수. 학습 목표 UART Init UART Send UART Receive UART -> Debugging Console Up/Down Game 제작 2.
Pulse Width Modulation
ECE 371- Unit 11 Timers and Counters (“Stop Watches and Alarm Clocks”)
7/23 Timers in Coldfire Processor Computer Science & Engineering Department Arizona State University Tempe, AZ Dr. Yann-Hang Lee (480)
September, 2007ENGR Low-Level Robot Control Mechatronics: Motors, sensors & embedded controls.
PWM ECE 4437-EMBEDDED SYSTEMS DR. GLOVER CHRISTOPHER AHN & KHOA VAN.
Timers and Event Counters
PWM UNIT 17 로봇 SW 교육원 조용수. 학습 목표 PWM PWM Register 2.
Robotics Research Laboratory Louisiana State University.
Pulse Width Modulation (PWM). 100% Pulse Width Modulation (PWM) 0% On the chipKIT there are 490 periods per second. Use analogWrite(pin, value) to control.
UNIT 29 MCU Project 로봇 SW 교육원 조용수.
로봇 모니터링 1/2 UNIT 20 로봇 SW 콘텐츠 교육원 조용수. 학습 목표 Message Queue Handler 2.
CCP MODULES  The CCP module (Capture/Compare/PWM) is a peripheral which allows the user to time and control different events.  Capture Mode provides.
UNIT 11 UART 로봇 SW 교육원 조용수.
Albert Board UNIT 27 로봇 SW 교육원 조용수. Albert Board ISD 9160 Albert Board Connection Albert Board 용 SW 설치 Sample Source 동작 2.
Example 12 Pulse-Width Modulation (PWM): Motors and Servos Lecture L8.1.
SPI Test UNIT 26 로봇 SW 교육원 조용수. 학습 목표 SPI Sample SPI Read/Write Function SPI loop back Test MPL115A1 Pressure and Temperature Sensor 2.
Robotics Research Laboratory Louisiana State University.
1 Timers and Event Counters Lecture In These Notes... We learn the basics of the Timer/Counter peripheral –Called timers by Renesas We examine how.
S4525A Peripherals & Enhanced FLASH 1 © 1999 Microchip Technology Incorporated. All Rights Reserved. S4525A Peripherals & Enhanced FLASH 1 Peripherals.
System Control & Clock UNIT 08 로봇 SW 교육원 조용수. 학습 목표 System Control Register System Clock CMSIS CMSIS Project 2.
1 4-Integrating Peripherals in Embedded Systems (cont.)
PIC18F4431. PIC18F1330 Infrared Encoder/Decoder.
PULSE WIDITH MODULATION EE 587 Presented by Viswanadha Kakarlapudi.
Timer 1 and 2 operation, PWM Principles. Timer 1 Operation.
PWM: Pulse Width Modulation © 2014 Project Lead The Way, Inc.Digital Electronics.
Timer & Watch Dog Test UNIT 16 로봇 SW 교육원 조용수. 학습 목표 Timer Init Timer Delay Test Timer Interrupt Test –One Shot Mode –Periodic Mode Watch Dog Test 시계 만들어.
Motor TYWu.
[Lab10] Output PWM  Output PWM Signal  Example  Exercise(Optional)
Analog Output Materials: animatronic head Processing Quiz HW: code links.
Seth Schwiethale James Crosetto James Ellison.  square pulse of ms, repeats every 20 ms  It is the same for both steering and acceleration 
Introduction to Arduino A very basic intro to Arduino, the IDE and the Servos class.
Atmega328p Introduction for Digital and PWM Output Brion L Fuller II Robotics Club.
Istituto Tecnico Industriale A.Monaco EURLAB Control a Servo Motor If you want to swing an robot arm or … steer a robot you need a special motor (Servo).
Pulse-Width Modulation: Simulating variable DC output
Module 8 Tutorial  An 8086 system is used for controlling the speed of a motor. The motor can operate at 5 different speeds (1- 5).  The speed.
Microcontroller basics Embedded systems for mortals.
Pulse Width Modulation Instructor Dr Matthew Khi Yi Kyaw.
1. PIC ADC  PIC18F877 has 8 analog input channels i.e. port A pins(RA0 to RA5) and port E pins(RE1 and RE2). These pins are used as Analog input pins.
-AT91SAM7X256 – Pulse Width Modulation YoonMo Yeon
PWM Test UNIT 20 로봇 SW 교육원 조용수. 학습 목표 PWM Init PWM LED 제어 2.
Team 7 Chaofan Chen Dhruvmin Gandhi Larry Gerhardt Pulse-width Modulation with the TIVA C.
UNIT 24 I2C Test 로봇 SW 교육원 조용수.
Microcontroller basics
Timers and Event Counters
If you want to swing an robot arm or …
Pulse Width Modulation
Introduction to Servos
AUTOCAR Team #13 Greg Futia Greg VonFange Phil Kasper Ani Bhende.
EET 2261 Unit 12 Controlling Stepper Motors and Servos
Arduino : Introduction & Programming
UNIT 19 PWM 로봇 SW 교육원 조용수.
UNIT 24 I2C Test 로봇 SW 교육원 조용수.
Robotics System Lecture 11_12: DC Motor
UNIT 26 SPI Test 로봇 SW 교육원 조용수.
Presentation transcript:

PWM Test 2 UNIT 20 로봇 SW 교육원 조용수

학습 목표 PWM Servo 제어 2

PWM Servo Motor 제어 RC Servo 제어 3

PWM Servo Motor 제어 RC Servo 의 주기 20ms (CNR + 1) = / [( 7 + 1) * (1) *(50Hz)]; CNR : ~ 1ms : CW –Duty Ratio : 3.5 ~ 5% 1.5ms : Center –Duty Ratio : 7.5% 1.7 ~ 2ms : CCW –Duty Ratio : 8.5 ~ 10 % 4

PWM Init PWM Port Setting 5 void SYS_Init(void) { SYS_UnlockReg(); CLK->APBCLK = CLK_APBCLK_UART0_EN_Msk; SystemCoreClockUpdate(); SYS->P3_MFP = SYS_MFP_P30_RXD0 | SYS_MFP_P31_TXD0; CLK_EnableModuleClock(PWM45_MODULE); CLK_SetModuleClock(PWM45_MODULE, CLK_CLKSEL2_PWM45_S_HIRC, 0); SYS->P2_MFP = SYS_MFP_P25_PWM5 ; /* Lock protected registers */ SYS_LockReg(); }

PWM Init 6 void PWMInit() { /* Config PWM generator and get the nearest frequency in edge aligned auto-reload mode */ PWM_ConfigOutputChannel(PWMB, 1, 50, 10); /* PWMA pin output enabled */ PWM_EnableOutput(PWMB, 0x2); /* Start PWMA module */ PWM_Start(PWMB, 0x2); }

PWM Init 7 int main(void) { int delay; SYS_Init(); PWMInit(); while(1){ PWM_ConfigOutputChannel(PWMB, 1, 50, 3); delay = 10000; while(delay--){ int delay2 = 100; while(delay2--); } PWM_ConfigOutputChannel(PWMB, 1, 50, 8); delay = 10000; while(delay--){ int delay2 = 100; while(delay2--); } PWM_ConfigOutputChannel(PWMB, 1, 50, 11); delay = 10000; while(delay--){ int delay2 = 100; while(delay2--); }

PWM LED 제어 가변 저항 값으로 PWM RC Servo 제어 8