Added code for cls.com and start of ver.com
All checks were successful
Run test asserts / Test-Asserts (push) Successful in 16s

This commit is contained in:
Willem Cazander 2024-07-14 16:43:39 +02:00
parent 48de748ae8
commit de377cf420
2 changed files with 46 additions and 13 deletions

View file

@ -1,18 +1,20 @@
CALLSLT .equ 0x001C
EXPTBL .equ 0xFCC1
BIOS_CLS .equ 0x00C3
.area _CODE .area _CODE
JP MAIN JP MAIN
.db 0x0D .db 0x0D
.db 0x0D,0x0A .db 0x0D,0x0A
.str "TODO: MSX-DOS1 cls command." .str "MSX-DOS1 cls command."
.db 0x0D,0x0A .db 0x0D,0x0A
.db 0x1A .db 0x1A
; TODO: code
;
; SUPPORT: cls
; - clear the screen
; - exit
MAIN: MAIN:
RET XOR A
LD IY,(EXPTBL)
LD IX,#BIOS_CLS
JP CALLSLT
.area _DATA .area _DATA

View file

@ -1,18 +1,49 @@
BDOS .equ 0x0005
_DOSVER .equ 0x6F
_STROUT .equ 0x09
.area _CODE .area _CODE
JP MAIN JP MAIN
.db 0x0D .db 0x0D
.db 0x0D,0x0A .db 0x0D,0x0A
.str "TODO: MSX-DOS1 ver(sion) command." .str "MSX-DOS1 ver(sion) command."
.db 0x0D,0x0A .db 0x0D,0x0A
.db 0x1A .db 0x1A
; TODO: code
;
; SUPPORT: ver
; - Prints DBOS version
; - exit
MAIN: MAIN:
XOR A
LD DE,#TXT_DOS
LD C,#_STROUT
CALL BDOS
XOR A
LD C,#_DOSVER
CALL BDOS
LD A,B; DOS VERSION
CP #1
LD C,#_STROUT
LD DE,#TXT_DOS1
JP C,BDOS
; TODO: print full version
; BC = MSX-DOS kernel version as BCD 0234h
; DE = MSXDOS2.SYS version number
ADD #48
LD DE,#TXT_VERSION
LD (DE),A
XOR A
LD C,#_STROUT
CALL BDOS
RET RET
TXT_DOS:
.str "Dos version $"
TXT_DOS1:
.str "1$"
TXT_VERSION:
.str "X.XX$"
.area _DATA .area _DATA