aboutsummaryrefslogtreecommitdiff
path: root/build/assembly
diff options
context:
space:
mode:
authorDominic Matarese <dominicmatarese@gmail.com>2021-07-12 16:21:43 +0000
committerDominic Matarese <dominicmatarese@gmail.com>2021-07-12 16:21:43 +0000
commiteb4fbe2ebdd44dbf9c604553f2ef053d0360dd41 (patch)
tree6bf8a5ed4a3e892a5155edab06899a354085627e /build/assembly
required first commitHEADmaster
Diffstat (limited to 'build/assembly')
-rw-r--r--build/assembly45
1 files changed, 45 insertions, 0 deletions
diff --git a/build/assembly b/build/assembly
new file mode 100644
index 0000000..196c19d
--- /dev/null
+++ b/build/assembly
@@ -0,0 +1,45 @@
+COPY START 1000
+FIRST STL RETADR
+CLOOP JSUB RDREC
+ LDA LENGTH
+ COMP ZERO
+ JEQ ENDFIL
+ JSUB WRREC
+ J CLOOP
+ENDFIL LDA EOF
+ STA BUFFER
+ LDA THREE
+ STA LENGTH
+ JSUB WRREC
+ LDL RETADR
+ RSUB
+EOF BYTE C'EOF'
+THREE WORD 3
+ZERO WORD 0
+RETADR RESW 1
+LENGTH RESW 1
+BUFFER RESB 4096
+RDREC LDX ZERO
+ LDA ZERO
+RLOOP TD INPUT
+ JEQ RLOOP
+ RD INPUT
+ COMP ZERO
+ JEQ EXIT
+ STCH BUFFER,X
+ TIX MAXLEN
+ JLT RLOOP
+EXIT STX LENGTH
+ RSUB
+INPUT BYTE X'F1'
+MAXLEN WORD 4096
+WRREC LDX ZERO
+WLOOP TD OUTPUT
+ JEQ WLOOP
+ LDCH BUFFER,X
+ WD OUTPUT
+ TIX LENGTH
+ JLT WLOOP
+ RSUB
+OUTPUT BYTE X'05'
+ END FIRST \ No newline at end of file