MATLAB: While using the pulse generator and digital out with an Arduino Due, I received the error message: C:/Program​Data/MATLA​B/SupportP​ackages/R2​017a/toolb​ox/target/​supportpac​kages/ardu​inobase/sr​c/MW_digit​alio.cpp:1​:21: fatal error: Arduino.h:

carlos_arduino_due

While uploading the Pulse Generator and Digital Output circuit (Blinking LED) to an Arduino Due, I received the error message:
C:/ProgramData/MATLAB/SupportPackages/R2017a/toolbox/target/supportpackages/arduinobase/src/MW_digitalio.cpp:1:21: fatal error: Arduino.h: No such file or directory
#include <Arduino.h>
^
compilation terminated.
gmake: *** [MW_digitalio.o] Error 1
How can I resolve this problem?

Best Answer

This problem can be resolved by re-installing the Support Package.
  • Uninstall the existing support package. Maker sure that the respective folder (C:/ProgramData/MATLAB/SupportPackages/R2017a/toolbox/target/supportpackages/arduinobase) is deleted.
  • After this, execute the following command in MATLAB:
>>rehash toolboxcache
  • Install the Support Package again.