Hello,
This is a continuation of my questions on irc. There were some recent
changes regarding how OpenOCD handles command output and as far as I can
tell the default was switched so that all commands will "return" instead
of "display" by default.
This doesn't make much sense to me because most commands have
human-readable output which is not intended for machine consumption. For
example "mdw" does pretty alignments, "targets" shows a table and "reg"
shows register names. In particular it breaks a bunch of scripts I have
which look like this:
proc dump_myip {base} {
echo "MYIP_REG1:"
mdw [expr $base + 0x000]
echo "MYIP_REG1:"
mdw [expr $base + 0x012]
echo "MYIP_REG1:"
mdw [expr $base + 0x032]
}
It's not terribly difficult to replace all "mdw *" with "echo [mdw *]"
but it seems strange. The "mdw" command stands for "Memory Display Word"
so my expectation is that it would "display" and other commands (like
mem2array) should be used to fetch memory values for manipulation inside
TCL. The output of "mdw" looks like "0x30360800: 00824110" so a regexp
would be required to strip the header and prepend 0x to the actual value.
Doesn't it make more sense for most commands to "display" instead?
--
Regards,
Leonard
_______________________________________________
OpenOCD-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openocd-devel