diff options
Diffstat (limited to 'testing/tcl_server.tcl')
-rw-r--r-- | testing/tcl_server.tcl | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/testing/tcl_server.tcl b/testing/tcl_server.tcl index c5ec2291..2e229c10 100644 --- a/testing/tcl_server.tcl +++ b/testing/tcl_server.tcl @@ -1,15 +1,15 @@ -# Simple tcl client to connect to openocd
-puts "Use empty line to exit"
-set fo [socket 127.0.0.1 6666]
-puts -nonewline stdout "> "
-flush stdout
-while {[gets stdin line] >= 0} {
- if {$line eq {}} break
- puts $fo $line
- flush $fo
- gets $fo line
- puts $line
- puts -nonewline stdout "> "
- flush stdout
-}
-close $fo
+# Simple tcl client to connect to openocd +puts "Use empty line to exit" +set fo [socket 127.0.0.1 6666] +puts -nonewline stdout "> " +flush stdout +while {[gets stdin line] >= 0} { + if {$line eq {}} break + puts $fo $line + flush $fo + gets $fo line + puts $line + puts -nonewline stdout "> " + flush stdout +} +close $fo |