S-Function with different behaviors during simulation and embedded coding
Ältere Kommentare anzeigen
Hi,
I have a microprocessor target for which I would like to have my S-function "simulate" and "generate embedded code".
By "simulation", I mean that the S-Function is executed in the computer and behaves like an I/O block reading/writing microprocessor input/output pins via a network link (the microprocessor target then runs an existing IO program). Right now, a m-file S-Function does it perfectly.
By "generation of embedded code", I mean that the generated code runs directly on the microprocessor target and is not related to any network link at all (the microprocessor target runs a program containing all the Simulink model). I'm about to write a TLC file for this second behavior.
After a look at the RTW User Guide, I could not find clues for having a single block with these two different behaviors. Is it possible using R2013?
My second question is about accelerated "simulations", how to prevent Matlab from using the TLC file and only rely on the m-file S-function? (the TLC file does not contain the simulation behavior).
Same question about the "external mode", how to force the usage of the TLC file in this mode when the code is generated?
TIA,
- Florent
1 Kommentar
Florent
am 28 Dez. 2013
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Simulink Coder finden Sie in Hilfe-Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!