Preventing Re-uploading of Arduino Code with Custom Add-on

조회 수: 7 (최근 30일)
Floris
Floris 2019년 6월 4일
답변: Floris 2019년 6월 4일
Hello,
I am currently using the Arduino Support from MATLAB add-on to upload code to my Arduino Uno. I also wrote a custom add-on for an Arduino Library which has been working great. However, now I no longer need to make any changes to the code uploaded to the board. Still, whenever I start my program, the server code on my Uno board is updated, which takes a while. This isn't necessarily a problem, but it does waste time as I attempt to debug other bugs in my code.
These lines of code causes the board to re-upload the code everytime I run it, even if I set ForceBuildOn to false. I suspect that it might be the custom library that I am linking as an add-on that causes the re-upload.
self.arduino = arduino('COM11', 'Uno', 'Libraries', 'Nunchuk/Nunchuk', 'ForceBuildOn', false, 'Trace', true);
self.nunchukAdd = addon(self.arduino, 'Nunchuk/Nunchuk');
Is there any way to save the arduino object or the custom library to stop having to re-upload the code to my board and waste a few minutes?
Thanks,
Floris

채택된 답변

Floris
Floris 2019년 6월 4일
I was able to solve the problem myself by restarting the Arduino as well as matlab, and then ensuring that 'ForceBuildOn' was set to false.
self.arduino = arduino('COM11', 'Uno', 'Libraries', 'Nunchuk/Nunchuk', 'ForceBuildOn', false, 'Trace', true);

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 I2C Devices에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by