I see I got a mention on this forum in 2010: viewtopic.php?t=2073
I made a "tiny" Pascal compiler in 1979 for a 6800 evaluation kit board. This compiler resided in UV-EPROM on the board itself.
In 1982 I ported it to the Apple II, calling it G-Pascal, and in 1983 to the Commodore 64. Those versions had to be loaded from disk, naturally.
It has lain dormant for a few decades now, however after buying Ben Eater's 6502 breadboard computer kit last Christmas (ie. December 2021) I thought it might be time to revive it, and go back to a Pascal compiler resident in EEPROM.
Fortunately I still had a listing of the Commodore 64 version, and managed to get it to assemble using vasm. Then the hard work came of removing all the stuff about the Commodore 64, and working out what the heck I was thinking when I wrote it 40 years ago.
The Pascal stuff only took about 16k out of the 32k EEPROM, so I added an on-board assembler as well.
Still with room to spare I added SPI and I2C support, CRC calculations, and support for the LCD on Ben's board.
This is all available on GitHub: https://github.com/nickgammon/G-Pascal.
Documentation is part of the GitHub download, and also viewable here: http://www.gammon.com.au/G-Pascal/.
To "talk" to the board you use 4800 baud serial comms (if using a 1 MHz clock), connected to the 6522 chip on Ben's board using an FTDI cable.
You can watch it in operation on Vimeo: https://vimeo.com/682663375.
There are also some demonstration videos there of the I2C and SPI interface.
You are welcome to use it "as is" or extract any functions you find useful, such as the I2C routines.
Having an on-board assembler is handy because you can code, assemble and test without having to remove EEPROM chips or muck around with external programmers. I developed the I2C and SPI routines using the on-board assembler.
- Nick