FRAM input/output error

Hi all,
I was about to use FRAM to store sensor data + motor controls and use simple last updated sequence number for each value to make sure sensor data is updated, to avoid main cycle of program to stuck in reading sensor data. So I was expecting Navio python example for FRAM will work like a charm, due to all other Navio examples worked absolutely perfect. Unfortunately it did not:

Fram memory Write/Read test!
We will read value from the address 0x005 of the fram memory, then rewrite this cell and read it again.
Value in 0x005 is: 0
The cell was rewritten. The new value is: 0
Traceback (most recent call last):
File “./”, line 19, in
fram.writeBytes(0x103, [2, 12, 15, 3, 7, 2, 12, 12, 3, 4, 5, 6, 1, 12, 43, 123, 11, 23, 33, 11, 43, 12, 43, 35, 11, 111, 234, 124, 43, 12, 11, 122]) #Writing some value to the address 0x103 - 0x123
File “/home/pi/Navio/Python/FRAM/”, line 67, in writeBytes
self.bus.write_i2c_block_data(self.address, registerAddress, data)
IOError: [Errno 5] Input/output erro

Any help will be appreciated!

Hello Sergey!

Yes, it seems that python FRAM example is currently broken, as Navio+ uses a different device than older Navio versions. The example relies on third party libraries and it takes some time to fix it. Sorry about that. C++ example should work fine, if that helps.

However, in your case I would not recommend using FRAM chip at all. Instead of storing sensor data on FRAM, you really should take advantage of Linux and use IPC mechanisms to transfer new measurements. You can also write the logs to a text file on the RPi SD card.