Login
Back to forumSee the full topicGo to last reply

Posted By

gerliczer
on 2009-01-12
05:33:31
 Re: Defining a custom charset from BASIC

I checked the code again. It is probably safe to skip the saving of zero page variables. The program in its presented form actually copies 258 bytes but as the two areas overlap the number of copied bytes is 257. To copy exactly 256 one has to poke 127 to location 2024. When calling the routine in a loop one has to keep in mind not to forget resetting the Y register (2036) if less than 256 bytes were copied.
Finding the routine was a piece of cakehappy First I fired up YAPE and checked the reset routine as it must copy a lot for initializing the machine but found nothing. Then I opened our "Holy Bible" (http://plus4world.powweb.com/publications/PLUS4_Belso_Felepitese) and paging through the ROM disassembly looked for KERNAL routines that do some copying. I came across the cursor control section and found the screen scrolling part.
The backup variable names of zero page values were chosen to help me remember what to put where for restoring the original state. I never intended them to be funny but probably that's what really makes them that.
Calling this solution some kind of Holy Grail is a bit of exaggeration. This poking and calling undocumented "APIs" could be called anything but elegant. Saying efficient or butt ugly is much better. Loading the charset form a separate file is way closer to elegant.



Back to top


Copyright © Plus/4 World Team, 2001-2024