MSPM0_ValvanoWare  1.0
ECE445L starter code
Macros | Functions
PWM.h File Reference

Pulse width modulation. More...

Go to the source code of this file.

Macros

#define PWMUSELFCLK   2
 use PWMUSELFCLK to select LFCLK
 
#define PWMUSEMFCLK   4
 use PWMUSEMFCLK to select MFCLK
 
#define PWMUSEBUSCLK   8
 use PWMUSEBUSCLK to select bus CLK
 

Functions

void PWM_Init (uint32_t timerClkSrc, uint32_t timerClkPrescale, uint32_t period, uint32_t duty0, uint32_t duty1)
 Initialize PWM. More...
 
void PWM_SetDuty (uint32_t duty0, uint32_t duty1)
 Set duty cycles. More...
 
void PWM_PA12Init (uint32_t timerClkSrc, uint32_t timerClkPrescale, uint32_t period, uint32_t duty0)
 Initialize PWM. More...
 
void PWM_PA12SetDuty (uint32_t duty0)
 Set duty cycles. More...
 

Detailed Description

Pulse width modulation.

Hardware creates fixed period, variable duty cycle waves

Version
ECE319K v1.0
Author
Daniel Valvano and Jonathan Valvano
Warning
AS-IS
Note
For more information see http://users.ece.utexas.edu/~valvano/
Date
August 13, 2023
PWM pins on the MSPM0G3507
Pin Description
PA12 CCP0 PWM output
PA13 CCP1 PWM output