mirror of
https://github.com/hsoft/collapseos.git
synced 2024-11-18 05:38:06 +11:00
recipes/trs80: fix double line feeds
Lines should be terminated only with a CR on this system, not CRLF.
This commit is contained in:
parent
0f2b3aca24
commit
bd38d46892
@ -76,6 +76,9 @@ printnstr:
|
|||||||
pop bc
|
pop bc
|
||||||
ret
|
ret
|
||||||
|
|
||||||
|
; Prints a line terminator. This routine is a bit of a misnomer because it's
|
||||||
|
; designed to be overridable to, for example, printlf, but we'll live with it
|
||||||
|
; for now...
|
||||||
printcrlf:
|
printcrlf:
|
||||||
push af
|
push af
|
||||||
ld a, CR
|
ld a, CR
|
||||||
|
@ -151,6 +151,10 @@ A memory range dumped this way will be re-loaded at the same offset through
|
|||||||
using the `RUN` command. Therefore, you can avoid all this work above in later
|
using the `RUN` command. Therefore, you can avoid all this work above in later
|
||||||
sessions by simply typing `recv` in the DOS prompt.
|
sessions by simply typing `recv` in the DOS prompt.
|
||||||
|
|
||||||
|
Note that you might want to turn `debug` off for these commands to run. I'm not
|
||||||
|
sure why, but when the debugger is on, launching the command triggers the
|
||||||
|
debugger.
|
||||||
|
|
||||||
## Sending binary through the RS-232 port
|
## Sending binary through the RS-232 port
|
||||||
|
|
||||||
Once you're finished punching your program in memory, you can run it with
|
Once you're finished punching your program in memory, you can run it with
|
||||||
@ -186,6 +190,12 @@ If there was no error during `pingpong`, the content should be exact.
|
|||||||
Nevertheless, I recommend that you manually validate a few bytes using TRSDOS
|
Nevertheless, I recommend that you manually validate a few bytes using TRSDOS
|
||||||
debugger before carrying on.
|
debugger before carrying on.
|
||||||
|
|
||||||
|
*debugging tip*: Sometimes, the communication channel can be a bit stubborn and
|
||||||
|
always fail, as if some leftover data was consistently blocking the channel. It
|
||||||
|
would cause a data mismatch at the very beginning of the process, all the time.
|
||||||
|
What I do in these cases is start a `COMM *cl` session on one side and a screen
|
||||||
|
session on the other, type a few characters, and try `pingpong` again.
|
||||||
|
|
||||||
## Running Collapse OS
|
## Running Collapse OS
|
||||||
|
|
||||||
If everything went well, you can run Collapse OS with `g3000<space>`. You'll
|
If everything went well, you can run Collapse OS with `g3000<space>`. You'll
|
||||||
|
@ -18,6 +18,9 @@
|
|||||||
.equ STDIO_PUTC trs80PutC
|
.equ STDIO_PUTC trs80PutC
|
||||||
.inc "stdio.asm"
|
.inc "stdio.asm"
|
||||||
|
|
||||||
|
; The TRS-80 generates a double line feed if we give it both CR and LF.
|
||||||
|
.equ printcrlf printcr
|
||||||
|
|
||||||
; *** BASIC ***
|
; *** BASIC ***
|
||||||
|
|
||||||
; RAM space used in different routines for short term processing.
|
; RAM space used in different routines for short term processing.
|
||||||
@ -44,4 +47,11 @@ init:
|
|||||||
call basInit
|
call basInit
|
||||||
jp basStart
|
jp basStart
|
||||||
|
|
||||||
|
printcr:
|
||||||
|
push af
|
||||||
|
ld a, CR
|
||||||
|
call STDIO_PUTC
|
||||||
|
pop af
|
||||||
|
ret
|
||||||
|
|
||||||
RAMSTART:
|
RAMSTART:
|
||||||
|
Loading…
Reference in New Issue
Block a user