On 7/5/2019 7:27 PM, Christopher Head wrote:
> On July 3, 2019 8:11:05 AM PDT, Leonard Crestez <[email protected]>
> wrote:
>> It would make sense to switch mdX to LOG_
>
> I disagree. I think it doesn’t make sense for the output of mdX to go
> everywhere. It should only go to the connection that requested it. If I have
> two connections open (e.g. due to debugging two processors in a JTAG chain),
> it would be extremely confusing to see mdX output showing up in the
> connection for the other processor!
Having output only go to one connection makes sense. As far as I can
tell this can be done by either:
* command_output_text which is not capturable
* return a string, which seems unwieldy.
I want to write a TCL proc which can be called from gdb or telnet and
which prints output to the "current connection" and this doesn't seem to
be possible. Maybe output is considered bad practice and I should
convert all the "echo" to a bunch of string appends?
Alternatively openocd could create a custom TCL channel called "client"
and make "puts client" only display to the current client. JimTcl does
not seems to expose channel-related APIs but "stdout/stderr" are just
procs so output could be redirected via Jim_RenameCommand.
--
Regards,
Leonard
_______________________________________________
OpenOCD-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openocd-devel