How to write parameters to flash at runtime for TMS320F28375 MCU using C2000 Microcontroller Blockset?

5 views (last 30 days)
I am using C2000 Microcontroller Blockset in Simulink R2023b for a TMS320F28375 MCU and would like to write parameters to flash (ROM) and read these parameters from flash into RAM at runtime to save data in real-time. Is such workflow supported?

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 19 Dec 2023
This answer was flagged by 晓虎
Please see reference example 'FLASH EEPROM Emulation from Simulink using Embedded Coder TI C2000 Support Package for F28379D Launchpad' in MATLAB File Exchange in the below link:
Through this demo, we define a sector of on-chip Flash memory as the emulated electrically erasable programmable read-only memory (EEPROM) by emulating the EEPROM functionality within the limitations of the Flash memory. 
The demo model will showcase how one can define calibration parameters that will be loaded to Flash sector reserved for EEPROM emulation. This is achieved through a separate load and run addresses for these parameters and a copy is performed to move from the Flash to the RAM at runtime. The calibration values can then be updated in RAM and then copied back to Flash for reuse even after power cycle using the TI Flash API routines.
For more information, please refer to the detailed documentation page "Simulink_EEPROM_Emulation_f2837x.pdf" in the downloaded files from the File Exchange.

More Answers (0)

Products


Release

R2023b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!