Exercise 3.1 # ROS Basics in 5 days # Unit 3 understanding ROS Topics

Hi !

I tried to do the exercise myself but I could not do it fully. I saw the solution they work. But I am confused :

  1. firstly , how can we know that we have to get “from geometry_msgs.msg import Twist” this from messages list ? how can we see the structure of this message .

  2. Secondly , How can we know these methods of our class twist :
    " move.linear.x = 0.5
    move.angular.z = 0.5 "

You can use the command as below:
rosmsg show geometry_msgs/Twist
This will show the structure of the msg we are using.

You will get exposure to how this works when you get to the section about creating custom ros messages.