summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Blake Kongslie2022-03-27 16:58:38 -0700
committerJulian Blake Kongslie2022-03-27 16:58:38 -0700
commit4861339500948bd7e0953ec9eba3ad21e1133625 (patch)
tree1c67e681753657bb25a336bafb270a78cff99954
parentReduce internal clock speed to 30MHz. (diff)
downloadmultipdp8-4861339500948bd7e0953ec9eba3ad21e1133625.tar.xz
Attempt to make somewhat less error-prone downloads.
Diffstat (limited to '')
-rwxr-xr-xdownload.tcl2
-rw-r--r--tool/p8bin2uart.c9
2 files changed, 5 insertions, 6 deletions
diff --git a/download.tcl b/download.tcl
index 31d4c82..635e54b 100755
--- a/download.tcl
+++ b/download.tcl
@@ -1,5 +1,7 @@
1#!/usr/bin/env expect 1#!/usr/bin/env expect
2 2
3set timeout 3600
4
3set core 0 5set core 0
4set wordsperline 1 6set wordsperline 1
5 7
diff --git a/tool/p8bin2uart.c b/tool/p8bin2uart.c
index 14cb207..944227a 100644
--- a/tool/p8bin2uart.c
+++ b/tool/p8bin2uart.c
@@ -131,7 +131,7 @@ load(FILE *fp)
131 return v; 131 return v;
132} 132}
133 133
134#define MAX_LINE_SIZE 1023 134#define MAX_LINE_SIZE 63
135 135
136char buf[MAX_LINE_SIZE * 2] = {0}; 136char buf[MAX_LINE_SIZE * 2] = {0};
137 137
@@ -186,11 +186,8 @@ dump(unsigned int wordsperline)
186 print("!%x ", (unsigned int)((a - nextaddr) / wordsperline)); 186 print("!%x ", (unsigned int)((a - nextaddr) / wordsperline));
187 } 187 }
188 print("="); 188 print("=");
189 for (uint_fast32_t i = 0; i < wordsperline; ++i) { 189 for (uint_fast32_t i = 0; i < wordsperline; ++i)
190 if (i != 0) 190 print(i == 0 ? "%x" : ":%04x", (unsigned int)words[i]);
191 print(":");
192 print("%04x", (unsigned int)words[i]);
193 }
194 print(" "); 191 print(" ");
195 nextaddr = a + wordsperline; 192 nextaddr = a + wordsperline;
196 } 193 }