Re: Auto Boot

From: silverdr_at_wfmh.org.pl
Date: Fri, 5 Apr 2013 17:22:27 +0200
Message-Id: <0C1DED7C-79A1-4DDB-A9EE-4447B04276B5@wfmh.org.pl>
Meaning you have to replace both BASIC and KERNAL anyway. Great job in any case!

As for the filename - if you can fit ":*" it should work properly, loading the first file, which is what IMHO would make it most useful.

-- 
SD!

On 2013-04-05, at 17:09, Ted wrote:

> Found a spot to wedge in the boot loader in the RESET routine, right after BASIC  is initialized and before the COMMODORE 64 message is printed.
> I also found another unused area to fit my wedge into. AND IT WORKS!!!
> 
> Full source will be on http://www.minows.net, give me time to upload the latest source and binaries
> 
> 
> THE QUESTION NOW IS...
> 
>    What file name should I load and run?
> 
> I used '-' instead of '*'.
> 
> '*' seems kind of random and you have to make sure the 1st file is the one you want to boot.
> 
> 
> 
> First I jump to my wedge BY REPLACING THE PRINT MESSAGE JUMP WITH MY JUMP
> 
> ; ----------------------------------------------------------------------------
> ; NORMAL HARD RESET ROUTINE
> LE394:  JSR     LE453             ; INIT VECTORS
>        JSR     LE3BF             ; INIT BASIC
> .IF (CS00004 = 1 || CS99999 = 1)
>        JMP     BOOTWEDGE         ; THIS IS WHERE I GRAB CONTROL
> .ELSE
>        JSR     LE422             ; PRINT START MESSAGES
> .ENDIF
> LE39D:  LDX     #$FB
>        TXS
>        BNE     LE386
> 
> 
> 
> THEN I CALL MY AUTOBOOT ROUTINE THEN JUMP BACK TO THE RESET ROUTINE. IT SEEMS TO WORK FINE
> 
> 
> ; ----------------------------------------------------------------------------
> ; UNUSED
> .IF (CS00004 = 1 || CS99999 = 1)
> BOOTWEDGE:
>        JSR     LE422           ; PRINT START MESSAGES THAT i JUST OVERWROTE IN THE RESET ROUTINE
>        JSR     AUTOBOOT        ; CALL MY FILE LOADER
>        JMP     LE39D           ; JUMP BACK TO THE RESET ROUTINE SO IT CAN FINISH
>        .RES $E4D3 - *, $AA
> .ELSE
>        .RES $E4D3 - *, $AA
> .ENDIF
> 
> 
> 
> THIS IS MY AUTO BOOT ROUTINE
> 
> 
> ; UNUSED
> .IF (CS00003  = 1 || CS99999 = 1)
> ; CODE TO AUTO BOOT AND RUN A FILE CALLED 'BOOT' FROM DEVICE 8
> KEYBUF := $0277
> KEYCNT := $C6
> AUTOBOOT:
>        LDX     #$00
> BOOTLOOP:
>        LDA     BOOTTEXT,X      ; GET NEXT BOOT TEXT BYTE
>        BEQ     BOOT_OUT        ; DONE IF ZERO
>        STA     KEYBUF,X        ; PUT IT IN THE KEYBOARD BUFFER
>        INX                     ; POINT X TO NEXT BYTE IN BOOT TEXT
>        JMP     BOOTLOOP        ; REPEAT THE LOOP
> BOOT_OUT:
>        STX     KEYCNT          ; SAVE THE BYTE COUNT
>        RTS                     ; RETURN TO CALLER
> BOOTTEXT:   .BYTE   "L", 'O'+$80, '"', "-", '"', ",8", $0D, "R", 'U'+$80, $0D, $00
> .ELSE
>       .RES    $BF71 - *, $AA
> .ENDIF
> 
> 

-- 
SD!


       Message was sent through the cbm-hackers mailing list
Received on 2013-04-05 16:00:55

Archive generated by hypermail 2.2.0.