Rapid accelerator - disable tunable parameter - issue with sizes of parameters

4 views (last 30 days)
Hi, I have a Simulink model using workspace variables as parameters. The variables are structs containing some big array-fields (look-up tables). When building the model for rapid accelerator (rtp=Simulink.BlockDiagram.buildRapidAcceleratorTarget('testModel')) it creates tunebale parameters for all used structs - I can see this in the rtp-struct. Afterwards, when starting the simulation I get warnings that the values were too big for downloading them: "Could not download parameter 'hdc' of 'testModell' due to: Parameter value is too large to download to target application."
I think I have to take this warning serios beacuse the simulation results differs from normal mode.
I have two questions: 1) How can I prevent the code generator from creating the tunable parameters from the big structs but instead hard-code the values? I failed to do so using Simulink-Parameters. I don't need most of the structs as tuneable.
2) Is there a way to increase the maximum size of structs which are possible as tunable parameters? I checked that the limitation is 9999 values for a struct containing double values, independent of the number of fields.
Any help is highly appreciated!
Many thanks, Jan
  1 Comment
antonino on 10 Mar 2017
Hello Jan, I have the same problem here and wondering whether - despite the lack of feedbacks in the forum - you have found a solution... Cheers, Nino

Sign in to comment.

Answers (1)

Albert Yam
Albert Yam on 23 Nov 2017
I think I have a solution, as I was looking and doing some research. Go to Model Explorer. Then "Base workspace", drag and drop the signals that get the "Parameter too large" into the "Model workspace". Make sure you save the location of the Model workspace, as a MAT or MATLAB file.
Re-run the rapid accelerator.

Community Treasure Hunt

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

Start Hunting!