.MPL LDY #0 \ Set Y = 0 to act as a byte counter LDX #2 \ Set X = 2 to act as a page counter .MVBL LDA LOADcode,Y \ Copy the Y-th byte of LOADcode to the Y-th byte of STA LOAD,Y \ LOAD (this instruction gets modified below, so this is \ a single-use, self-modifying routine) INY \ Increment the byte counter BNE MVBL \ Loop back to MVBL to copy the next byte until we have \ copied a whole page INC MVBL+2 \ Increment the high byte of the LDA instruction above, \ so it now points to the next page INC MVBL+5 \ Increment the high byte of the STA instruction above, \ so it now points to the next page DEX \ Decrement the page counter in X BNE MVBL \ Loop back to MVBL to copy the next page until we have \ copied X pages JMP ENTRY2 \ Jump to ENTRY2 to continue the loading processName: MPL [Show more] Type: Subroutine Category: Utility routines Summary: Move two pages of memory from LOADcode to LOAD and jump to ENTRY2Context: See this subroutine in context in the source code References: This subroutine is called as follows: * Elite loader (Part 1 of 2) calls MPL
[X]
Entry point ENTRY2 in subroutine Elite loader (Part 2 of 2) (category: Loader)
Re-entry point to continue the loading process from the MPL routine
[X]
Subroutine LOAD (category: Copy protection)
This code accesses the disc directly (not used in this version as disc protection is disabled)
[X]
Subroutine LOADcode (category: Copy protection)
LOAD routine, bundled up in the loader so it can be moved to &0400 to be run
[X]
Label MVBL is local to this routine