2016-10-21 01:21 AM
2016-10-24 06:48 AM
Solved, just need to be added :
HAL_TIMEx_PWMN_Start(&htim1, TIM_CHANNEL_1);2016-10-26 03:35 AM
Hi BramLabs,
Is this function not generated as HAL_TIMEx_PWM_Start() ? can you share you .ioc file.-Hannibal-2016-10-26 09:32 AM
Sure :)
https://www.dropbox.com/s/il15kbf10xbha6c/TES_PWM_COMPLEMENTARY.ioc?dl=0 or you can see the file in attachment file. (I just added ADC read configuration using DMA into the file for my project recently. Just delete the ADC things and reset the status of the pin to make sure only the PWM configuration enabled) Oh yeah btw, for your question, i only tried usingHAL_TIMEx_PWMN_Start(&htim1, TIM_CHANNEL_1);
I tried looking at thestm32f4xx_hal_tim_ex.c function, and i found that:
(#) Activate the TIM peripheral using one of the start functions: (++) Complementary Output Compare : HAL_TIMEx_OCN_Start(), HAL_TIMEx_OCN_Start_DMA(), HAL_TIMEx_OC_Start_IT() (++) Complementary PWM generation : HAL_TIMEx_PWMN_Start(), HAL_TIMEx_PWMN_Start_DMA(), HAL_TIMEx_PWMN_Start_IT() (++) Complementary One-pulse mode output : HAL_TIMEx_OnePulseN_Start(), HAL_TIMEx_OnePulseN_Start_IT() (++) Hall Sensor output : HAL_TIMEx_HallSensor_Start(), HAL_TIMEx_HallSensor_Start_DMA(), HAL_TIMEx_HallSensor_Start_IT(). Just ady tested and it worked. ________________ Attachments : TES_PWM_COMPLEMENTARY.ioc : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I1Jz&d=%2Fa%2F0X0000000blF%2F7aeaVVsziwb27gjCo8mlNmjYhH5X1yfrmQMYj3V7rCk&asPdf=false