Dear Matlab Expert,
I am trying to connect Niryo one robot with Matlab R2020b on Windows10. In doing so, I receive the following error message.
folderpath = "C:\Users\Afsoon\Downloads\Applications\niryo_one_ros-master";
>> rosgenmsg(folderpath)
Identifying message files in folder 'C:/Users/Afsoon/Downloads/Applications/niryo_one_ros-master'..Done.
Validating message files in folder 'C:/Users/Afsoon/Downloads/Applications/niryo_one_ros-master'..Done.
[0/1] Generating MATLAB interfaces for custom message packages... 0%Error using ros.internal.utilities.getCMakeBinaryPath (line 19)
Could not find CMake in your system. Please install CMake version 3.15.5 or higher and rerun the command.
Error in ros.internal.CatkinBuilder.getCMakePath (line 82)
[aPath, aVersion] = ros.internal.utilities.getCMakeBinaryPath(ros.internal.CatkinBuilder.CMAKEMINVERSION);
Error in ros.internal.ROSProjectBuilder (line 391)
h.CMakePath = h.getCMakePath();
Error in ros.internal.CatkinBuilder (line 24)
h@ros.internal.ROSProjectBuilder(varargin{:});
Error in rosgenmsg (line 223)
builder = ros.internal.CatkinBuilder(genDir, pkgInfos{iPkg});
I have installed CMake, Visual Studio 2019, and Python 2.7. Also, CMake is available on the system PATH environment variable. I appreciate your advice on this issue!
Thanks,

 採用された回答

Cam Salzberger
Cam Salzberger 2021 年 5 月 13 日

0 投票

Hello Afsoon,
Can you try running this code in MATLAB:
!cmake --version
If you see any warning messages about libcurl or libstdc++, see this answer for suggestions and workarounds that users have found.
-Cam

3 件のコメント

Afsoon Nejati Aghdam
Afsoon Nejati Aghdam 2021 年 5 月 13 日
Dear Cam,
Thanks for the reply.
>>!cmake --version
cmake version 3.20.2
CMake suite maintained and supported by Kitware (kitware.com/cmake)
Then I run the code:
>>rosgenmsg(folderpath)
Identifying message files in folder 'C:/Users/Afsoon/Downloads/Applications/niryo_one_ros-master'..Done.
Validating message files in folder 'C:/Users/Afsoon/Downloads/Applications/niryo_one_ros-master'..Done.
[0/1] Generating MATLAB interfaces for custom message packages... 0%Error using ros.internal.ROSProjectBuilder (line 396)
No C++ compiler selected for ROS build. To choose a compiler, run 'mex -setup cpp'.
Error in ros.internal.CatkinBuilder (line 24)
h@ros.internal.ROSProjectBuilder(varargin{:});
Error in rosgenmsg (line 223)
builder = ros.internal.CatkinBuilder(genDir, pkgInfos{iPkg});
Then, I run teh code:
>>mex -setup cpp
MEX configured to use 'MinGW64 Compiler (C++)' for C++ language compilation.
What compiler do you suggest?
Thanks so much,
Cam Salzberger
Cam Salzberger 2021 年 5 月 18 日
R2020b requires Visual Studio 2017 as the only supported compiler for Windows.
The use of Visual Studio for Windows is unfortunately a ROS requirement, so MinGW will not work.
-Cam
Afsoon Nejati Aghdam
Afsoon Nejati Aghdam 2021 年 5 月 19 日
編集済み: Afsoon Nejati Aghdam 2021 年 5 月 19 日
Dear Cam,
Thanks so much for the reply. Yes, the problem is solved by using visual studio 2017 instead of the 2019-version.
Best of luck,

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange で Custom Message Support についてさらに検索

製品

リリース

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by