Dear All,
I have Arduino Engineering Kit V2, I am facing an issuing with external mode in Simulink.
But I could establish a connection via command line when I try to build and deploy, I am facing below issue.
Build:
### Starting build procedure for: imu_demo
"### Generating static library."
"C:/Program Files/MATLAB/R2021b/bin/win64/gmake" -j17 -C "C:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinobase/staticmakefiles" SHELL="%SystemRoot%/system32/cmd.exe" -f samdcomm.mk all
gmake[1]: Entering directory `C:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinobase/staticmakefiles'
"### Successfully generated libcomm.a library."
gmake[1]: Leaving directory `C:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinobase/staticmakefiles'
"C:/Program Files/MATLAB/R2021b/bin/win64/gmake" -j17 -C "C:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinobase/staticmakefiles" SHELL="%SystemRoot%/system32/cmd.exe" -f samdcore.mk all
gmake[1]: Entering directory `C:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinobase/staticmakefiles'
"### Successfully generated libcore.a library."
gmake[1]: Leaving directory `C:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinobase/staticmakefiles'
"C:/Program Files/MATLAB/R2021b/bin/win64/gmake" -j17 SHELL="%SystemRoot%/system32/cmd.exe" -f "imu_demo.mk" all
gmake[1]: Entering directory `C:/Users/rohit/AppData/Roaming/MathWorks/MATLAB Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2/imu_demo_ert_rtw'
"C:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -std=gnu++11 -fno-threadsafe-statics -fno-rtti -fno-exceptions -Os -c -w -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -Dprintf=iprintf -DARDUINO=10801 -MMD -MP -MF"MW_arduinoI2C.dep" -MT"MW_arduinoI2C.o" -MMD -mcpu=cortex-m0plus -fpermissive -DF_CPU=48000000L -DARDUINO_SAMD_NANO_33_IOT -DARDUINO_ARCH_SAMD -D__SAMD21G18A__ -mthumb -DUSB_VID=0x2341 -DUSB_PID=0x8057 -DUSBCON -DUSB_MANUFACTURER=\""Arduino LLC\"" -DUSB_PRODUCT=\""Arduino NANO 33 IoT\"" -D_RUNONTARGETHARDWARE_BUILD_ -D_ROTH_NANO33_IOT_ -DCRYSTALLESS -DARDUINO_VIRTUAL_COM_PORT -DARDUINO_WIFI_LIB_NINA -DARDUINO_NUM_SERIAL_PORTS=2 -DARDUINO_ARM_CORTEX_M0_PLUS -DARDUINO_ARM -D__MW_TARGET_USE_HARDWARE_RESOURCES_H__ -DMW_TIMERID=10 -DMW_PRESCALAR=128 -DMW_TIMERCOUNT=625 -DMW_SCHEDULERCOUNTER=1 -DARDUINO_NUM_SERIAL_PORTS=2 -D_RTT_BAUDRATE_SERIAL0_=9600 -D_RTT_BAUDRATE_SERIAL1_=9600 -D_RTT_ANALOG_REF_=0 -DCLASSIC_INTERFACE=0 -DALLOCATIONFCN=0 -DONESTEPFCN=1 -DTERMFCN=1 -DMULTI_INSTANCE_CODE=0 -DINTEGER_CODE=0 -DMT=0 -DTID01EQ=0 -DXCP_CUSTOM_PLATFORM -DEXIT_FAILURE=1 -DEXTMODE_DISABLEPRINTF -DEXTMODE_DISABLETESTING -DEXTMODE_DISABLE_ARGS_PROCESSING=1 -DSTACK_SIZE=64 -DRT -DMODEL=imu_demo -DNUMST=1 -DNCSTATES=0 -DHAVESTDIO -DMODEL_HAS_DYNAMICALLY_LOADED_SFCNS=0 -IC:/Users/rohit/AppData/Roaming/MathWorks/MATLAB Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2 -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/shared/svd/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinobase/include -IC:/Users/rohit/AppData/Roaming/MathWorks/MATLAB Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2/imu_demo_ert_rtw -IC:/PROGRA~1/MATLAB/R2021b/extern/include -IC:/PROGRA~1/MATLAB/R2021b/simulink/include -IC:/PROGRA~1/MATLAB/R2021b/rtw/c/src -IC:/PROGRA~1/MATLAB/R2021b/rtw/c/src/ext_mode/common -IC:/PROGRA~1/MATLAB/R2021b/rtw/c/ert -IC:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/tools/CMSIS/4.5.0/CMSIS/Include -IC:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/tools/CMSIS-Atmel/1.2.0/CMSIS/Device/ATMEL -IC:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/hardware/samd/1.8.9/cores/arduino -IC:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/hardware/samd/1.8.9/variants/nano_33_iot -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinotarget/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinotarget/scheduler/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/armcortexmbase/scheduler/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/shared/externalmode_daemon/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/armcortexmbase/xcp/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/aIDE/libraries/Servo/src -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/hardware/samd/1.8.9/libraries/Wire -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/hardware/samd/1.8.9/libraries/SPI -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/aIDE/libraries/Servo/src/samd -o "MW_arduinoI2C.o" "C:\ProgramData\MATLAB\SupportPackages\R2021b\toolbox\target\supportpackages\arduinobase\src\MW_arduinoI2C.cpp"
"C:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -std=gnu++11 -fno-threadsafe-statics -fno-rtti -fno-exceptions -Os -c -w -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -Dprintf=iprintf -DARDUINO=10801 -MMD -MP -MF"io_wrappers.dep" -MT"io_wrappers.o" -MMD -mcpu=cortex-m0plus -fpermissive -DF_CPU=48000000L -DARDUINO_SAMD_NANO_33_IOT -DARDUINO_ARCH_SAMD -D__SAMD21G18A__ -mthumb -DUSB_VID=0x2341 -DUSB_PID=0x8057 -DUSBCON -DUSB_MANUFACTURER=\""Arduino LLC\"" -DUSB_PRODUCT=\""Arduino NANO 33 IoT\"" -D_RUNONTARGETHARDWARE_BUILD_ -D_ROTH_NANO33_IOT_ -DCRYSTALLESS -DARDUINO_VIRTUAL_COM_PORT -DARDUINO_WIFI_LIB_NINA -DARDUINO_NUM_SERIAL_PORTS=2 -DARDUINO_ARM_CORTEX_M0_PLUS -DARDUINO_ARM -D__MW_TARGET_USE_HARDWARE_RESOURCES_H__ -DMW_TIMERID=10 -DMW_PRESCALAR=128 -DMW_TIMERCOUNT=625 -DMW_SCHEDULERCOUNTER=1 -DARDUINO_NUM_SERIAL_PORTS=2 -D_RTT_BAUDRATE_SERIAL0_=9600 -D_RTT_BAUDRATE_SERIAL1_=9600 -D_RTT_ANALOG_REF_=0 -DCLASSIC_INTERFACE=0 -DALLOCATIONFCN=0 -DONESTEPFCN=1 -DTERMFCN=1 -DMULTI_INSTANCE_CODE=0 -DINTEGER_CODE=0 -DMT=0 -DTID01EQ=0 -DXCP_CUSTOM_PLATFORM -DEXIT_FAILURE=1 -DEXTMODE_DISABLEPRINTF -DEXTMODE_DISABLETESTING -DEXTMODE_DISABLE_ARGS_PROCESSING=1 -DSTACK_SIZE=64 -DRT -DMODEL=imu_demo -DNUMST=1 -DNCSTATES=0 -DHAVESTDIO -DMODEL_HAS_DYNAMICALLY_LOADED_SFCNS=0 -IC:/Users/rohit/AppData/Roaming/MathWorks/MATLAB Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2 -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/shared/svd/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinobase/include -IC:/Users/rohit/AppData/Roaming/MathWorks/MATLAB Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2/imu_demo_ert_rtw -IC:/PROGRA~1/MATLAB/R2021b/extern/include -IC:/PROGRA~1/MATLAB/R2021b/simulink/include -IC:/PROGRA~1/MATLAB/R2021b/rtw/c/src -IC:/PROGRA~1/MATLAB/R2021b/rtw/c/src/ext_mode/common -IC:/PROGRA~1/MATLAB/R2021b/rtw/c/ert -IC:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/tools/CMSIS/4.5.0/CMSIS/Include -IC:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/tools/CMSIS-Atmel/1.2.0/CMSIS/Device/ATMEL -IC:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/hardware/samd/1.8.9/cores/arduino -IC:/ProgramData/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/hardware/samd/1.8.9/variants/nano_33_iot -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinotarget/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/arduinotarget/scheduler/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/armcortexmbase/scheduler/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/shared/externalmode_daemon/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/toolbox/target/supportpackages/armcortexmbase/xcp/include -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/aIDE/libraries/Servo/src -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/hardware/samd/1.8.9/libraries/Wire -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/aIDE/portable/packages/arduino/hardware/samd/1.8.9/libraries/SPI -IC:/PROGRA~3/MATLAB/SupportPackages/R2021b/aIDE/libraries/Servo/src/samd -o "io_wrappers.o" "C:\ProgramData\MATLAB\SupportPackages\R2021b\toolbox\target\supportpackages\arduinobase\src\io_wrappers.cpp"
arm-none-eabi-g++: error: Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2: No such file or directory
arm-none-eabi-g++: error: Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2/imu_demo_ert_rtw: No such file or directory
gmake[1]: *** No rule to make target `Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2/imu_demo_ert_rtw/imu_demo.c', needed by `imu_demo.o'. Stop.
gmake[1]: *** Waiting for unfinished jobs....
gmake[1]: *** [MW_arduinoI2C.o] Error 1
arm-none-eabi-g++: error: Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2: No such file or directory
arm-none-eabi-g++: error: Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2/imu_demo_ert_rtw: No such file or directory
gmake[1]: *** [io_wrappers.o] Error 1
gmake[1]: Leaving directory `C:/Users/rohit/AppData/Roaming/MathWorks/MATLAB Add-Ons/Toolboxes/Arduino_Engineering_Kit_Project_Files_Rev_2/Motorcycle/exercise_6_2/imu_demo_ert_rtw'
gmake: *** [all] Error 2
The make command returned an error of 2
### Build procedure for imu_demo aborted due to an error.
Summary:
Top model targets built: Model Action Rebuild Reason ==================================================================== imu_demo Failed Code generation information file does not exist. 0 of 1 models built (0 models already up to date) Build duration: 0h 0m 16.276s
Error(s) encountered while building "[imu_demo](matlab:das_dv_hyperlink('DAS','mdl','imu_demo'))"
Component:Simulink | Category:Block diagram error