hjalfi wrote:
Belatedly: I have finally written about 3/4 of a functioning assembler for CP/M-65. It's good enough to compile small programs and produce native binaries. It's about 1800 lines of C which compiles into an eye-watering 11kB of 6502 code but even on a BBC B there should be enough spare RAM to compile at least something. And I recorded it all! Do you like very long, boring live coding videos?
Bravo! What took you so long? The videos are quite watchable at 2x speed.
For a size reference, I have transcribed the 6800 FLEX native assembler to the 6502. It is a full featured assembler for its time though lacking advanced things like conditional assembly and macros. It weighs in at 7.7K.
hjalfi wrote:
So the only remaining piece of the puzzle to produce an actually useful (for some definitions of useful) operating system is an editor. CP/M traditionally uses edlin. I've found a copy of the original PL/M source, and bleagh.
Does anyone know of any existing ports of something like edlin for the 6502 that I might be able to rip off, I mean, reuse?
I have also transcribed the FLEX text editor to the 6502. It still lacks several commands and has bugs. I do not know enough to say how difficult it would be to make it run under CP/M-65. It is somewhat better than CP/M's ED, more like EDLIN.
This is the manual for the 6809 version; the 6800 version I started with is missing a few of the commands.
http://www.flexusergroup.com/flexusergr ... /tedit.pdfHow does a program determine the end of the usable TPA? With CP/M-80, the jump to BDOS indicates where the operating system code begins.
In the past, I have threatened to write a compiler for PL/M.
https://talk.dallasmakerspace.org/t/pro ... /18852/216It is not very far along. <mumble>too many projects...</mumble>
hjalfi wrote:
At one point someone told me about a third CP/M for the 6502 project, but I can't find their message now...
That would be
viewtopic.php?f=2&t=7394It uses 256 byte record sizes, so may be difficult to port code to.