Why am I unable to connect to Arduino in External Mode?
Show older comments
When I try to run my model in external mode with Arduino Mega connected, I receive the following error:
---------------------------
### Starting build procedure for model: model1_test
Code Generation 1
Elapsed: 1:04 min
AVR Memory Usage
----------------
Device: atmega2560
Program: 24764 bytes (9.4% Full)
(.text + .data + .bootloader)
Data: 1769 bytes (21.6% Full)
(.data + .bss + .noinit)
### Successful completion of build procedure for model: model1_test
Build process completed successfully
Attempting to establish connection with hostname '127.0.0.1' through port 17725.
action: EXT_CONNECT
Component:Simulink | Category:Model
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.
Caused by:
An error occurred attempting to open an rtIOStream. More detail may be reported in the MATLAB command window
Component:Simulink | Category:Block diagram error
Unable to connect to the 'Arduino Mega 2560' target for 'model1_test'.
Accepted Answer
More Answers (0)
Categories
Find more on Arduino Hardware in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!