Arduino Toolkit - Functions


The following functions are available:

General Functions

arduinosetupOpen the arduino config / programming tool to program the arduino hardware fo...
isarduinoCheck if input value is an arduino object
listArduinoLibrariesRetrieve list of all known arduino library modules that are available.
scanForArduinosScan system for programmed serial connected arduino boards.

Arduino Functions

@arduino/checkI2CAddressCheck that an address of given address responds on the I2C bus
@arduino/configurePinSet/Get pin mode for a specified pin on arduino connection.
@arduino/configurePinResourceSet/Get pin mode for a specified pin on arduino connection.
@arduino/decrementResourceCountDecrement the count of a named resource by 1 and return the new count.
@arduino/deleteFree resources of an arduino object.
@arduino/dispDisplay the arduino object in a verbose way, showing the board and available ...
@arduino/getEndianGet the endian used by the connected arduino.
@arduino/getI2CTerminalsGet a cell list of pin Ids available are used for I2C mode.
@arduino/getInterruptTerminalsGet a cell list of pin Ids available have interrupt functionality
@arduino/getLEDTerminalsGet a cell list of pin Ids available are connected natively to LEDs.
@arduino/getMCUGet the MCU used by the connected arduino.
@arduino/getPWMTerminalsGet a cell list of pin Ids available for PWM use.
@arduino/getPinAliasGet the pin actual pin name from a pin alias.
@arduino/getPinInfoGet the pin information from the input pins values.
@arduino/getPinsFromTerminalsGet the pin names from the input terminal values.
@arduino/getResourceCountGet the count of uses of a given resource.
@arduino/getResourceOwnerGet the owner of pin allocated previously by configurePinResource.
@arduino/getSPITerminalsGet a cell list of pin Ids available for SPI mode.
@arduino/getServoTerminalsGet a cell list of pin Ids available for servo use.
@arduino/getSharedResourcePropertyGet the value of a property from a given resource.
@arduino/getTerminalModeGet the mode of a pin allocated previously by configurePinResource.
@arduino/getTerminalsFromPinsGet the terminal number for each pin.
@arduino/incrementResourceCountIncrement the count value of a named resource by 1 and return the new count
@arduino/isTerminalAnalogReturn true if pin is capable of analog input
@arduino/isTerminalDigitalReturn true if pin is capable of digital functions
@arduino/playTonePlay a tone of a given frequency on a specified pin.
@arduino/readAnalogPinRead analog voltage of PIN.
@arduino/readDigitalPinRead digital value from a digital I/O pin.
@arduino/readVoltageRead analog voltage of a pin.
@arduino/resetSend reset command to arduino hardware to force a hardware reset.
@arduino/sendCommandSend a command with option data to the connected arduino, waiting up to a spe...
@arduino/setSharedResourcePropertySet property values for a given resource.
@arduino/uptimeGet the number of seconds the arduino board has been running concurrently.
@arduino/validatePinValidate that the mode is allowed for specified pin
@arduino/versionGet version of library code installed on arduino board
@arduino/writeDigitalPinWrite digital value to a digital I/O pin.
@arduino/writePWMDutyCycleSet pin to output a square wave with a specified duty cycle.
@arduino/writePWMVoltageEmulate an approximate voltage out of a pin using PWM.
@arduino/arduinoCreate a arduino object with a connection to an arduino board.

Arduino I2C Functions

scanI2CbusScan arduino for devices on the I2C bus.
@i2cdev/deleteFree resources of a i2cdev object.
@i2cdev/dispDisplay i2cdev object.
@i2cdev/readRead a specified number of bytes from a i2cdev object using optional precisio...
@i2cdev/readRegisterRead a specified number of bytes from a register of an i2cdev object using op...
@i2cdev/subsrefsubref for i2cdev
@i2cdev/writeWrite data to a i2cdev object using optional precision for the data byte used...
@i2cdev/writeRegisterWrite data to i2cdev object at a given registry position using optional preci...
@i2cdev/i2cdev‘i2cdev’ is depreciated and will be removed in a future version.
@device/deleteFree resources of a device object.
@device/dispDisplay device object.
@device/readRead a specified number of bytes from a i2c or serial device object using opt...
@device/readRegisterRead a specified number of bytes from a register of an i2cdev object using op...
@device/subsrefsubref for device
@device/writeWrite data to a I2C or serial device object using optional precision for the ...
@device/writeRegisterWrite data to i2c device object at a given registry position using optional p...

Arduino Rotary Encoder Functions

@rotaryEncoder/deleteFree resources of a encoder object.
@rotaryEncoder/dispDisplay the rotary encoder object in a verbose way,
@rotaryEncoder/readCountread count value from the rotary encoder.
@rotaryEncoder/readSpeedread rotational speed from the rotary encoder.
@rotaryEncoder/resetCountreset the rotary encoder count values
@rotaryEncoder/subsrefsubref for rotaryEncoder
@rotaryEncoder/rotaryEncoderCreate a rotaryEncoder object controlled by the input pins.

