Comments (6)
I have been reworking all this. Branch https://github.com/commanderx16/x16-rom/tree/basic_geos has the following (rough) zero page allocation:
- $00-$7F available to the user
- $80-$8D used by the KERNAL
- $8E-$9E used by CBDOS
- $9F-$FF used by BASIC
from x16-rom.
I am having similar problems with my porting of durexforth, still struggling to get the
kernel to run properly. It temporary reuses a few addresses in the zero page that ought not to cause problems for the machine if they work and are used as they were in a C64 :)
BASIC RND function seed value ($8B, $8C, $8D, $8E)
Tape Error Log ($9E, $9F)
from x16-rom.
It appears to be a fault in the build process (or it's already been corrected). The code overwriting $02 is in kernal/joystick.s, at the end, where it uses a zp location "j0tmp" which is allocated to segment "ZPKERNAL" which should be in the "lanes".
from x16-rom.
I have no idea how that segmenting system works ... whether it could possibly wrap around on overflow if they have overflowed $FF and there are locations that Basic hasn't put a claim on. Maybe declaring a 3 byte segment at $00-$02 ZPUSER could block such an overflow.
But there eventually needs to be a documented section of RAM that can be used by code called from Basic with SYS ... even if it is provided in a set of Basic locations that are not storing persistent data at the time of a SYS call ... and there needs to be SOME machine language routine ZP locations that can be used by userland interrupt routines no matter what the state of Basic may happen to be ... which is what $02 and $FB, $FC, $FD, $FE were for the C64.
from x16-rom.
I have no idea how that segmenting system works ... whether it could possibly wrap around on overflow if they have overflowed $FF, and there are locations that BASIC hasn't put a claim on.
The linker (ld65) doesn't wrap-around; and, it doesn't overflow. Instead, it complains that the memory area is too big.
from x16-rom.
That's lovely ... with that ZP allocation, I could have my Forth return stack on the zero page while still allowing it to cooperate with Basic ... which is a big dividing line for C64 Forth models.
from x16-rom.
Related Issues (20)
- LOAD and SAVE should respect current BANK HOT 3
- DOS unit tests 07 and 08 (C: copy/concatenate) are broken HOT 4
- BASIC overflow/hang in SQR() HOT 4
- Screen editor changes colors when deleting across line boundary HOT 3
- GEOS won't start HOT 3
- CMDR-DOS: Input corruption when programmatically reading from a directory listing "$" (SA 0) and another file (SA 2) HOT 4
- LOG(2) inaccurate (slightly) HOT 4
- To match official Perixx keyboard keycaps, treat scroll lock as 40/80 switch in BASIC instead of (or in addition to) F4 HOT 1
- memory_decompress not working when decompressing to VRAM HOT 2
- RFE: method for fetching the current working directory HOT 4
- Cursor not cleared in the BASIC editor on startup HOT 1
- [DOS] Rename across directories on FAT32 has incorrect and possibly undefined behavior HOT 1
- The future of X16 NMI behavior HOT 1
- Changes to basic\token2.s doesn't cause a build HOT 4
- Given SPI_CTRL_AUTOTX doesn't work on hardware it should be removed HOT 1
- Fat32 implementation doesn't understand 0xffffffff in the Free Count field in FSInfo
- Saving a file doesn't update the free space HOT 2
- Overwriting a file doesn't appear to work HOT 1
- Add ELSE and END IF to BASIC
- would like a way to adjust key repeat parameters on the system HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from x16-rom.