Skip to content

Commit 3e15d70

Browse files
committed
fixes
1 parent 017f267 commit 3e15d70

5 files changed

Lines changed: 23 additions & 23 deletions

File tree

param/planner.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ use_jrk: false
2222

2323
# min/max time discretization for each primitive
2424
min_dt: 0.10
25-
max_dt: 0.20
25+
max_dt: 0.25
2626

2727
# max number of time discretization for a plan
2828
ndt: 1000

param/platform_2.0.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Params for drone size for planner
2-
radius: 0.675 # meters
3-
buffer: 0.325 # meters
2+
radius: 0.6 # meters
3+
buffer: 0.1 # meters
44

55
# kinematic constraints
66
max_speed: 0.75 # m/s
7-
max_acceleration: 1.5 # m/s^2
8-
max_jerk: 7.5 # m/s^3
7+
max_acceleration: 1.0 # m/s^2
8+
max_jerk: 4.0 # m/s^3
99

1010
# tolerances
1111
p_tol: 0.1

param/platform_crazyflie.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Params for drone size for planner
2-
radius: 0.675 # meters
3-
buffer: 0.325 # meters
2+
radius: 0.6 # meters
3+
buffer: 0.1 # meters
44

55
# kinematic constraints
66
max_speed: 0.75 # m/s
7-
max_acceleration: 1.5 # m/s^2
8-
max_jerk: 7.5 # m/s^3
7+
max_acceleration: 1.0 # m/s^2
8+
max_jerk: 4.0 # m/s^3
99

1010
# tolerances
1111
p_tol: 0.1

param/platform_sim.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Params for drone size for planner
2-
radius: 0.675 # meters
3-
buffer: 0.325 # meters
2+
radius: 0.6 # meters
3+
buffer: 0.1 # meters
44

55
# kinematic constraints
66
max_speed: 0.75 # m/s
7-
max_acceleration: 1.5 # m/s^2
8-
max_jerk: 7.5 # m/s^3
7+
max_acceleration: 1.0 # m/s^2
8+
max_jerk: 4.0 # m/s^3
99

1010
# tolerances
1111
p_tol: 0.1

src/MotionPlanner.cpp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ int main(int argc, char **argv) {
286286
}
287287

288288
if (last_msg == nullptr) {
289-
ROS_ERROR("MotionPlanner: No obstacle information available, can't build map");
289+
ROS_DEBUG_THROTTLE(30,"MotionPlanner: No obstacle information available, can't build map");
290290
} else {
291291
// get a new goal from action server
292292
if (server.isNewGoalAvailable()) {
@@ -297,11 +297,11 @@ int main(int argc, char **argv) {
297297
goal_ = server.acceptNewGoal();
298298

299299
// offset by start pose so that we never "go out" of arena
300-
double x_offset = -goal_->start.motion_point.pose.position.x;
301-
double y_offset = -goal_->start.motion_point.pose.position.y;
300+
double x_offset = 10;
301+
double y_offset = 10;
302302

303-
pose_start.x = 0.0;
304-
pose_start.y = 0.0;
303+
pose_start.x = goal_->start.motion_point.pose.position.x + x_offset;
304+
pose_start.y = goal_->start.motion_point.pose.position.y + y_offset;
305305
pose_start.z = goal_->start.motion_point.pose.position.z;
306306

307307
twist_start = goal_->start.motion_point.twist.linear;
@@ -356,17 +356,17 @@ int main(int argc, char **argv) {
356356
for (float r = 0; r < pipe_radius; r += map_res) {
357357
px = r * std::cos(theta) + pipe_x + voxel_map_origin[0];
358358
py = r * std::sin(theta) + pipe_y + voxel_map_origin[1];
359-
Vec3f pt(px, py, std::min(max_arena_limits[2], pz + buffer));
359+
Vec3f pt(px, py, pz);
360360
pts.push_back(pt);
361361
}
362362
}
363363
}
364364
}
365365

366366
std::array<decimal_t, 3> voxel_map_dim =
367-
{map.dim.x * map_res,
368-
map.dim.y * map_res,
369-
map.dim.z * map_res};
367+
{max_arena_limits[0],
368+
max_arena_limits[1],
369+
max_arena_limits[2]};
370370

371371
std::unique_ptr<VoxelGrid> voxel_grid(
372372
new VoxelGrid(voxel_map_origin, voxel_map_dim, map_res));
@@ -383,7 +383,7 @@ int main(int argc, char **argv) {
383383

384384
map_util->setMap(ori, dim, map.data, map_res);
385385

386-
ROS_INFO("Takes %f sec for building and setting map",
386+
ROS_DEBUG_THROTTLE(30,"Takes %f sec for building and setting map",
387387
(ros::WallTime::now() - t1).toSec());
388388

389389
iarc7_msgs::PlanResult result_;

0 commit comments

Comments
 (0)