Why do I receive 'Failed to open serial port COM* to communicate with the board' or 'Open fail: Port: COM* is not available. No ports are available.' error with MATLAB/Simulink support package for Arduino Hardware

1 vue (au cours des 30 derniers jours)
Why do I receive the following error when trying to connect to Arduino Hardware with the MATLAB support package?
ERROR: Failed to open serial port COM6 to communicate with board Uno. Make
sure there is no other MATLAB arduino object for this board. For
troubleshooting, see Arduino Hardware Troubleshooting.
Correspondingly using the Simulink Support Package for Arduino, why do I receive the following error when building a model for the Arduino?
ERROR: Open fail: Port: COM* is not available. No ports are available.
Use INSTRFIND to determine if other instrument objects are connected to the requested device.

Réponse acceptée

MathWorks Support Team
MathWorks Support Team le 1 Août 2024
Modifié(e) : MathWorks Support Team le 26 Juin 2024
This issue mainly arises when MATLAB tries to connect to the Arduino via more than one connection.
This can happen if there is an existing "arduino" object in the workspace.
Make sure to clear the previous arduino objects before calling the arduino function again, or simulating a model on the Arduino.
To clear an arduino object "my_arduino":
>> clear my_arduino
Additionally check that other MATLAB instances are not connected to the Arduino.
If this does not resolve the error, please contact MathWorks Technical Support at:

Plus de réponses (0)

Catégories

En savoir plus sur Arduino Hardware dans Help Center et File Exchange

Tags

Aucun tag saisi pour le moment.

Produits


Version

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by