How to program a 93C66 EEPROM chip with an AVR microcontroller?
The 93C66 is a serially (MICROWIRE) Electrically Erasable Programmable ROM (EEPROM) chip with 4 kbit (4096 bit, can be ORGanized as 256 x 16bit or 512 x 8bit) memory space. Here a DIL version (which I will use in my moving message sign project) of the 93C66:
The 93C66 (ST) has five control pins, D (data input), C (clock), S (chip select), ORG (8- or 16bit organized) and Q (data output)
Other pins are Vcc (supply), Vss (GND) and DU (Don’t Use) Connect four (S, C, D and Q) of the five control pins directly to an AVR, connect Vcc to +5V, and connect Vss to GND. Tide ORG and DU to GND, the 93C66 will now be 8bit (byte) organized, meaning that the user can store 512 bytes.
If you power the 93C66 up, you must keep the S (chip select) line low, at init the 93C66 is in Write Disable mode (you cannot write yet) Here a diagram on how to connect the 93C66 to an AVR microcontroller:
The 93C66 operates with seven Instructions, READ (fetch data), WRITE (store data), EWEN (enable writing), EWDS (disable writing), ERASE (clear byte), ERALL (clear all memory), WRALL (write whole memory with the same data) The instructions are built from a startbit (a single bit), opcode bits (2 bits) and address bits (9 bits) The instructions READ, WRITE and ERASE are 3 bits (addressfield set by you), all other instructions are 12 bits. You can make for example a table with the instructions-data. Here the instruction set from the datasheet:
The first instruction (you must transmit) is the EWEN instruction, this enables writing (without executing this instruction you cannot write (write protected) any data to the 93C66), when the 93C66 is write enabled, you can write your data to it. The transmission works as follow: First make the S (chip enable) line high (clock must be low), then set the right data on the D pin, now give one clock (clock rises, causing the transmission), now the first bit is clocked in the 93C66, this is the startbit. Next shift the other bits in the 93C66, when this is happen the 93C66 is write enabled.
For more detail: 93C66 EEPROM chip with an AVR microcontroller
This free embedded project also found using:
- 93c66 programmer
- 93c66 eeprom
- what is ic 93c66 in a circuit?
- arduino programmer for microwire 93s66 eeprom
- atmel 93c66 arduino