Hi
when I want to programming the arduino Due this error is showing:
>> arduino
Updating server code on board Due (COM10). Please wait (might take a few minutes).
Cannot program board Due (COM10). Please make sure the board is supported and the port and board type are correct. For more
information, see Arduino Hardware Troubleshooting.

 채택된 답변

Madhu Govindarajan
Madhu Govindarajan 2019년 1월 14일

2 개 추천

Try the following and post any error messages that you get -
a = arduino('COM#','Due','TraceOn',true)
Remember the COM# should be the correct number of your Arduino Due. For instance - COM3, COM25 etc.

댓글 수: 6

john white
john white 2019년 1월 17일
ok thank you so much
I have written your code but it shows this error:
a = arduino('COM10','Due','TraceOn',true)
Updating server code on board Due (COM10). Please wait (might take a few minutes).
DPI detection failed, fallback to 96 dpi
Loading configuration...
Initializing packages...
Preparing boards...
Verifying...
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\arduino-builder -dump-prefs
-logger=machine -hardware
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\hardware -hardware
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages -tools
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\tools-builder -tools
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\hardware\tools\avr -tools
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages -built-in-libraries
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\libraries -libraries
C:\Users\leviusa90\Documents\Arduino\libraries -fqbn=arduino:sam:arduino_due_x_dbg -ide-version=10613 -build-path
C:\Users\LEVIUS~1\AppData\Local\Temp\ArduinoServer\MW -warnings=null
-prefs=build.path=C:\Users\LEVIUS~1\AppData\Local\Temp\ArduinoServer\MW -prefs=build.warn_data_percentage=75
-prefs=runtime.tools.bossac.path=C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\tools\bossac\1.6.1-arduino
-prefs=runtime.tools.arm-none-eabi-gcc.path=C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\tools\arm-none-eabi-gcc\4.8.3-2014q1
-verbose C:\Users\leviusa90\AppData\Local\Temp\ArduinoServer\ArduinoServer.ino
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\arduino-builder -compile
-logger=machine -hardware
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\hardware -hardware
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages -tools
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\tools-builder -tools
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\hardware\tools\avr -tools
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages -built-in-libraries
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\arduino-1.6.13\libraries -libraries
C:\Users\leviusa90\Documents\Arduino\libraries -fqbn=arduino:sam:arduino_due_x_dbg -ide-version=10613 -build-path
C:\Users\LEVIUS~1\AppData\Local\Temp\ArduinoServer\MW -warnings=null
-prefs=build.path=C:\Users\LEVIUS~1\AppData\Local\Temp\ArduinoServer\MW -prefs=build.warn_data_percentage=75
-prefs=runtime.tools.bossac.path=C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\tools\bossac\1.6.1-arduino
-prefs=runtime.tools.arm-none-eabi-gcc.path=C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\tools\arm-none-eabi-gcc\4.8.3-2014q1
-verbose C:\Users\leviusa90\AppData\Local\Temp\ArduinoServer\ArduinoServer.ino
Using board 'arduino_due_x_dbg' from platform in folder:
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7
Using core 'arduino' from platform in folder:
C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7
Detecting libraries used...
"C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-g++"
-c -g -Os -w -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib -fno-threadsafe-statics --param
max-inline-insns-single=500 -fno-rtti -fno-exceptions -Dprintf=iprintf -w -x c++ -E -CC -mcpu=cortex-m3 -mthumb
-DF_CPU=84000000L -DARDUINO=10613 -DARDUINO_SAM_DUE -DARDUINO_ARCH_SAM -D__SAM3X8E__ -mthumb -DUSB_VID=0x2341
-DUSB_PID=0x003e -DUSBCON '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Due"'
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\system/libsam"
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\system/CMSIS/CMSIS/Include/"
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\system/CMSIS/Device/ATMEL/"
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\cores\arduino"
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\variants\arduino_due_x"
"C:\Users\LEVIUS~1\AppData\Local\Temp\ArduinoServer\MW\sketch\ArduinoServer.ino.cpp" -o "nul"
Generating function prototypes...
"C:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-g++"
-c -g -Os -w -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib -fno-threadsafe-statics --param
max-inline-insns-single=500 -fno-rtti -fno-exceptions -Dprintf=iprintf -w -x c++ -E -CC -mcpu=cortex-m3 -mthumb
-DF_CPU=84000000L -DARDUINO=10613 -DARDUINO_SAM_DUE -DARDUINO_ARCH_SAM -D__SAM3X8E__ -mthumb -DUSB_VID=0x2341
-DUSB_PID=0x003e -DUSBCON '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Due"'
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\system/libsam"
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\system/CMSIS/CMSIS/Include/"
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\system/CMSIS/Device/ATMEL/"
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\cores\arduino"
"-IC:\ProgramData\MATLAB\SupportPackages\R2017a\3P.instrset\arduinoide.instrset\idepkgs\packages\arduino\hardware\sam\1.6.7\variants\arduino_due_x"
"C:\Users\LEVIUS~1\AppData\Local\Temp\ArduinoServer\MW\sketch\ArduinoServer.ino.cpp" -o
"C:\Users\LEVIUS~1\AppData\Local\Temp\ArduinoServer\MW\preproc\ctags_target_for_gcc_minus_e.cpp"
exec:
"C:\\ProgramData\\MATLAB\\SupportPackages\\R2017a\\3P.instrset\\arduinoide.instrset\\idepkgs\\packages\\arduino\\tools\\arm-none-eabi-gcc\\4.8.3-2014q1/bin/arm-none-eabi-g++":
file does not exist
Error compiling for board Arduino Due (Programming Port).
Madhu Govindarajan
Madhu Govindarajan 2019년 1월 17일
This looks like installation issue and something went wrong during download and install. Please try the following and if you still get the same error message reach out to MathWorks Technical support -
1) Uninstall MATLAB and SImulink Support package for Arduino.
2) Close MATLAB and reopen with administrator access. Right click on MATLAB icon and select Run as administrator.
3) Install MATLAB Support package for Arduino.
4) Try the command a = arduino('COM#','Due','TraceOn',true)
john white
john white 2019년 1월 17일
ok thank you so much for your answer and your spending time to answer me
madhan ravi
madhan ravi 2019년 1월 17일
Then accept his answer.
john white
john white 2019년 1월 17일
thanks for your notice , I have done

