> Hello,
>
> If I understood correctly, the external scripting is to be done by
> submitting commands to TCL server.
More precisely: by submitting tcl. The tcl can invoke OpenOCD commands.
>So at least result of the TCL command processing itself
> shall be returned in defined format, or have I missed something?
What is returned is simply the output of the tcl command.
The problem is that code has to *parse* the output from tcl.
Tcl can more easily parse tcl output than Lua could(I guess anyway).
E.g. an array is returned as a string in Tcl from a procedure. Everything
in Tcl is a string.
{1 2 3 4 5}
So on a host PC running tcl one would simply use the returned string
as an array directly. No conversion or parsing necesary.
Lua would, however, need to parse the returned string into an array.
My thinking is that it is easier to convert the array into Lua speak
from Jim Tcl than to parse Tcl array in Lua.
However, the code that would reformat tcl strings into Lua speak is
part of the application(running inside OpenOCD) rather than part
of the API.
--
Øyvind Harboe
http://www.zylin.com/zy1000.html
ARM7 ARM9 XScale Cortex
JTAG debugger and flash programmer
_______________________________________________
Openocd-development mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/openocd-development