[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: BASIC in ROM - Any Interest?e t



I ran into the 'syntax error' issue when the RAM wasn't being set to all 0s (removing the RAMCheck may have also removed the code to clear the RAM). The code at start up should set all RAM to zeros; then it initializes the internal working areas (all in low RAM); the RST areas; the PEEK/POKE stubs etc. The start of RAM to store the BASIC program then starts right above the internal working areas. If the RAM used to the store the BASIC program isn't cleared it finds the garbage in the RAM; assumes it part of a BASIC program; tries to see if it needs to insert a line etc. and generates the error message. 'NEW' resets the storage RAM to all 0s. Note that if there is garbage in memory higher up in RAM when the entered program gets big enough it will encounter this garbage and will again generate the off syntax error.

Near the top of the code it also sets the Z-80 board memory page registers; I'm not sure if / how this might affect the monitor or your system.

Overall it's been very stable for me running from ROM; I've let it run for hundreds of hours doing FP calculations; outputting text etc. This testing has NOT exercised every command so your millage may vary.

-Neil

On Thursday, July 24, 2014 2:11:35 PM UTC-7, Philippe Elie wrote:
Hi Neil,

Thanks to the files you kindky uploaded, I was able to run BASIC on my system. Since the monitor (John's monitor patched to run with the SIO) is stored in a 2732 in the F000-FFFF space, i changed the ORG statements to start the code at B000 (to leave lots of space to John's monitor stack, I think I could locate at C800 with no problem but it was really to make a first test). Apart from the ORG change, no significant changes : I obviously asembled it with the SCC driver, I removed the RAMcheck portion considering my specific setup, and now I am proud to see the BASIC prompt afer downloading the code in XMODEM using the monitor !
For some reason, the monitor was froaen after the XMODEM transfer completion, I was getting the prompt but could not enter a command. Probably a handshake problem, I added a SCC_INIT call just before returning to the main monitor loop, rather brute force but it now works great.
One minor issue though I have to investigate : a RUN gives systematically a syntax error, even is this is a one-line program with a REM... To run a program, I have to insert a dummy/REM line before the entry line and RUN that entry line explicitely (eg. RUN 10 if there is a dummy line say at 5).souonds like a pointer pb created by my mods...
Thanks again for your work, I am so happy to see BASIC running on my new toy !

Philippe