Quantcast
Channel: ROS Answers: Open Source Q&A Forum - RSS feed
Viewing all articles
Browse latest Browse all 85

code explanation

$
0
0
hi guys. I need help understanding this code. What does it do? 00802 private void publishVelocity(double linearVelocityX, double linearVelocityY, 00803 double angularVelocityZ) { 00804 currentVelocityCommand.getLinear().setX(linearVelocityX); 00805 currentVelocityCommand.getLinear().setY(-linearVelocityY); 00806 currentVelocityCommand.getLinear().setZ(0); 00807 currentVelocityCommand.getAngular().setX(0); 00808 currentVelocityCommand.getAngular().setY(0); 00809 currentVelocityCommand.getAngular().setZ(-angularVelocityZ); 00810 } Publish the velocity as a ROS Twist message. Parameters:
 linearVelocityX The normalized linear velocity (-1 to 1). angularVelocityZ The normalized angular velocity (-1 to 1). ---------- currentVelocityCommand declaration: private geometry_msgs.Twist currentVelocityCommand;

Viewing all articles
Browse latest Browse all 85

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>