From 5a007f2dad9507b2aa67631f99d60fec2a22f7de Mon Sep 17 00:00:00 2001 From: Sergi Hernandez Juan <shernand@iri.upc.edu> Date: Thu, 10 May 2018 10:19:13 +0200 Subject: [PATCH] =?UTF-8?q?Changed=20the=20sign=20of=20the=20yaw=20top?= =?UTF-8?q?=C3=ACc=20to=20coincide=20with=20the=20ral=20robot.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- seat_car_controller/include/seat_car_controller_impl.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/seat_car_controller/include/seat_car_controller_impl.h b/seat_car_controller/include/seat_car_controller_impl.h index 39e32ee..a5cc39e 100644 --- a/seat_car_controller/include/seat_car_controller_impl.h +++ b/seat_car_controller/include/seat_car_controller_impl.h @@ -350,6 +350,10 @@ namespace seat_car_controller twist_msg.linear.x=-((drive_r_l_vel-drive_r_r_vel)*5.5)/2.0; twist_msg.linear.y=0.0; twist_msg.linear.z=0.0; + twist_msg.angular.x=0.0; + twist_msg.angular.y=0.0; + twist_msg.angular.z=0.0; + this->twist_pub.publish(twist_msg); servo_angle=-4.0*steer_angle+3.14159/2.0; @@ -435,7 +439,7 @@ namespace seat_car_controller std_msgs::Float32 yaw_msg; this->heading=tf::getYaw(msg->orientation); - yaw_msg.data=this->heading; + yaw_msg.data=-this->heading*180.0/3.14159; this->yaw_pub.publish(yaw_msg); } -- GitLab