Clear Filters
Clear Filters

SIMULINK ARDUINO MEGA 2560

2 views (last 30 days)
JOSEPH KURAN
JOSEPH KURAN on 25 Oct 2015
Answered: Gareth Thomas on 25 Oct 2015
My MEGA2560 R3 receives uploads VIA USB from MATLAB OK. But when using SIMULINK (I used "getting started with Arduino Hardware" example) to make LED blink on pin 9. I keep getting "Failed to generate all binary outputs" error after "deploying hardware" button in initiated. The difference is that the TX/RX LED's flash when uploading from MATLAB, but TX/RX LED's do not flash when uploading from SIMULINK. Using Windows 10 64 Bit and MATLAB 2015b and windows device driver indicates that 2560 in enabled and assigned COM5. Also, 2560 works OK when uploading sketches from Arduino sketch book. It acts like that maybe SIMULINK doesn't recognize the USB connection, even-though MATLAB does recognize it. Also I have the issue with Arduino UNO. Any help would be appreciated.

Answers (1)

Gareth Thomas
Gareth Thomas on 25 Oct 2015
Make sure that your simulink model is configured for the arduino mega, and make sure that you set the com port in the simulink model properties under hardware settings. it is set to automatic by default, you can force it to use com5

Community Treasure Hunt

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

Start Hunting!