Possible bug found in listArduinoLibraries()

조회 수: 3 (최근 30일)
Clayton Allen
Clayton Allen 2024년 12월 3일
답변: Sreeram 2024년 12월 11일
Greetings,
I have followed the tutorial for the creation of a HelloWorld Arduino Addon Library. Upon completion I was unable to get the addon to register so I subsequently followed the documention for Custom Arduino Library Issues.
1.
clear classes
2.
rehash toolboxcache
Produces a warning:
Warning: Function license has the same name as a MATLAB built-in. We suggest you rename the function to avoid a potential name conflict.
3.
lib = listArduinoLibraries();
Produces a list of warnings and errors
Warning: The following error was caught while executing 'onCleanup' class destructor:
Output argument "status" (and possibly others) not assigned a value in the execution with "matlabshared.ddux/HWSDKDataUtility/dataUpdateImpl" function.
Error in matlabshared.internal.DataUtility/dataUpdate
Error in matlabshared.ddux.HWSDKDataUtilityHelper/integrateData
Error in listArduinoLibraries>@()integrateData(dduxHelper) (line 17)
c = onCleanup(@()integrateData(dduxHelper));
^^^^^^^^^^^^^^^^^^^^^^^^^
Error in onCleanup/delete (line 25)
obj.task();
^^^^^^^^^^
Error in listArduinoLibraries (line 72)
end
^
And of course, my HelloWorld addon doesn't register. Perhaps this potential bug might be the cause?
Cheers,
  댓글 수: 4
Les Beckham
Les Beckham 2024년 12월 5일
Interesting. Did you try which -all license in Matlab Online? The error messages that you showed seemed to indicate an issue with that command.
Clayton Allen
Clayton Allen 2024년 12월 5일
/MATLAB/toolbox/matlab/connector2/shadowfiles/shadows/license/license.m
built-in (/MATLAB/toolbox/local/license) % Shadowed

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

답변 (1개)

Sreeram
Sreeram 2024년 12월 11일
Hi Clayton,
I also encountered the same warnings and errors when callinglistArduinoLibraries()in MATLAB Online.
I fixed it by running the following snippet before calling listArduinoLibraries():
system('mkdir -p overloads/+matlab/+ddux/+internal');
system (['echo -e "function status = logData(identification, varargin) \\n status = true; \\n end" > overloads/+matlab/+ddux/+internal/logData.m']);
addpath('./overloads');
Regarding warning about license, I remember seeing in an older documentation of “rehash” that this functionality was not supported in MATLAB Online. This might be contributing to the unexpected behaviour.

카테고리

Help CenterFile Exchange에서 Arduino Hardware에 대해 자세히 알아보기

제품


릴리스

R2024b

Community Treasure Hunt

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

Start Hunting!

Translated by