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.
5 years, 11 months ago.
Can I debug this board with pyOCD?
I have just seen that pyOCD supports stlinkv2 and installed version 0.14.3 using pip. I know that the board isn't supported directly, but wanted to try using GDB to debug code. However, when I try to start pyOCD using the generic cortex_m target I get an exception. Is this expected to be possible (and I'm missing something) or is this a non-starter?
The exception is as below:
0000830:INFO:board:Target type is cortex_m 0000846:INFO:dap:DP IDR = 0x2ba01477 0000857:ERROR:__main__:uncaught exception: 0 Traceback (most recent call last): File "/home/alan/Documents/mbed_test/lib/python3.6/site-packages/pyocd/__main__.py", line 309, in run self._commands[self._args.cmd]() File "/home/alan/Documents/mbed_test/lib/python3.6/site-packages/pyocd/__main__.py", line 490, in do_commander PyOCDCommander(self._args, cmds).run() File "/home/alan/Documents/mbed_test/lib/python3.6/site-packages/pyocd/tools/pyocd.py", line 548, in run status = CORE_STATUS_DESC[self.target.get_state()] File "/home/alan/Documents/mbed_test/lib/python3.6/site-packages/pyocd/core/coresight_target.py", line 270, in get_state return self.selected_core.get_state() File "/home/alan/Documents/mbed_test/lib/python3.6/site-packages/pyocd/core/coresight_target.py", line 65, in selected_core return self.cores[self._selected_core] KeyError: 0
Question relating to:
1 Answer
5 years, 11 months ago.
Hi I advice you to post the question in the github repo
https://github.com/mbedmicro/pyOCD/issues
Regards,
Jerome