Skip to content

Commit

Permalink
Removed commented lines from planning server
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidSpielman authored and marip8 committed May 29, 2024
1 parent 7ff1968 commit 4302c7f
Showing 1 changed file with 1 addition and 34 deletions.
35 changes: 1 addition & 34 deletions snp_motion_planning/src/planning_server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -634,8 +634,6 @@ class PlanningServer

tesseract_planning::CompositeInstruction freespace_program(PROFILE, tesseract_planning::CompositeInstructionOrder::ORDERED,
manip_info);
// tesseract_planning::CompositeInstruction repeat_process(PROFILE);
// repeat_process.setDescription("repeat_process");

tesseract_planning::JointWaypoint wp1 = rosJointStateToJointWaypoint(req->js1);
tesseract_planning::JointWaypoint wp2 = rosJointStateToJointWaypoint(req->js2);
Expand All @@ -650,28 +648,6 @@ class PlanningServer
tesseract_planning::MoveInstruction(tesseract_planning::JointWaypointPoly{wp2},
tesseract_planning::MoveInstructionType::FREESPACE, PROFILE, manip_info));

// Add the composite to the program
// freespace_program.push_back(repeat_process);

// Create a manipulator info and program from the service request
// const std::string& base_frame = req->tool_paths.at(0).segments.at(0).header.frame_id;
// if (base_frame.empty())
// {
// throw std::runtime_error("Base frame is empty!");
// }
// if (req->motion_group.empty())
// {
// throw std::runtime_error("Motion group is empty!");
// }
// if (req->tcp_frame.empty())
// {
// throw std::runtime_error("TCP frame is empty!");
// }
// tesseract_common::ManipulatorInfo manip_info(req->motion_group, base_frame, req->tcp_frame);

// Set up composite instruction and environment
// tesseract_planning::CompositeInstruction program = createProgram(manip_info, fromMsg(req->tool_paths));

// Add the scan link to the planning environment
addScanLink(req->mesh_filename, req->mesh_frame);

Expand All @@ -680,18 +656,9 @@ class PlanningServer
auto freespace_task_name = get<std::string>(node_, FREESPACE_TASK_NAME_PARAM);
tesseract_planning::CompositeInstruction program_results = plan(freespace_program, pd, freespace_task_name);

// Remove scan link?
// Remove scan link
removeScanLink();

// if (program_results.size() != 1)
// {
// std::stringstream ss;
// ss << "The composite instruction must have at least 1 child. "
// "This result only has "
// << program_results.size();
// throw std::runtime_error(ss.str());
// }

// Return results

res->trajectory = tesseract_rosutils::toMsg(toJointTrajectory(program_results), env_->getState());
Expand Down

0 comments on commit 4302c7f

Please sign in to comment.