pulse widith modulation ee 587 presented by viswanadha kakarlapudi
DESCRIPTION
PULSE WIDITH MODULATION EE 587 Presented by Viswanadha Kakarlapudi. Overview. Introduction Implementing 16-Bit PWM Using the PCA 16-Bit PWM Using the On-Chip Timer How Servos Work References. Introduction. Signal Information is encoded in the duty cycle - PowerPoint PPT PresentationTRANSCRIPT
PULSE WIDITH MODULATIONPULSE WIDITH MODULATION
EE 587EE 587
Presented byPresented by Viswanadha KakarlapudiViswanadha Kakarlapudi
OverviewOverview
IntroductionIntroduction
Implementing 16-Bit PWM Using the PCAImplementing 16-Bit PWM Using the PCA
16-Bit PWM Using the On-Chip Timer16-Bit PWM Using the On-Chip Timer
How Servos Work How Servos Work
ReferencesReferences
IntroductionIntroduction
Signal Information is encoded in the Signal Information is encoded in the duty cycleduty cycle
Input to the PWM implementation is an integer Input to the PWM implementation is an integer proportional to the duty cycle desiredproportional to the duty cycle desired
Implementing PWM Using PCAImplementing PWM Using PCA Introduction to PCA (Programmable Counter Array)Introduction to PCA (Programmable Counter Array)
Implementing PWM Using PCAImplementing PWM Using PCA
8-Bit PWM8-Bit PWM
Implementing PWM Using PCAImplementing PWM Using PCA
8-Bit PWM8-Bit PWM
Duty cycle can be changed by single 8-bit write Duty cycle can be changed by single 8-bit write to PCAOCPHnto PCAOCPHn
16-Bit PWM Using the PCA16-Bit PWM Using the PCA
16-Bit PWM Using the PCA16-Bit PWM Using the PCA
Duty cycle can be changed by single 16-bit write Duty cycle can be changed by single 16-bit write to the variable to the variable PWMPWM
16-Bit PWM Using an On-Chip Timer16-Bit PWM Using an On-Chip Timer
The C8051F2xx family SoC’s feature three on-The C8051F2xx family SoC’s feature three on-board timers that can be used for PWM board timers that can be used for PWM generationgeneration
The C8051F226-TB features a low-pass filter that The C8051F226-TB features a low-pass filter that can be readily used for the PWM DACcan be readily used for the PWM DAC
16-Bit PWM Using an On-Chip Timer16-Bit PWM Using an On-Chip Timer
Timer is set to the amount of time the PWM wave Timer is set to the amount of time the PWM wave is high during one cycleis high during one cycle
When the timer overflows, the program vectors to When the timer overflows, the program vectors to an ISR to take a port pin high or low to produce an ISR to take a port pin high or low to produce the PWM wavethe PWM wave
The smallest pulse width that can be assigned is The smallest pulse width that can be assigned is 19 clock cycles. The ISR takes 14 cycles to take 19 clock cycles. The ISR takes 14 cycles to take the PWM wave from high to lowthe PWM wave from high to low
16-Bit PWM Using an On-Chip Timer16-Bit PWM Using an On-Chip Timer
How Servos WorkHow Servos Work
Servos are commanded through PWM signalsServos are commanded through PWM signals In order for the Servo to hold position, the In order for the Servo to hold position, the
command must be sent every 20mscommand must be sent every 20ms
How Servos WorkHow Servos Work
ReferencesReferences
www.cygnal.com/appnoteswww.cygnal.com/appnotes
www.brookshiresoftware.comwww.brookshiresoftware.com