댓글을 달려면 로그인하십시오.

추가 답변 (2개)

madhan ravi
madhan ravi 2019년 1월 12일
편집: madhan ravi 2019년 1월 12일

1 개 추천

Make sure the proper board (Arduino Uno or mini for example) and the port are selected.

댓글 수: 7

john white
john white 2019년 1월 12일
thanks for your answer
I'm sure that both of the port and board are correct but I don't know why this error is showing!
madhan ravi
madhan ravi 2019년 1월 12일
Are you using mac ?
john white
john white 2019년 1월 12일
No, I'm using windows 7
madhan ravi
madhan ravi 2019년 1월 12일
Did you download arduino support package?
john white
john white 2019년 1월 12일
yes of course and I could program on the Uno board but, with the Due one I couldn't
madhan ravi
madhan ravi 2019년 1월 12일
편집: madhan ravi 2019년 1월 12일
Oh, I have experience with Uno and Mini but Due not , sorry
john white
john white 2019년 1월 12일
ok thank you so much

댓글을 달려면 로그인하십시오.

nguyen nhan tinh
nguyen nhan tinh 2019년 12월 25일
편집: nguyen nhan tinh 2019년 12월 26일

0 개 추천

I have same this issue.
When i run cmd:
>> a = arduino('COM3','Due', 'TraceOn', true)
Updating server code on board Due (COM3). Please wait (might take a few minutes).
Loading configuration...
Initializing packages...
Preparing boards...
Error: sam: Unknown architecture
How to resolve it. I using Matlab 2017b with Win10 64bit
Thanks

댓글 수: 3

Madhu Govindarajan
Madhu Govindarajan 2019년 12월 26일
This means that the architecture necessary to program this board is missing. Try the following:
  1. Open Arduino IDE version supported by MATLAB. To open this IDE, type winopen(arduinoio.IDERoot) in MATLAB Command Window. Then open the Arduino Application in that folder.
  2. Go to Tools > Boards > Boards Manager.
  3. Search for ARduino Due here.
  4. The results should have Arduino SAM Boards. Check the version and install v 1.6.11 if not already done.
If this does not resolve your issue, contact MathWorks Technical Support.
nguyen nhan tinh
nguyen nhan tinh 2019년 12월 26일
Matlab worked.
Thanks for your support.
Walter Roberson
Walter Roberson 2019년 12월 26일
Thanks, Madhu Govindarajan .

댓글을 달려면 로그인하십시오.

카테고리

질문:

2019년 1월 12일

댓글:

2019년 12월 26일

Community Treasure Hunt

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

Start Hunting!

Translated by