Adapt Add-ons to New matlabshared.addon.LibraryBase Class
If you have been using the arduinoio.LibraryBase
class, follow these
steps to adapt your add-ons to the new matlabshared.addon.LibraryBase
class:
Inherit your custom add-on class from
matlabshared.addon.LibraryBase
classdef MyAddon < matlabshared.addon.LibraryBase
Add the property
Pins
to your custom add-on class to continue using it, as this is not included inmatlabshared.addon.LibraryBase
.properties(Access = protected) Pins end
Change the
ArduinoLibraryHeaderFiles
property toLibraryHeaderFiles
.LibraryName = 'ExampleLCD/LCDAddon' DependentLibraries = {} LibraryHeaderFiles = 'LiquidCrystal/LiquidCrystal.h' CppHeaderFile = fullfile(arduinoio.FilePath(mfilename('fullpath')),'src','LCD.h') CppClassName = 'LCD'
listArduinoLibraries
.