0

FRAM SPI breakout board not able to read/write
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Re: FRAM SPI breakout board not able to read/write

by rb91409 on Wed Sep 23, 2020 1:56 am

Thanks everyone for all the good advise to run down why I was not able to get my Adafruit FRAM breakout board working. I had some time today and yesterday to revisit this problem and looked at both the header and cpp files for the FRAM and the datasheet for the IC chip. I hooked up my oscilloscope to the DI and CLK pins of the 24C256 chip. All the enable and disable write looked fine and the data was OK too. I was looking at all the different FRAM and eeprom example sketches trying to see it any worked with this FRAM. There was one sketch that did work but wasn't really meant for this type of memory but it did work. The one thing that was different was in the fram.begin() of the sketch, so I added "uint8_t addrSizeInBytes = 3;" and modified line 7 from "if( fram.begin() ) to if( fram.begin(addrSizeInBytes))". I tested it with some different addresses and values and all seamed to work fine. Thanks again.

1. uint8_t addrSizeInBytes = 3;
2.
3. void setup(void) {
4. Serial.begin(9600);
5. while (!Serial) delay(10); // will pause Zero, Leonardo, etc until serial console opens
6.
7. if (fram.begin(addrSizeInBytes)) [color=#804080][color=#804000][/color][/color]{
8. Serial.println("Found SPI FRAM");
9. } else {
10. Serial.println("No SPI FRAM found ... check your connections\r\n");
11. while (1);
12. }

rb91409
 
Posts: 9
Joined: Wed Sep 09, 2020 2:02 am

Please be positive and constructive with your questions and comments.