9 years, 8 months ago.

PWM pin PA_5

Hello, I want pwm on pin PA_5 (LED) and I see, there is pinmap not found for peripheral. I look into PeripheralPins.c in mbed-src and I see

{PA_5, PWM_2, STM_PIN_DATA(STM_MODE_AF_PP, GPIO_PULLUP, GPIO_AF1_TIM2)}, TIM2_CH1 - Warning: LED1 is connected on this pin TIM2 cannot be used because already used by the us_ticker

In Arduino-compatible headers is about PA_5 PWM1/1N . PWM1 indicate as TIM1.

How I can use pin PA_5 as PWM output with mbed?

Question relating to:

Affordable and flexible platform to ease prototyping using a STM32F303RET6 microcontroller.
Be the first to answer this question.