8 years, 2 months ago.

St Nucleo F091RC and break signal (mbed bug?)

The below source code works perfectly with the ST Nucleo F446RE but not with ST Nucleo F091RC. We have verified with an oscilloscope. Is it a mbed bug or the board does not support the break signal?

  1. include "mbed.h"
  1. define BAUDRATE 19200

Serial Serial0(USBTX, USBRX); Serial Serial1(PA_0, PA_1); Serial Serial2(PC_10, PC_11);

int main() { Serial0.baud(BAUDRATE); Serial1.baud(BAUDRATE); Serial2.baud(BAUDRATE);

Serial0.format(8, SerialBase::None, 1); Serial1.format(8, SerialBase::None, 1); Serial2.format(8, SerialBase::None, 1);

while(1) { Serial0.send_break(); Serial1.send_break(); Serial2.send_break();

Serial0.putc(0x30); Serial1.putc(0x31); Serial2.putc(0x32); } }

1 Answer

8 years, 2 months ago.

Hello,
On Nucleo-F446RE you have the following:

  • (USBTX, USBRX) associated to Seria_2
  • (PA_0, PA_1) associated to Serial_4
  • (PC_10, PC_11) associated to Serial_3

While on Nucleo-F091RC you have the following:

  • (USBTX, USBRX) associated to Serial_2
  • (PA_0, PA_1) associated to Serial_4
  • (PC_10, PC_11) associated to Serial_4

where Serial_2 Serial_3 Serial_4 are hardware instances of the serial interface as named on the mbed platform page pinout. (in the datasheet they are usually named UART or USART )
When you run your code on the Nucleo-F091RC, there is a conflict with your Serial1 and Serial2 competing for the same hardware.
Could you try using another interface?
look at the platform page pinout for other options.