Shows how Atari Basic can be copied from ROM to RAM... Credits: https://goto10.substack.com/p/change-the-atari-basic-ready-prompt. This is my version of the code from the link mentioned.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; Copys Basic from ROM into RAM. | |
; | |
; Allows one to change Atari Basic, e.g. change ready prompt etc. | |
; | |
; Initial idea: https://goto10.substack.com/p/change-the-atari-basic-ready-prompt | |
; | |
; B.Fritz 10/2022 | |
; --------------------------------------------------------------------------------- | |
; Some addresses to play with: | |
; Ready promt starts at: 48499 | |
; | |
org $0600 | |
lda #0 | |
sta 204 | |
lda #160 ; Basic starts here => 40960 | |
sta 205 | |
ldy #0 | |
ldx #32 ; 32 pages => 8192 bytes. | |
loop | |
lda (204),y ; This does the trick: Copy one byte from ROM to the same addrress in RAM | |
pha ; Get byte from ROM | |
lda #255 ; Basic off | |
sta $d301 | |
pla ; Write back to RAM | |
sta (204),y | |
lda #253 ; Basic on | |
sta $d301 | |
iny | |
bne loop | |
inc 205 | |
dex | |
bne loop ; Repeat until all 32 pages are done. | |
; | |
; Example on how to change Atari Basic in RAM | |
; | |
lda #255 ; Basic off | |
sta $d301 | |
ldy #0 ; Change prompt. | |
ldx #5 | |
l2 | |
lda prompt,y | |
sta 48498,x | |
iny | |
dex | |
bne l2 | |
; | |
; Activates Basic rom and returns.... | |
; To activate in- ram- basic type Poke 54017,255. | |
; To return to in- rom- version type Poke 54017,253 | |
; | |
rts | |
; | |
; Some Data | |
; | |
prompt | |
.byte 'Ok ' |
Author
codingbychanche
commented
Oct 16, 2022
Switching between Atari Basic in ROM and its customized version in RAM....
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment