External Mode Error in Simulink - Using TI Piccolo F2803x

1 次查看(过去 30 天)
Hi,
I'm trying to run a program on the TI Piccolo F2803x but it keeps showing this error:
Error occurred while executing External Mode MEX-file 'ext_comm':
Failed to connect to the target. A time-out occurred while waiting for the connection response from the target. Possible reasons for the time-out:
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.
Component:Simulink | Category:Block diagram error
Unable to connect to the 'TI Piccolo F2803x' target for 'sm_exm'.
Component:Simulink | Category:Model error
How can I solve it?
The thing is that the hardware is working. We've tried this by using a simple program shown in the picture below.
But when we start to 'complicate' things, such as in this other example:
It keeps giving the error that you can see at the beginning of my question.
What we tried to do, according to other questions and answers I found on Mathworks is:
But in every case I still experienced the problem.
Please help me to understand whether it's a setting that I forgot, or what should I do.
Thank you very much in advance!

回答(2 个)

Birdman
Birdman 2021-1-26
The main thing about External Mode is that you need to make sure that the code is running on the hardware before you try to run the External Mode. I suggest you check that.

James Lorenzo Fioravanti
Hi @pavan koushik, I got support from the MathWorks Team and they showed me that it's not a connection issue, but a problem of the example itself which got stuck in a loop of "do while" and so created a time-out error.

产品


版本

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by