I bought an Apple ][+ off ebay and the keyboard stopped working. I tracked it down to the strobe output on the keyboard encoder (an SMC KR3600). Using data from the book The Apple II Circuit Description by Winston D. Gayler, I programmed a PIC18F46K22 to replace the chip. Since I didn't need it anymore, I decapped it.
die shot after top metal removed
The ASCII values are stored in the 3600-bit ROM in the middle of the die. There is a 90-bit RAM at the bottom of the die to keep track of which keys are down.