93C66 EEPROM chip with an AVR microcontroller

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:
93c66 ins set
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

Related Post

Be the first to comment

Leave a Reply

Your email address will not be published.


= 3 + 2

Read previous post:
DS1669 Digital Potmeter UP/DOWN using microcontroller

Part list:1x AT90S1200-12PI 1x DS1669 (Dallas) 1x 78L05 2x 1N4007 1x 4MHz X-tal 2x 27pf 1x 22pF 1x 47uF/16V 1x...