Error when running rapid accelerator mode : Error occurred while executing External Mode MEX-file 'ext_comm'

7 ビュー (過去 30 日間)
Hi!
I'm running simulink with a s-function calling a external .dll file. I can run in normal mode. But error occurs when I try to run rapid accelerator mode.
Any idea what might cause this error?
Error occurred while executing External Mode MEX-file 'ext_comm': Failed to connect to the target. Possible reasons for the failure: a) The target is not switched on. b) The target is not connected to your host machine. c) The application for the model is not running on the target. You might have clicked the Stop button. If the Run button is not dimmed, click it. Otherwise, click the Build button, which downloads and runs your application on the target
  1 件のコメント
Evan Parker
Evan Parker 2022 年 7 月 14 日
編集済み: Evan Parker 2022 年 9 月 22 日
This error is due to an issue that was introduced in MATLAB R2020a with using Level-1 C MEX S-functions in conjunction with Rapid Accelerator Mode when continuous states are present. One of the following workarounds can be used to avoid this issue:
  1. Use a version of MATLAB prior to the R2020a release. If the Simulink model was produced using a later version of MATLAB, instructions for exporting the model to an earlier version can be found below:https://www.mathworks.com/help/releases/R2020a/simulink/ug/saving-a-model.html#f2-86382
  2. The second workaround would be to ensure that all C MEX S-functions used within the model are Level-2 S-functions. A guide on how to convert Level-1 S-functions to Level-2 can be found below: https://www.mathworks.com/help/releases/R2020a/simulink/sfg/converting-level-1-c-mex-s-functions-to-level-2.html
  3. The last workaround is to use Normal or Accelerator Mode as these modes are unaffected by the issue.

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeEmbedded Coder についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by