9 #include <nxp/drivers/fsl_pwm.h>
11 #define EFLEXPWM_DUMPREG_ENABLED 1
44 return ( (65535U * dutyCyclePercent) + 50U) / 100U;
50 const uint8_t NofTimers = 4;
51 const uint8_t NofSubmodules = FSL_FEATURE_PWM_SUBMODULE_COUNT;
52 const uint8_t NofPins = PWM_SUBMODULE_CHANNEL;
62 Pwm1Flag = (1 << Pwm1),
63 Pwm2Flag = (1 << Pwm2),
64 Pwm3Flag = (1 << Pwm3),
65 Pwm4Flag = (1 << Pwm4),
66 AllTimersFlag = (Pwm1Flag | Pwm2Flag | Pwm3Flag | Pwm4Flag)
77 Submodule1Flag = (1 << Submodule1),
78 Submodule2Flag = (1 << Submodule2),
79 Submodule3Flag = (1 << Submodule3),
80 Submodule4Flag = (1 << Submodule4),
81 AllSubmodulesFlag = (Submodule1Flag | Submodule2Flag | Submodule3Flag | Submodule4Flag)
93 extern PWM_Type *PWM[NofTimers];
94 extern uint8_t SmMask[NofTimers];
102 return (c == ChanA ? kPWM_PwmA : kPWM_PwmB);
enum _pwm_channels pwm_channels_t
List of PWM channels in each module.
enum _pwm_submodule pwm_submodule_t
List of PWM submodules.
uint16_t reloadValue(uint8_t dutyCyclePercent)
Convert duty cycle to reload value.
uint16_t u16TwoCompl(uint16_t value)
Complement the variable of type uint16_t as needed.