• Please review our updated Terms and Rules here

CBM BASIC 32k PET Memory usage in Immediate mode-question.

Hugo Holden

Veteran Member
Joined
Dec 23, 2015
Messages
4,813
Location
Australia
I had read that in immediate mode, that BASIC does not use any (user) memory. Presumably it must use some of the screen memory in the 2114 RAM Ic's though ?

If that were entirely true it would suggest that you could peek and poke memory immediately above address 1024 with impunity, provided only immediate mode was used.

If I write a small immediate mode program with a FOR NEXT loop to poke and print the peek values, the memory values in the zone of 1024 to a few hundred locations above that, occasionally the returned value is defective . For example poking location 1027 with 255 returns a zero, sometimes, with the immediate mode program.

However, without a loop doing the poke & peek, with just a single immediate mode poke & peek into memory at address 1027, it always appears to return the correct value from that memory location, suggesting that memory location is not defective and somehow BASIC itself has changed the memory value while executing the immediate mode loop.

It suggests that even in immediate mode only there is some sort of usage or interference to the user memory area RAM just above address 1024 by BASIC ?

If I try higher range addresses than 1024, by a few hundred locations higher, for the immediate mode program to poke & peek memory with a loop, there is no problem.

I guess it could be that there is an intermittent DRAM memory defect just at address 1027 in my DRAM for example, but that seems very unlikely.

(I'm working on an assembly language program to put just below address 1024, where the cassette buffers are, so as to fully check DRAM memory from 1024 to 32767, but it will take me a while to figure that out)
 
Back
Top