Hello
I've been wanting to try one of these memory chips (Cypress), so got one of the 4kb versions as it had been tested with with the sosandroid /FRAM_MB85RC_I2C library.
After quite a few attempts, careful wiring checks etc, none of examples included with the library worked, nor did Nick Gammons' I2C finder sketch find any device.
The chip only has 7 of 8 pins to use - SDA, SCL, WP (write protect, GND to allow write), Vdd, GND, and two address pins A1 and A2, both grounded in my example, or using pin 13 to ground, as in the examples.
In the issues tab of the GitHub repository, someone had raised the same problems, but had found that using the standard EEPROM examples (write, read, clear), it worked, and sure enough it did.
I wondered if anyone had tried the library examples or Nick Gammons' sketch with this chip or similar and managed to get it to work?
I would also be interested to know why the EEPROM library appears to work and the FRAM library doesn't.
I have a suspicion that with the address finder reporting "no devices", it might have something to do with addressing.
With A1 and A2 grounded, the full address is binary 1010 0000 or HEX 0x50. 1010 is the device identifier, 0000 is A1, A2 grounded, A0 does not exist on the 4-kb chip, and LSB 0 is write.
The only consolation so far is that it doesn't look as though I blew it up (for what it's worth, I did try two identical chips and both behaved the same)
The library example Simple read and write does not compile with error FRAM_I2C_simple_write_read:52:21: error: request for member 'writeByte' in 'mymemory', which is of non-class type 'FRAM_MB85RC_I2C()'
Some of the examples (manual mode and store anything) partially work, but don't read or write
I'll answer this one myself.
First, disregard the comments about EEPROM - totally off subject.
Eventually, I got the I2C scanner to see something. It took several days of faffing around with pullup values and even included attacching fine wires to the SOIC-8 package to eliminate adapter problems.
The 64-kb chip has three address pins and either can be set high or low, giving a device ID between 0x50 and 0x57 (default 0x50).
When the scanner sketch reported back, it reported two devices found, despite only one connected.
Once one of those values was plugged into the device constructor in the sketches, things began to work.
This was with the Cypress chips.
To regain some confidence, I tried an Adafruit 256-kb I2C breakout and used the Adafruit FRAM library, which of course, worked straightaway.
The Adafruit board uses the Fujitsu chips that are not easily available in the UK (got some from Digikey USA).
One thing the Adafruit tutorial does mention, is to power cycle the chip if the address jumpers are changed.
I'm not sure if the same applies to the Cypress chips without going through the datasheets.
What to learn from this? Persevere, use a tested breakout board from a reputable supplier, especially if they have a library to go with it, then mess about with the raw chips. I might also experiment with SPI versions if the multiple device address probem persists