How to import JRodrigoTech/HCSR04 in arduino library
조회 수: 4 (최근 30일)
이전 댓글 표시
I get this add-on library from mathwork
And I don’t know how to add jrodrigotech/hcsr04 library to arduino libraries in matlab
댓글 수: 0
답변 (1개)
Madhu Govindarajan
2018년 8월 9일
1. Download the zip file from https://github.com/JRodrigoTech/Ultrasonic-HC-SR04/archive/master.zip 2. Unpackage the zip into local directory and rename the folder to ‘Ultrasonic’. 3. Move the ‘Ultrasonic’ folder into the "libraries" folder inside your Arduino sketchbook folder: On Windows, the default path is "My Documents\Arduino\libraries\" On Mac, the default path is "~/Documents/Arduino/libraries/" On Linux, the default path is "/home/<username>/Arduino/libraries" Then follow the example provided here https://www.mathworks.com/matlabcentral/fileexchange/57898-hc-sr04-add-on-library-for-arduino.
댓글 수: 2
Nalin Das
2018년 8월 25일
I tried everything from putting the Ultrasonic folder in Documents/Arduino/libraries/ and C:\ProgramData\MATLAB\SupportPackages\R2018a\3P.instrset\arduinoide.instrset\arduino-1.8.1 But none of it is reflecting in the library list ... pls help ASAP
Madhu Govindarajan
2018년 8월 27일
When something does not show up on the listArduinoLibraries, it is because they are not on MATLAB's path.
If you downloaded the submission as toolbox
1) Go to MATLAB > Preferences. Here Under MATLAB, Add-Ons check the location and go there from MATLAB Command Window, ex. cd 'C:\Users\mgovinda\MATLAB' in my case. 2) Check if this toolbox is properly installed and the code folder is on MATLAB's path. Ex - 'cd 'C:\Users\mgovinda\MATLAB\Toolboxes\HC-SR04 Add-On Library for Arduino'' 3) If not, feel free to add it to path manually or reinstall.
If you downloaded the submission as zip file 1) Go to the extracted folder in MATLAB and go one level up. 2) Right click on the folder and select Add to Path > Selected Folders and Subfolders.
HTH,
Madhu
참고 항목
카테고리
Help Center 및 File Exchange에서 Arduino Hardware에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!