Arm Mbed and Pelion Device Management support forum

Lpc 1768 no usb serial to pc connection

I have scoured the Mbed site and internet for a solution to this problem. I have followed all of the guidance for drivers and ports and still cannot get any output to a terminal window (Putty or CoolTerm).
I am using Windows 10 Home with the basic serial example program and get the following output to the terminal: $$$$10100f2ea3eced51bdc9897acd2f201d7596.

Your help would be greatly appreciated.

#include “mbed.h”

// define the Serial object
Serial pc(USBTX, USBRX);

DigitalOut led1(LED2);

int main() {
while (true) {
led1 = !led1;

    // Print something over the serial connection
    pc.printf("Blink! LED is now %d\r\n",;


Hello @girrion,

Please try this simple example to print something on the window and let us know.

Thanks & Regards,
Team Mbed

Hello @maygup01,

Thank you for the prompt reply.
Following your suggestion I have received the following (abbreviated) response from the compiler:
mbed compile -t GCC_ARM -m LPC1768
[Error] main.cpp@20,2: #error [NOT_SUPPORTED] test not supported

Following subsequent failures, I imported and tried mbed-os-example-blinky. This compiled and behaved as expected.

I then ran mbed detect and received the following output:

[mbed] Detected LPC1768, port None, mounted H:, interface version unknown:
[mbed] Supported toolchains for LPC1768

Target mbed OS 2 mbed OS 5 uARM IAR ARM GCC_ARM ARMC5
LPC1768 Supported Supported Supported Supported Supported Supported -

Supported targets: 1
Supported toolchains: 4

I note that despite Windows device Manager reporting the port etc (mbed Serial Port(COM3)) all working properly, the above report identifies no port.

If i use the MODE command, only COM1 is listed.

Your help is greatly appreciated.

Best regards,


@girrion Did you reset your LPC1768 after flashing your original program?

As for “[Error] main.cpp@20,2: #error [NOT_SUPPORTED] test not supported”, you are missing macro definitions. Looks like the example defines one of them in mbed_app.json (not sure how the others are defined). See line 19 to 21. If you just want to see some actions, I think you can just comment these out.

#if !defined(MBED_CPU_STATS_ENABLED) || !defined(DEVICE_LPTICKER) ||      !defined(DEVICE_SLEEP)
#error [NOT_SUPPORTED] test not supported

In any case, you want to press the reset button after flashing a new program.

Hello @lonesometraveler,

Thank you, commenting out the lines allowed the code to compile and flash to the LPC1768.

Best regards,


Hello @maygup01,

Following @lonesometraveler advice, and compiling and flashing the code you suggested earlier to the LPC1768 resulted in LED1 blinking on and off a couple of times, but provided no printed output to any of the terminal programs.

COM3 is now listed by the MODE command

When I run mbedls the serial port is unknown.

Best regards,


Hello @maygup01, @lonesometraveler,

I have resolved the port detection issue as you can see below

[mbed] Detected LPC1768, port COM3, mounted H:, interface version unknown:
[mbed] Supported toolchains for LPC1768

Target mbed OS 2 mbed OS 5 uARM IAR ARM GCC_ARM ARMC5
LPC1768 Supported Supported Supported Supported Supported Supported -

Supported targets: 1
Supported toolchains: 4

Using the mbed serial terminal
mbed sterm
and connecting to the LPC1768 board; I can reset from this terminal but I still cannot output anything to sterm, CoolTerm or Putty.

Hoping you can help with this.

I have re-run the test program you suggested in your first response and pasted the log output below.

Output from cpu-stats.log:

[1575134137.39][HTST][INF] host test executor ver. 0.0.10
[1575134137.39][HTST][INF] copy image onto target…
1 file(s) copied.
[1575134141.41][MBED][WRN] Target ID not found: Skipping flash check and retry
[1575134141.50][HTST][INF] starting host test process…
[1575134141.84][CONN][INF] starting connection process…
[1575134141.84][CONN][INF] notify event queue about extra 60 sec timeout for serial port pooling
[1575134141.84][CONN][INF] initializing serial port listener…
[1575134141.85][SERI][INF] serial(port=COM3, baudrate=9600, read_timeout=0.01, write_timeout=5)
[1575134141.85][SERI][INF] reset device using ‘default’ plugin…
[1575134141.86][HTST][INF] setting timeout to: 60 sec
[1575134142.11][SERI][INF] waiting 1.00 sec after reset
[1575134143.11][SERI][INF] wait for it…
[1575134143.11][SERI][TXD] mbedmbedmbedmbedmbedmbedmbedmbedmbedmbed
[1575134143.12][CONN][INF] sending up to 2 __sync packets (specified with --sync=2)
[1575134143.12][CONN][INF] sending preamble ‘fb5fe8bc-38dd-4b2b-b876-079f99dea266’
[1575134143.12][SERI][TXD] {{__sync;fb5fe8bc-38dd-4b2b-b876-079f99dea266}}
[1575134148.12][CONN][INF] Reset the part and send in new preamble…
[1575134148.12][SERI][INF] reset device using ‘default’ plugin…
[1575134148.39][SERI][INF] waiting 1.00 sec after reset
[1575134149.39][SERI][INF] wait for it…
[1575134149.39][CONN][INF] resending new preamble ‘ca76689e-0531-4b9e-8882-2c3b465ecb3c’ after 5.00 sec
[1575134149.39][SERI][TXD] {{__sync;ca76689e-0531-4b9e-8882-2c3b465ecb3c}}
[1575134149.42][HTST][ERR] None
[1575134149.42][HTST][WRN] stopped to consume events due to __notify_sync_failed event
[1575134149.43][HTST][INF] __exit_event_queue received
[1575134149.43][HTST][INF] test suite run finished after 7.57 sec…
[1575134149.43][HTST][INF] CONN exited with code: 0
[1575134149.43][HTST][INF] No events in queue
[1575134149.43][HTST][INF] host test result() call skipped, received: sync_failed
[1575134149.43][HTST][WRN] missing __exit event from DUT
[1575134149.43][HTST][INF] calling blocking teardown()
[1575134149.44][HTST][INF] teardown() finished
[1575134149.44][HTST][INF] {{result;sync_failed}}

Hello girrion,

Does your LPC1768 board use the latest firmware?

Hello @hudakz,
The board has the latest firmware (141212) and flashes programs with no difficulty, both from the online and off line compilers. Additional programs such as “Use the U and D keys to make LED1 brighter or dimmer” from the “Board to PC communication over USB” manual function as expected, but no text data can be sent to a terminal e.g. Putty, CoolTerm or sterm. Interestingly each time I disconnect from a terminal and reconnect, the terminal displays the following $$$$10100f2ea3eced51bdc9897acd2f201d7596, which seems to be “target_id_usb_id”: “10100f2ea3eced51bdc9897acd2f201d7596”.

I need to resolve this issue quickly, so any help you can offer will be greatly appreciated.

Best regards

Some people complainded that serial port worked only when the LPC1768 was plugged into a USB port on the back of the PC’s motherboard.

Have tried various USB ports with no luck. I have also tried re-numbering the COM port, again with no positive result.

Hi @maygup01,
Have you had an opportunity to review the information I have posted?
I have had no luck resolving this issue of serial to pc comms (print output to screen) and would really appreciate your input.

Best regards