Q: Simulink Real-Time Desktop model: why does it rebuild on every run? I have a Simulink Real-Time Desktop model that launches from a GUIDE application in External mode. My problem is how to run the model without Matlab rebuilding it every single time. 
In the _OpeningFcn I included a 'rtwrebuild' command with the expectation that this would rebuild the code only if the model had been changed since the last run. However, when I start the real-time simulation using set_param(MODEL, 'SimulationCommand', 'start', ...), it invariably rebuilds the code regardless of what 'rtwrebuild' did. How can I keep the start command from causing all these unnecessary builds?

A: Since I don't have reputation enough for posting a comment request for clarification, I'll ask it here; did you check the rebuild option setting in the configuration set?
From my own experience it take a long time even if set to only rebuild if changes detected because it still opens every single file in the model tree to check that nothing was changed. Also I think some parameter changes counts as cause for rebuild. If you don't want that you need to set "Never" rebuild and control this yourself.
