MCPcopy Create free account
hub / github.com/NKU-MobFly-Robotics/LRAE / pathHandler

Function pathHandler

local_planner/src/pathFollower.cpp:120–139  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

118}
119
120void pathHandler(const nav_msgs::Path::ConstPtr& pathIn)
121{
122 int pathSize = pathIn->poses.size();
123 path.poses.resize(pathSize);
124 for (int i = 0; i < pathSize; i++) {
125 path.poses[i].pose.position.x = pathIn->poses[i].pose.position.x;
126 path.poses[i].pose.position.y = pathIn->poses[i].pose.position.y;
127 path.poses[i].pose.position.z = pathIn->poses[i].pose.position.z;
128 }
129
130 vehicleXRec = vehicleX;
131 vehicleYRec = vehicleY;
132 vehicleZRec = vehicleZ;
133 vehicleRollRec = vehicleRoll;
134 vehiclePitchRec = vehiclePitch;
135 vehicleYawRec = vehicleYaw;
136
137 pathPointID = 0;
138 pathInit = true;
139}
140
141void joystickHandler(const sensor_msgs::Joy::ConstPtr& joy)
142{

Callers

nothing calls this directly

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected