__HAL_TIM_SetCompare for complementary PWM signals
Is there a way to use __HAL_TIM_SetCompare() for negated signals while generating complementary PWM signals?
Any help would be appreciated
Is there a way to use __HAL_TIM_SetCompare() for negated signals while generating complementary PWM signals?
Any help would be appreciated
The signal on TIMx_CHxN output is the same as on TIMx_CHx output, except inverted and dead time applied.
So, there is only one TIMx_CCRx register, determining the given channel's pulse width, and that is what __HAL_TIM_SET_COMPARE() (which is a newer name for __HAL_TIM_SetCompare()) sets.
In other words, there is no separate "pulse" register for the inverted output, so there is also no separate macro to set it.
JW
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.