On Fri, Jul 07, 2017 at 10:11:06AM +0000, Baltissen, GJPAA (Ruud) wrote: >I found this in: http://www.zimmers.net/cbmpics/cbm/vic/memorymap.txt >>NOTE: When additional memory is added to block 1 (and 2 and 3), the >>KERNAL relocates the following things for BASIC: >I used my auto disassembler on the ROM and found this: Well, does the ROM run any BASIC code? Of course programs are free to use the available 1 kilonibble color RAM in any way they please. Only the BASIC and KERNAL are using one half (or actually 22*23=506 nibbles) of it. Actually, if you configure the screen to have very many characters per line and very many lines, you should be able to use almost all of the color RAM, especially on the 6561 (PAL) where the visible picture area of the video signal is larger than on the 6560 (NTSC). Hmm, is Pasi Ojala still on this list? He probably implemented some crazy CPU-intensive graphics modes for the Vic-20, programmatically changing the VIC-I registers on every raster line. That would easily use all of the color RAM even with a smaller picture area. >The above means data is written to the NORMAL location for the screen >memory and colour RAM. But the text says that this RAM is only used if >there is NO extra RAM on board. Did I miss something or is the text >wrong? You missed the above. Actually, if you duplicate some of the KERNAL reset code, you can let BASIC think that there is no extra memory even if you had it there starting at BLK1 ($2000). You could also type some POKEs after RESET to "downgrade to unexpanded" while having a 3k or 8k+ RAM expansion plugged in. >The *003C should be *033C. Yes, definitely, the tape buffer is at $33C. Even without knowing this, it is kind of obvious, because the memory map is in ascending order of memory address. On a related note, I wonder how many cartridges there are that invoke the BASIC interpreter to run code straight from the ROM? I have seen at least one such cartridge for the Vic-20. With this trick, you will be able to use all of the precious internal RAM from $1000 to $1dff or $1200 to $1fff for BASIC variables while keeping the program code in the ROM. It is a bit like the separation of program memory and RAM on Harvard architectures like the Atmel AVR: you would want to keep constant in program memory, not waste the small RAM by copying into it. On the Commodore 64, this trick would make little sense, because the cartridge ROM would make internal RAM or ROM inaccessible, especially in those configurations that you would need when using the BASIC interpreter. Maybe you could have a simple cartridge that keeps the BASIC code at $8000-$9fff and the BASIC variables at $0800-$7fff, but the only "benefit" might be copy protection. Marko Message was sent through the cbm-hackers mailing listReceived on 2017-07-07 11:00:02
Archive generated by hypermail 2.2.0.