Using EPROMS And EEPROMs As Programmable Logic With Lisp

Die of an Altera EPM7032 EEPROM-based Complex Programmable Logic Device (CPLD). (Credit: ZeptoBars, Wikipedia)

That EPROMs, EEPROMs and kin can be used as programmable logic should probably not come as a major surprise, but [Jimmy] has created a Lisp-based project that makes using these chips as a logic array very straightforward. All it takes is importing the package into one’s Lisp project and defining the logic, before the truth function generates the binary file that can be written to the target chip.

Suggested is the one-time-programmable AT27C512R EPROM (64k x8), but any 8-bit parallel interface (E)EPROM should work, with non-OTP chips being nice unless the chip has to go into a production device. A possible future improvement is the addition of 16-bit (E)EPROM support.

The use of EEPROMs is common with PLA-replacements, as with, for example, the Commodore 64, where the official PLA IC tends to go bad over time. Due to the complexity of the logic in these PLA ICs, here CPLDs are used, which internally are still EEPROM-based, but feature many more programmable elements to allow for more complex logic. If all you need is a bit of glue logic and you are looking for something in between a stack of 74-logic ICs and a CPLD, an EEPROM may be just be the solution, regardless of whether you prefer to create the binary image with Lisp or C.

Top image: Die of an Altera EPM7032 EEPROM-based Complex Programmable Logic Device (CPLD). (Credit: ZeptoBars, Wikipedia)

9 thoughts on “Using EPROMS And EEPROMs As Programmable Logic With Lisp

  1. Ah yes, its very straight forward method, good way to manage all sorts
    of functional logic with no buggy software, though do need to handle
    potential for race hazards, ie Data out from EEprom 1 to other others and
    random logic too in any sort of chain, feed-backs most interesting ;-)

    Toyed with the general principles circa mid-late 1980’s turned out when
    the Motorola 68705P3 cpu’s turned up mostly went away from eproms
    and proms & GAL – still used a 74C86 though with R & C for pulse edge
    decoding quadrature from optical disk sensors for Press Brake back-gauges :-)

    Good fun and very reliable, straightforward and simple to protect from
    industrial electronics transients, curious about the really high speed high
    density stuff for forms of Ai coupled with modern 32 bit micros in 8 pins
    handling serial streams that appear like mammalian neuron firings – LoL !

    Thanks for posting :-)

  2. It’s a neat idea, and I’ve used it many times. It’s a great way to build state machines. I’ve never seen it done with LISP though.

    Caveats: Memory chips have an access time that is significantly longer than actual logic ICs. When the address inputs are changing, the outputs can be unstable, During their access time, the outputs may be unstable, so it is good practice to latch the outputs during the access time.

    1. True, it needs to be a synchronous circuit. EEPROM doesn’t get much faster than 55ns and like-wise buried gate NOR FLASH without spending money. I think a modern EPROM would likely be faster EEPROM or FLASH.

      But 64kB chips is 2 8bit-8bit LUTS though it can handle a full width of permutations.

      I see a lot of home-brew CPU architectures where both the micro-code and come of the control are in a number of these chip. Slow but versatile.

  3. To anyone around since the 1980s this should be unsurprising. Many of the early CAE tools were written in Lisp, at least at the research stage. It’s good to see folks bringing it back.

  4. Hey, you can use C too… After the PHPPLD I created CPLD (see github). I use it to create the ROM images for all those crazy state machines I do. Its great having all the functions of a high level language at your disposal to create images for these projects, love to see the language set growing!

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.