Arduino Servo Functions

@servo/deleteFree resources of a servo object.
@servo/dispDisplay servo object.
@servo/readPositionRead the position of a servo
@servo/subsrefsubref for servo
@servo/writePositionWrite the position to a servo.
@servo/servoCreate a servo object using a specified pin on a arduino board.

Arduino Shiftregister Functions

@shiftRegister/deleteFree resources of a shiftRegister object.
@shiftRegister/dispDisplay the register object in a verbose way,
@shiftRegister/readread a value from the shift register.
@shiftRegister/resetclear the shift register value.
@shiftRegister/writeWrite a value to the shift register.
@shiftRegister/subsrefsubref for shiftRegister
@shiftRegister/shiftRegisterCreate shift register of a given type, controlled by the input pins.

Arduino SPI Functions

@spidev/deleteFree resources of a spidev object.
@spidev/dispDisplay spidev object.
@spidev/subsrefsubref for spidev
@spidev/writeReadWrite uint8 data to spi device and return back clocked out response data of s...
@spidev/spidev‘spidev’ is depreciated and will be removed in a future version.
@device/deleteFree resources of a device object.
@device/dispDisplay device object.
@device/subsrefsubref for device
@device/writeReadWrite uint8 data to spi device and return back clocked out response data of s...

Arduino Serial Functions

@device/deleteFree resources of a device object.
@device/dispDisplay device object.
@device/flushFlush the serial port buffers
@device/readRead a specified number of bytes from a i2c or serial device object using opt...
@device/subsrefsubref for device
@device/writeWrite data to a I2C or serial device object using optional precision for the ...
@device/deviceCreate an i2c, spi or serial object to communicate on a connected arduino.

Arduino Device Functions

@device/deleteFree resources of a device object.
@device/dispDisplay device object.
@device/flushFlush the serial port buffers
@device/readRead a specified number of bytes from a i2c or serial device object using opt...
@device/readRegisterRead a specified number of bytes from a register of an i2cdev object using op...
@device/subsrefsubref for device
@device/writeWrite data to a I2C or serial device object using optional precision for the ...
@device/writeReadWrite uint8 data to spi device and return back clocked out response data of s...
@device/writeRegisterWrite data to i2c device object at a given registry position using optional p...
@device/deviceCreate an i2c, spi or serial object to communicate on a connected arduino.

Arduino Ultrasonic Functions

@ultrasonic/deleteFree resources of a ultrasonic object.
@ultrasonic/dispDisplay ultrasonic object.
@ultrasonic/subsrefsubref for ultrasonic
@ultrasonic/readDistanceRead the distance from a ultrasonic device
@ultrasonic/readEchoTimeMeasure the time for waves to reflect back to the ultrasonic device
@ultrasonic/ultrasonicCreate an ultrasonic object to communicate to a connected ultrasonic device

Arduino Addons

addonCreate an addon object using the addon named class.
arduinoioaddons.ExampleAddon.EchoBasic Example matlab/octave code to illustrate creating a user addon.
arduinoioaddons.ExampleLCD.LCDBasic Example octave addon for LCD
arduinoioaddons.EEPRomAddon.EEPRomEEPROM addon for arduino
arduinoioaddons.RTCAddon.DS1307DS1307 addon
arduinoioaddons.adafruit.motorshieldv2Adafruit motor shield addon
arduinoioaddons.adafruit.dcmotorv2DC Motor class for dc motor control on the adafruit motor shield
arduinoioaddons.adafruit.stepperStepper class for stepper control on the adafruit motor shield
arduinoioaddons.SimpleStepper.SimpleStepperStepper class for stepper control using ULN2003 and compatible drivers

Arduino Sensors

arduinosensor.DS1307DS1307 realtime clock sensor
arduinosensor.MPC3002MCP3002 ADC sensor
arduinosensor.SI7021SI7021 temperature and humidity sensor
arduinosensor.GUVAS12SDA thin wrapper for the GUVAS12SD analog UV-B sensor

Arduino I/O package

arduinoio.AddonBaseBase class used for arduino library sensors
arduinoio.FilePathGet the directory component of a pathname.
arduinoio.LibFilesGet the list of files used for the building arduino library
arduinoio.LibraryBaseBase class used for arduino library plugins
arduinoio.getBoardConfigReturn the configuration for a known arduino board type

Matlab Compatibility Classes

matlabshared.addon.LibraryBaseCompatability class used for arduino library plugins using matlabshared.addon...

Sensors

bme280BME280 pressure, temperature and humidity sensor
bno055BNO055 9 axis orientation sensor
lis3dhLIS3DH 3 degrees sensor
lps22hbLPS22HB absolute pressure and temperature sensor
lsm6dsoLSM6DSO 6 degrees sensor
mpu6050MPU-6050 6 degrees sensor
si7021SI7021 temperature and humidity sensor

Test Functions

arduino_bistsetupInstall on an arduino the required core libraries to run the BIST tests