AT93C46

Go To Last Post
4 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello

 

I'm At93C46 for my design,  it is an old device and not recommended by Atmel for new dosing , however I've few and want to use it but have some issue with it.

The CPU I'm using to interface with it is AT89S52. At the moment it seems that I can send the following command : Write enable, Write disable, Erase all and read.

The problem I stuck with is write.

When writing to some address, it looks like the next address is also being programed with same data. If I write to address 00h with data 55h, when dump all Eeprom memory to screen , I see that add 01h also has 55h.

 

Does anyone here have experience with At93c46 and can assist ?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

If you are using a AT89S52,   there is no SPI peripheral.    So you have no choice but to bit-bash.

 

Since you can read the device,   I assume that your low-level "SPI" functions are ok.

 

Look at your data sheet.    From memory there is a hardware WP pin and also a software "write-enable" sequence.

 

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi David

 

Thanks for your reply

 

Along with my trying to read\write the EEPROM I've build a debugging environment which consists a terminal (run on PC) that communicates with the AT89S52 through RS-232.

This way I can send commands to the At93C46 like the EWEN (write enable) EWDS (Write disable) ERAL (erase all) , read a specific address and dump all memory to screen , I see that these commands working properly which means the communication (signal integrity) between the CPU and Eeprom is good (also test with oscilloscope).

The problem I'm faceting is not lack ability to write the Eeprom but kind of duplicate or double writing in one writing cycle, when I'm writing to address 00H (for example) with data 55H ,later I read address 00H and I get the 55H but for some reason that I'm not totally understand , address 01H also gets the value 55H and I can't figure out why and how come it happens. I never used this chip before and have no experience with it.

The At93c46 is configured to works at 8 byte mode (pin 6 is tied to GND) and the chip is working with 5V. No pull-up resistors were connected to CLOK, DI or DO.

 

Open for any comments, idea or others

 

Itzik

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Without seeing your code,   we can not really help much.

 

The data sheet explains EWEN, EWDS etc.    It also shows the complete sequence.    Personally,   I find a Logic Analyser is easier than an oscilloscope trace.

 

Regarding your absence of pull-ups.    The 8051 is an open-drain device (with a bit of switching assistance).   You would normally have some sort of external pull-up to ensure that your external electronics 'see' a HIGH signal.

 

There must be thousands of 93C46 examples for an 8051.     Many of them with recommended schematics.

 

David.