> I am having a bear of a problem trying to get a PIC 16F877 to write > to and read data from a non-volatile SRAM chip. > > ... > > I checked and double checked my wiring and I believe it was done > correctly. To test my circuit, I (1) write an arbitrary bitfield to an > arbitrary memory location in the RAM, (2) read it back to a temp value > and (3) store what was read in the PIC's EEPROM. Why store it in the PIC's EEPROM? That just introduces one more thing that can go wrong. How do you know the problem isn't writing to the EEPROM instead of accessing the external RAM? When implementing external busses, I like to start with a loop that writes a counting value to all the lines. This makes is easy to verify that all the bits make it to the target device because each should be a square wave with each more significant bit having half the frequency than the previous. This finds opens, shorts to ground/power, shorts between lines, etc. Once that works, do the same with the address lines. Once all the address and data lines are verified, make a loop that writes and reads some value to/from the same memory location. Now you can check the timing and relationship of the various control lines, and see when the RAM drives the bus, etc. There are more steps after that. I won't bother with the details, but the point is to test each thing incrementally until eventually everything works. ***************************************************************** Embed Inc, embedded system specialists in Littleton Massachusetts (978) 742-9014, http://www.embedinc.com -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads