Page 1 of 1

A minor bug for STM32F3x and STM32F3 Board UART example

Posted: Sun Jan 25, 2015 7:06 pm
by joedalton
Hi, i 'm a newbie to ChibiOS, and just run a UART example for STM32F3 Discovery Board, and i found a minor bug on this:
In the main.c , at USART1 configuartion:

Code: Select all

 /*
   * Activates the serial driver 1 using the driver default configuration.
   * PA9(TX) and PA10(RX) are routed to USART1.
   */
  sdStart(&SD1, NULL);
  palSetPadMode(GPIOA, 9, PAL_MODE_ALTERNATE(7));
  palSetPadMode(GPIOA, 10, PAL_MODE_ALTERNATE(7));


but for STM32F30x, PC4(TX) and PC5(RX) are routed to USART1, PA2(TX) and PA3(RX) routed to USART2, PB10(TX) and PB11(RX) routed to USART3. I 've fixed it and it run like a charm :D

Re: A minor bug for STM32F3x and STM32F3 Board UART example

Posted: Sun Jan 25, 2015 9:37 pm
by Giovanni
Hi,

Have fun with ChibiOS :)

Both PA9/PA10 and PC4/PC5 (and also PE0/PE1) can be used, the STM32 GPIO allows to map peripherals to multiple sets of pins.

The matter is described in tables 11-17 of the F3 DataSheet.

Giovanni

Re: A minor bug for STM32F3x and STM32F3 Board UART example

Posted: Mon Jan 26, 2015 1:35 am
by joedalton
Wow, thanks. It 's my bug :mrgreen: :mrgreen: