Hi,
I have a following question.
Question
Does anyone know what might cause execution of certain command to throw exception when called via jlink.exec_command()?
|
def exec_command(self, cmd): |
Context
I'll dig deeper into it tomorrow, but for now I've observed that commands such as Regs, Go or Mem end up throwing exception.
Note: I call the above ones only after jlink.open() and jlink.connect() were called (doesn't matter whether target was halted beforehand or not)
Calling Halt seem to work fine though. Other configuration like commands that get executed before connecting to target work correctly (like JLinkDevicesXMLPath).
Source of confusion
Here, I'm a bit at a loss, because JLink SDK Guide states the following:
- JLINKARM_ExecCommand() from the JLINK DLL offers a possibility to execute several command strings.
- "For a detailed description of all available commands strings please refer to the J-Link User Manual (UM08001)"
Initially I thought that all of the commands from jlink commander were supposed to be working via jlink.exec_command(), but then I realized those are not COMMAND STRINGS that you should pass to the aforementioned DLL.
Command strings are defined here.
But that does not explain why Halt works and Go does not (both come from JLink Commander set of commands).
I searched forums and web looking for answer but didn't find any.
BR,
Michael
Hi,
I have a following question.
Question
Does anyone know what might cause execution of certain command to throw exception when called via jlink.exec_command()?
pylink/pylink/jlink.py
Line 946 in a2172aa
Context
I'll dig deeper into it tomorrow, but for now I've observed that commands such as Regs, Go or Mem end up throwing exception.
Note: I call the above ones only after jlink.open() and jlink.connect() were called (doesn't matter whether target was halted beforehand or not)
Calling Halt seem to work fine though. Other configuration like commands that get executed before connecting to target work correctly (like JLinkDevicesXMLPath).
Source of confusion
Here, I'm a bit at a loss, because JLink SDK Guide states the following:
Initially I thought that all of the commands from jlink commander were supposed to be working via jlink.exec_command(), but then I realized those are not COMMAND STRINGS that you should pass to the aforementioned DLL.
Command strings are defined here.
But that does not explain why Halt works and Go does not (both come from JLink Commander set of commands).
I searched forums and web looking for answer but didn't find any.
BR,
Michael