controling right and left wheels using ROS
Dear guys,
Can anyone help me, i just follow a tutorial to make "Differential Drive Robot" from this link:
https://www.generationrobots.com/blog...
in the tutorial, Mobile robot models can be moved using cmd_vel (by controlling linear,x and angular.z). How can i control right and left wheels based on the trajectory? Im newbie :(
Thank you in advance
this is my code:
ros::Publisher pLeft = nh.advertise<std_msgs::Float64>("/my_robot/leftWheel_effort_controller/command",1);
ros::Publisher pRight = nh.advertise<std_msgs::Float64>("/my_robot/rightWheel_effort_controller/command",1);
std_msgs::Float64 stdMessage;
pLeft.publish(stdMessage);
pRight.publish(stdMessage);
But, it do nothing :(
Welcome! What have you tried so far (an example of your code please)? Showing that you've put forth some effort is likely to increase your chances of getting help with this.
i have showed the code