initial commit

This commit is contained in:
Moon Man 2022-07-24 17:34:51 -07:00
commit ab4ac6e89c
2 changed files with 44 additions and 0 deletions

41
helloworld.asm Normal file
View File

@ -0,0 +1,41 @@
KERNAL_CLEAR_SCREEN = $e544 ; KERNAL ROM routine.
VICSCN = $0400 ; VIC-II Screen Video Matrix, 1024 (int).
* = $8000
.word coldstart ; coldstart vector
.word warmstart ; warmstart vector
.byte $C3,$C2,$CD,$38,$30 ; "CBM8O". Autostart string
coldstart
sei
stx $d016
jsr $fda3 ;Prepare IRQ
jsr $fd50 ;Init memory. Rewrite this routine to speed up boot process.
jsr $fd15 ;Init I/O
jsr $ff5b ;Init video
cli
warmstart
; Insert your code here
jsr KERNAL_CLEAR_SCREEN
; read string by byte into vram until null byte
ldx #0
loop
lda my_string,x
cmp #$00
beq bail
sta VICSCN,x
inx
jmp loop
bail
; pretty colors
inc $d020
jmp *-3
.enc "screen"
my_string .null "HELLO WORLD!"
.enc "none"
* = $9fff ; fill up to 8k or cartconv will fail
.byte 0

3
make.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh
64tass helloworld.asm -o helloworld.prg
cartconv -t normal -n "Hello World" -i helloworld.prg -o helloworld.crt