Allocating parameters to ramfuncs section
Ältere Kommentare anzeigen
I need to execute parts of my code on the C2000 from RAM. I was able to generate code from my subsystem into a non‑reusable, standalone function and copy that function to RAM. I also need to copy some of the parameters used by this function into RAM so they can execute more quickly.
Paragraph 7 of the following document attempts to describe the process, but it does not provide enough detail to follow:
Could you provide guidance and a step‑by‑step explanation of how to perform this operation?
Antworten (1)
Adarsh
am 10 Apr. 2026 um 10:29
Here is a brief explanation of point 7 in the given documentation link.
1) Firstly, execute the following command to create a Simulink parameter to the ramfuncs section
demoParam = tic2000demospkg.Parameter
2) Now in the MATLAB's workspace panel you can see the variable named "demoParam"
3) Click on the "demoParam" variable in the MATLAB's workspace panel
4) Open the code generation tab as mentioned in the image below and select "const_data_ramfuncs" this will allow this will indicate the model to store the parameters in ROM and load them into RAM during execution

5) Once you click "OK", you can replace the previous parameters in the blocks of simulink model with the new parameter that you have created.
This is the brief gist of what the point 7 in the given documenatation states.
I hope this helps!
1 Kommentar
Valeriy
vor etwa 2 Stunden
Kategorien
Mehr zu Simulink Environment Customization finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!