c2000 how to store data in non volatile memory

조회 수: 9 (최근 30일)
Lorenzo
Lorenzo 2012년 9월 11일
댓글: Venkatesh Chilapur 2018년 12월 4일
Hallo, I have a control system built into simulink scheme. The scheme is configured to download code to flash memory.
Control gains and all parameters are thus defined at compile time.
I need to update those gains and parameters with new values received via serial port (for instance) during the system operation and store them in the internal flash memory so that, even after an on/off power cycle the new parameters are used (not the old ones).
Which is the best way to store those parameters without having to recompile the scheme with the new gains?
thanks, Lorenzo
  댓글 수: 1
Imanol Eguren
Imanol Eguren 2018년 12월 3일
Hello Lorenzo,
I know that this question is from 2012, but did you figure out a way to store the values in the non volatile memory?
I need to do the same thing, and I did not find any help...
Thank you!
Imanol

댓글을 달려면 로그인하십시오.

답변 (2개)

Venkatesh Chilapur
Venkatesh Chilapur 2018년 12월 3일
Please refer this link:
https://in.mathworks.com/matlabcentral/answers/172053-how-do-i-store-variables-to-flash-memory-of-the-c2000-f28335-controller-using-matlab

Imanol Eguren
Imanol Eguren 2018년 12월 3일
I need to update the value of the variable periodically without building the model again. If I understood the example correctly, what it does is not exactly what I need.
In the example a parameter called STEP_PARAM is created so that changing the value of it is allowed when running the example in external mode. But, for storing the value in the flash, building the model again is required.
Can a parameter like this one be updated programatically?
Thank you,
Imanol
  댓글 수: 1
Venkatesh Chilapur
Venkatesh Chilapur 2018년 12월 4일
Hi Imanol,
We currently do not support writing parameters to flash programatically. The description from Antonin in the link above summarizes the same.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Embedded Coder Supported Hardware에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by