Skip to content

Commit

Permalink
planning: add RESUME CRUISE command to pad_message tool
Browse files Browse the repository at this point in the history
  • Loading branch information
jmtao committed Nov 7, 2019
1 parent 6577f77 commit 588b91e
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions modules/planning/tools/pad_terminal.cc
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ class PadTerminal {
AINFO << "\t2: change right";
AINFO << "\t3: pull over";
AINFO << "\t4: stop";
AINFO << "\t5: resume cruise";
AINFO << "\t10: exit";
AINFO << "\tother number: print help";
}
Expand All @@ -56,15 +57,17 @@ class PadTerminal {
PadMessage pad;
pad.set_action(DrivingAction(action));
if (action == DrivingAction::FOLLOW) {
AINFO << "sending follow action command.";
AINFO << "sending FOLLOW action command.";
} else if (action == DrivingAction::CHANGE_LEFT) {
AINFO << "sending change left action command.";
AINFO << "sending CHANGE LEFT action command.";
} else if (action == DrivingAction::CHANGE_RIGHT) {
AINFO << "sending change right action command.";
AINFO << "sending CHANGE RIGHT action command.";
} else if (action == DrivingAction::PULL_OVER) {
AINFO << "sending pull over action command.";
AINFO << "sending PULL OVER action command.";
} else if (action == DrivingAction::STOP) {
AINFO << "sending stop action command.";
AINFO << "sending STOP action command.";
} else if (action == DrivingAction::RESUME_CRUISE) {
AINFO << "sending RESUME CRUISE action command.";
}
apollo::common::util::FillHeader("terminal", &pad);
pad_writer_->Write(std::make_shared<PadMessage>(pad));
Expand All @@ -91,6 +94,9 @@ class PadTerminal {
case 4:
send(DrivingAction::STOP);
break;
case 5:
send(DrivingAction::RESUME_CRUISE);
break;
case 10:
should_exit = true;
break;
Expand Down

0 comments on commit 588b91e

Please sign in to comment.