On OSX by using the same FRDM-K22F board and Onboard OpenSDA/J-Link, with KDS 3.2 I can debug w/o problem, but with MCUXpresso 10 I can't. It seems MCUX doesn't provide proper commands to arm-none-eabi-gdb.
I tried the suggestion to delete existing debug configuration and recreate one from Quickstart panel as the following discussion, but it didn't help:
Cannot debug FDRM-K64F via J-link.
See the attachment jlink_setting.png for the debugger setup.
J-Link GDB server connected successfully to the board, and started listening to localhost port 2331.
But arm-none-eabi-gdb didn't send the following command (existed in KDS):
target remote localhost:2331
and as a result MCUX aborts the debugging, shows a misleading message of "Cannot get Jtag device".
Here's the gdb trace:
280,936 2-gdb-version
280,937 ~"GNU gdb (GNU Tools for ARM Embedded Processors) 7.12.0.20161204-git\n"
280,938 ~"Copyright (C) 2016 Free Software Foundation, Inc.\n"
280,938 ~"License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\nThis is fre\
e software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitt\
ed by law. Type \"show copying\"\nand \"show warranty\" for details.\n"
280,938 ~"This GDB was configured as \"--host=x86_64-apple-darwin10 --target=arm-none-eabi\".\nType \
\"show configuration\" for configuration details."
280,938 ~"\nFor bug reporting instructions, please see:\n"
280,938 ~"<http://www.gnu.org/software/gdb/bugs/>.\n"
280,938 ~"Find the GDB manual and other documentation resources online at:\n<http://www.gnu.org/soft\
ware/gdb/documentation/>.\n"
280,938 ~"For help, type \"help\".\n"
280,938 ~"Type \"apropos word\" to search for commands related to \"word\".\n"
280,938 2^done
280,938 (gdb)
280,939 3-environment-cd /Users/xxx/tmp/workspaces/mcuxpresso/frdmk22f_hellodemo_apps_hello_worl\
d
280,940 3^done
280,940 (gdb)
280,940 4-gdb-set breakpoint pending on
280,941 4^done
280,941 (gdb)
280,942 5-enable-pretty-printing
280,942 5^done
280,942 (gdb)
280,943 6-gdb-set python print-stack none
280,943 6^done
280,943 (gdb)
280,944 7-gdb-set print object on
280,944 7^done
280,944 (gdb)
280,944 8-gdb-set print sevenbit-strings on
280,945 8^done
280,945 (gdb)
280,945 9-gdb-set charset ISO-8859-1
280,946 9^error,msg="Cannot convert between character sets `UTF-32' and `ISO-8859-1'"
280,946 (gdb)
280,946 10-gdb-set dprintf-style gdb
280,947 10^done
280,947 (gdb)
280,947 11-gdb-set auto-solib-add on
280,947 11^done
280,947 (gdb)
280,950 12-gdb-exit
280,951 12^exit
If I do everything from the command line, by providing "target remote localhost:2331", etc to arm-none-eabi-gdb, debugging is fine.
Also KDS's GDB Client Setup is more flexible than MCUX GDB Client Settings.
KDS has Other options, plus commands, while in MCUX there is no place to enter commands and options.
See kds.png.
Any suggestions how to address this?
Thanks