From: MagerValp (MagerValp_at_cling.gu.se)
Date: 2003-10-29 18:48:33
Just in case someone wants to make autostarting c64 code with ca65, here's how I did it. Assemble with cl65 -t none -C autostart.cfg autostart.s. Thanks again Uz for helping me with ld65 :) I'd appreciate it if someone with "exotic" drives (ramlink, ide64, and others that patch kernal vectors) could verify that this still works. Drop me a mail in private with your findings. Thanks! ----- autostart.cfg ----- MEMORY { ZP: start = $02, size = $1a, type = rw; LOADADDR: start = $02a5, size = 2, file = %O; STARTLO: start = $02a7, size = 91, file = %O, fill = yes; STARTVECTOR: start = $0302, size = 2, file = %O; STARTHI: start = $0304, size = 16, file = %O; } SEGMENTS { LOADADDR: load = LOADADDR, type = rw; STARTLO: load = STARTLO, type = rw; STARTVECTOR: load = STARTVECTOR, type = rw; STARTHI: load = STARTHI, type = rw; ZEROPAGE: load = ZP, type = zp; } ----- ----- autostart.s ----- .segment "LOADADDR" .addr * + 2 .segment "STARTLO" init: ldx #16 : lda message-1,x jsr $ffd2 dex bne :- stx $d020 stx $d021 : sta $d800,x sta $d900,x sta $da00,x sta $db00,x inx bne :- jsr $e453 jmp * .segment "STARTVECTOR" .addr init .segment "STARTHI" message: .byte 13, "'NITSET-A TSUJ",147 ----- -- ___ . . . . . + . . o _|___|_ + . + . + . Per Olofsson, arkadspelare o-o . . . o + MagerValp_at_cling.gu.se - + + . http://www.cling.gu.se/~cl3polof/ ---------------------------------------------------------------------- To unsubscribe from the list send mail to majordomo_at_musoftware.de with the string "unsubscribe cc65" in the body(!) of the mail.
This archive was generated by hypermail 2.1.3 : 2003-10-29 18:51:15 CET