필터 지우기
필터 지우기

Error rosgenmsg (line 480) : error build log

조회 수: 7 (최근 30일)
Laurent GARI
Laurent GARI 2023년 4월 5일
댓글: Laurent GARI 2023년 4월 6일
Hi,
I want to generate some custom ROS messages in Matlab for communicate with a robot NED2 of Nyrio. To generate custom ROS I follow this tutorial.
I install all extention like CMake, the package ros ned_ros in the first root of my hard disk, Visual Studio 2019 is my compiler c++ in matalb (configuartion with mex -setup), ROS toolbox has been installed.
After all this installation, I eecute this command Matlab.
folderpath = "D:\ned_ros"
rosgenmsg(folderpath)
And I have the following result :
folderpath =
"D:\ned_ros"
Identifying message files in folder 'D:/ned_ros'..Done.
Validating message files in folder 'D:/ned_ros'..Done.
[13/13] Generating MATLAB interfaces for custom message packages... Done.
Running catkin build in folder 'D:/ned_ros/matlab_msg_gen_ros1/win64'.
Build in progress. This may take several minutes...Error using ros.internal.ROSProjectBuilder/buildPackage
Error building package: build log.
Error in rosgenmsg (line 480)
buildPackage(builder, [], 'install', catkinMakeArgs); %other messages might need to be present in the same directory
Error in configuration_Matlab (line 5)
rosgenmsg(folderpath)
I didn't understand why the problem is related why a script of the toolbox. You can see my build log as an attachment.
How can I fix the issue and build the custom messages?
thanks in advance.

채택된 답변

Jagadeesh Konakalla
Jagadeesh Konakalla 2023년 4월 6일
Hi,
When I analyzed error, the error is related to redefinition error. I found that one of the message file has issue. I see that REBOOT_MOTOR constant is defined twice in the message file (niryo_robot_status\msg\RobotStatus.msg). Once in the line number 10 and other line number 21.
You need to remove one definition.
I removed the line number 21 and tried rosgenmsg, it works without issue.
Thanks,
Jagadeesh
  댓글 수: 1
Laurent GARI
Laurent GARI 2023년 4월 6일
Hi,
Thank you a lot for your help Jagadeesh. Have a good day.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Specialized Messages에 대해 자세히 알아보기

제품


릴리스

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by