All, Since I got back into the 6502 I've designed the small 2-board system and did some initial restructuring of Brian Phelps' SyMon III code to get it running (basic HW test). I first tried out SyMon on a Vic-20 using my old custom I/O board which has a 6551 chip and a 25-pin D-shell port. I modified Symon for the ACIA port base, assembled it, burned it into an EEPROM and replaced the Kernel ROM in the Vic... it worked and I started playing around with it. It sorta reminds of the old Commodore Machine Language monitor code (have the Vic cartridge version and the C64 version on diskette). Bottom line, lot of things I like about it and some I don't. But once you get used to it, it's quite a nice setup to have running and can be extended.
So, to get into doing some coding, I opted to start changing Symon around... basic goals: 1- Get back into doing some assembly coding.... look at some commented code, get back into the basic flow... and some of my old code as well. 2- Alter Symon to take advantage of 65C02 additional instructions and addressing modes. 3- Shrink it down to a smaller size and look to optimize when possible. 4- Make it fully relocatable and use a fixed JMP table for all of the documented calls. 5- Make all empty space contiguous (sans the JMP table and hardware vectors).
My 2-board system uses the following memory map: RAM from $0000-$7FFF EEPROM from $8000-$FDFF (has RO/RW jumper) I/O page from $FE00-$FEFF (8 I/O selects, $FE00 has 65C22 and $FE20 has 6551) EEPROM from $FF00-$FFFF (JMP table and HW vectors)
I've been successful so far in updating Symon. Lots of 65C02 specific coding, much optimization of space and some cleaner routines and it's fully relocatable and contiguous... nothing is hard addressed. I've assembled, linked and loaded at various ROM locations and (keeping the top page the same of course) it works clean in all cases. At the default based address of $E000, contiguous code ends at $FB2B, leaving 725 Bytes of contiguous free space to the I/O page at $FE00. The JMP table starts at $FF00 and uses 90 bytes so far, plus the 6 bytes for the HW vectors, leaving 160 Bytes available. Total free space is 885 Bytes.
Next plan is to replace the Interrupt structure with my own (from many years ago) and have soft vectors which can be linked/replaced, put some of the interrupt handler code in page $FF and add 65C22 interrupt and timer support. I really wish I had more free time to play... I'm actually having some fun.
|