Circular buffer using MBDT on S32K144

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Circular buffer using MBDT on S32K144

1,068 Views
rolo90
Contributor I

Hello everyone, @mariuslucianand 

My application needs to write to EEPROM every 1s, and as to not wear the internal EEPROM from the S32K144, I would need to implement a circular buffer. Since there are no "Circular buffer" MBDT blocks, do I need to write custom C code to access specific registers?

Thanks,

Rolando

0 Kudos
Reply
1 Reply

1,045 Views
mariuslucianand
NXP Employee
NXP Employee

Hello @rolo90 ,

You are right, if you want to implement a circular buffer, for the EEPROM Write or Read block, the block should have the address as an external input/output. You can still use the FLASH_Config block f or setting the EEPROM. Once you did that, you can write a custom code function to call the following C function, where the offset, size and sourceBufferAddress have to be provided as inputs 

FLASH_DRV_EEEWrite(&flashSSDConfig, flashSSDConfig.EERAMBase + <offset>, <size>, <sourceBufferAddress>);

Hope this helps,

Marius

0 Kudos
Reply