imitate.cpp
Go to the documentation of this file.
1 
10 #include <ctrl/imitate.hpp>
11 
12 
13 // Cf Controller::chooseVelocities(...)
14 void ImitateCtrl::chooseVelocities(double& trans_vel, double& rot_vel,
15  std::ostream& log_str) {
16  searchGoal(); // updates the goal to be after the robot's date
17  // gets the goal's velocities
18  moving_velocity = (*goal)->translationVelocity();
19  turning_velocity = (*goal)->rotationVelocity();
20  // updates the parameters and send the update signal
21  updateVelocities(trans_vel, rot_vel);
22 } // end of void ImitateCtrl::chooseVelocities(double&, double&, ...)-
void searchGoal(const double &forwardTime=0)
Moves the goal forward until it gets after the robot&#39;s date plus a given amount of time...
Definition: track.hpp:38
double moving_velocity
Translation velocity desired for the robot.
Definition: controller.hpp:45
void updateVelocities(double &trans_vel, double &rot_vel)
Update the velocities from the fields and send the update signal.
Definition: controller.hpp:66
double turning_velocity
Rotation velocity desired for the robot.
Definition: controller.hpp:47
Path following controller class, copying the velocities.
virtual void chooseVelocities(double &trans_vel, double &rot_vel, std::ostream &log_str)
Computes new velocities for ROS node.
Definition: imitate.cpp:14


qt_ctrl
Author(s): Alexis Scheuer
autogenerated on Wed Dec 16 2020 15:51:32