cancel
Showing results for 
Search instead for 
Did you mean: 

How to use CubeMX to set up IRTIM Feature

David Brooks
Associate II
Posted on August 26, 2015 at 16:26

I am trying to use CubeMX to set up the IRTIM feature on pin PB9 on an STM32F051. The feature is complicated, as it used TIM16 and TIM17 as well. After configuring PB9, TIM16 and TIM17 in Cube as I would expect, PB9 is orange on the Pinout Page. And, according to the example in  RM0091 Section A.10, there appears to be a number of additional configurations settings that need to be completed to make the feature work, but I am not finding those configuration settings in Cube. I guess there is always the possibility that Cube cannot configure the entire feature. Can anyone tell me how to properly and fully configure the IRTIM feature in Cube or point me to documentation that does?

3 REPLIES 3
Posted on August 28, 2015 at 13:57

Hi dmbrooks44,

When you activate TIM16 and TIM17 in the pinout view, do not forget to enable the channel1 option with ''Output Compare No Output'' for both of them. After that, the iRTIM peripheral will be enabled and you can activate it. At the end, choose the PB9 as output pin.

Hope this can help.

-Shahrzad-
David Brooks
Associate II
Posted on October 27, 2015 at 22:44

Thank you.  Your suggestion allowed me to enable the IRTIM feature in Cube. However, I cannot find any other documentation on how to use this feature. In fact TIM16, TIM17 and pin IR_OUT aren't described in the Reference Manual or Timer Manual. Can you point me to some documentation?

Posted on October 28, 2015 at 16:50

Hi dmbrooks44,

It is indicated in Reference manual that you should use TIM16/17 to activate IRTIM.

''To generate the infrared remote control signals, the IR interface must be enabled and TIM16 channel 1 (TIM16_OC1) and TIM17 channel 1 (TIM17_OC1) must be properly configured to generate correct waveforms.''

Besides, you find in 

http://www.st.com/st-web-ui/static/active/en/resource/technical/document/application_note/DM00053084.pdf

 more informations about using IRTIM.

Hope yhis can help 🙂

-Shahrzad-