Cannot find a MATLAB message class for type geometry_msgs/Twist

Hello!
I follow the official steps to create custom ros messages and when I use " rosmsg list " to check it, my custom message is right here.
However, it didn't work when I use rosmessage('geometry_msgs/Twist'),
and it shows "Cannot find a MATLAB message class for type geometry_msgs/Twist".
Also, if I use the command " msginfo=rosmsg("show",'geometry_msgs/Twist') ",
it shows "Could not find definition of message type geometry_msgs/Twist. Check the spelling of the type, or use "rosmsg list" to retrieve a list of available message types."

답변 (1개)

鼎 钟
鼎 钟 2022년 4월 20일

0 개 추천

I have the same question with you. But finally, I find the problem is just because your path contains chinese.
You can try command 'javaclasspath' to check if the path of your custom ros message contains strange characters. Maybe it's java's fault.

카테고리

질문:

2020년 9월 1일

답변:

2022년 4월 20일

Community Treasure Hunt

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

Start Hunting!

Translated by