AnsweredAssumed Answered

How to debug a program via serial port?

Question asked by Alaa Masalha on Aug 25, 2016
Latest reply on Aug 29, 2016 by Alaa Masalha

I'm trying to debug an app sitting on my IMX6 board which is connected to PC by serial port, using gdb and gdbserver like described here and here.


I connect to the board by putty and run the following:

gdbserver --multi :2345

And I get:

Listening on port 2345

Then I run the following in Windows cmd (on the PC that the board is connected to via serial port):


(gdb) target extended :2345

And after a few seconds, I get:

:2345: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

I also tried COM17:2345 instead of just :2345 and I got:

COM17:2345: No such file or directory.

(COM17 is the serial port I'm connected to as it appears in Device Manager)