summaryrefslogtreecommitdiff
path: root/tool/download.tcl
diff options
context:
space:
mode:
Diffstat (limited to '')
-rwxr-xr-xtool/download.tcl (renamed from download.tcl)9
1 files changed, 4 insertions, 5 deletions
diff --git a/download.tcl b/tool/download.tcl
index 635e54b..c0dca55 100755
--- a/download.tcl
+++ b/tool/download.tcl
@@ -12,14 +12,13 @@ if {$::argc > 1} {
12 set core [lindex $::argv 0] 12 set core [lindex $::argv 0]
13} 13}
14 14
15spawn nios2-terminal --instance 0 15spawn tool/connect
16expect -ex "connected to hardware target"
17 16
18send "@[format %x [expr $core * 32768 / $wordsperline]]\n" 17send "@[format %x [expr $core * 32768 / $wordsperline]]\n"
19 18
20while {[gets stdin line] >= 0} { 19while {[gets stdin line] >= 0} {
21 send "$line\n" 20 send "$line\n"
22 expect -ex "$line" 21 expect -ex "$line\n"
23} 22}
24 23
25# It's likely we ended with a very large zero-memory operation. We want to see 24# It's likely we ended with a very large zero-memory operation. We want to see
@@ -30,5 +29,5 @@ expect -ex "?"
30send "?" 29send "?"
31expect -ex "?" 30expect -ex "?"
32 31
33send "\004" 32send "\n~."
34expect -ex "exiting due to ^D on remote" 33wait