Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
7 years, 11 months ago.
Nordic nRF52-DK stops its serial communication with a linux pc
I used a windows pc with tera term for the serial communication until now (with online compiler). There everything was working fine. But i wanted to switch to Linux (arch) for the mbed cli. Compiling is working fine, but the connection to the serial port always quits after a first few transmission and the LED stops at its current condition.
I tested multiple Serial terminals in Linux (cat, screen, putty,picocom...) but everywhere the same behaviour. The "port" was always /dev/ttyACM0.
So I first thought the maybe my Linux configuration has some problems but i tested with an arduino under the same conditions and everything worked fine (9600 baud rate, 8 bits, 1 stop bit, no parity).
Now to the question: Is there a bug with the mbed library or the nrf52-DK using the serial port? And is there a workaround?
Greetings, Chris
Here the simple code example i used to test the "bug":
#include "mbed.h" DigitalOut led1(LED1); Serial pc(USBTX, USBRX); // tx, rx int main() { int counter = 0; while (true) { pc.printf("test %d \n", counter); counter++; led1 = !led1; Thread::wait(500); } }
Question relating to:
2 Answers
7 years, 11 months ago.
Just found the following resolution via a Google search:
https://devzone.nordicsemi.com/question/91854/mbed-os-serial-port-hang/
https://github.com/ARMmbed/mbed-os-example-ble/issues/25
7 years, 11 months ago.
By default nRF52-Dk target use hardware flow control on serial port (involved RTS/CTS signals) - so the described behaviour is not a bug. As was answered above: it is possible to turn of flow control on DK firmware or turn it on in PC terminal.