Filter löschen
Filter löschen

Installing Arduino sensor library to Matlab

17 Ansichten (letzte 30 Tage)
akkaya
akkaya am 18 Jan. 2023
Hello, I want to install an Arduino library for Pololu VL53L1X to Matlab (library source here: https://github.com/pololu/vl53l1x-arduino), I tried following this example and changed
a = arduino('COM4','Uno','Libraries','Adafruit\MotorShieldV2')
to
a = arduino('COM9','Uno','libraries','VL53L1X')
The directory for the library on my computer is C:\Users\hp\Documents\<name>\Arduino\libraries\VL53L1X, so I assumed I just have to add the VL53L1X part but I'm getting this error:
Expected libraries to match one of these values:
'APDS9960', 'Adafruit/MotorShieldV2', 'CAN', 'I2C', 'MotorCarrier', 'RotaryEncoder', 'SPI', 'Serial', 'Servo',
'ShiftRegister', 'Ultrasonic'
The input, 'VL53L1X', did not match any of the valid values.
What am I doing wrong? Is there a way of including Arduino libraries to Matlab by referring to Arduino library directory?

Akzeptierte Antwort

Amit Charantimath
Amit Charantimath am 8 Feb. 2023
Hi Akkaya
For libraries not directly supported by MATLAB Arduino. You can use the "Custom Arduino library" feature to integrate the VL53L1X library with MATLAB Arduino.
Here is the documentation that describes integration of Custom librares. With this feature you can integratem the driver of VL53L1X.
Thanks,
Amit

Weitere Antworten (1)

Ashu
Ashu am 27 Jan. 2023
Hi Akkaya,
You can not use the Arduino Libraries directly in MATLAB.
For the list of supported Arduino Libraries in MATLAB, please refer the following documentation.

Kategorien

Mehr zu Arduino Hardware finden Sie in Help Center und File Exchange

Produkte


Version

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by