Hi,
I designed an interrupt-based model for object code generation to the target microcontroller including blocks from the target support package. When I hit the build button in the hardware pane the code is built:
Code generation targets built:
Model Action Rebuild Reason
==================================================================================
ES_Application Code generated and compiled. Rebuild option is set to 'Always'.
Top model targets built:
Model Action Rebuild Reason
============================================================
PIL_Model Code compiled. Referenced models were updated.
2 of 2 models built (0 models already up to date)
Build duration: 0h 0m 13.534s
however I get the following error just below that:
Error:An asynchronous sample time is specified for the component (PIL_Model). However, this is not supported for:
a) SIL/PIL block simulations
b) Top-model SIL/PIL simulations (unless the component is an export-function model)
To avoid this error, use an alternative sample time, for example, discrete sample time. Alternatively, consider running this component in Model block SIL/PIL mode.
Then when I try to connect to run on hardware by clicking on connect the build fails and I get the following error:
Error:Unable to update models referenced by 'PIL_Model'.
Caused by:
The model 'untitled' is configured to run in external mode, but the referenced models below are out of date. If an external mode simulation is not required, set 'SimulationMode' to 'normal'. Otherwise, regenerate the code for 'PIL_Model'.
Rebuild option is set to 'Always'.
Does anyone have an idea what the error is actually about? I get that it is related to the asynchronous sample time due to the interruptions but it doesn't make much sense since the execution domain is set to discrete in the Execution pane of the property inspector.
Thanks in advance,