提交 cc54cc43 编写于 作者: J jmtao 提交者: Liangliang Zhang

planning: fix stop reason of stopping for head vehicles

上级 7de2f466
......@@ -377,7 +377,15 @@ void FrontVehicle::MakeStopDecision(
ObjectDecisionType stop;
auto stop_decision = stop.mutable_stop();
stop_decision->set_reason_code(StopReasonCode::STOP_REASON_OBSTACLE);
if (obstacle_type == PerceptionObstacle::UNKNOWN_MOVABLE ||
obstacle_type == PerceptionObstacle::BICYCLE ||
obstacle_type == PerceptionObstacle::VEHICLE) {
stop_decision->set_reason_code(
StopReasonCode::STOP_REASON_HEAD_VEHICLE);
} else {
stop_decision->set_reason_code(
StopReasonCode::STOP_REASON_OBSTACLE);
}
stop_decision->set_distance_s(-stop_distance);
stop_decision->set_stop_heading(stop_heading);
stop_decision->mutable_stop_point()->set_x(stop_point.x());
......
......@@ -849,7 +849,7 @@ trajectory_point {
decision {
main_decision {
stop {
reason_code: STOP_REASON_OBSTACLE
reason_code: STOP_REASON_HEAD_VEHICLE
reason: "stop by 6211"
stop_point {
x: 586575.19098307879
......@@ -865,7 +865,7 @@ decision {
perception_id: 6211
object_decision {
stop {
reason_code: STOP_REASON_OBSTACLE
reason_code: STOP_REASON_HEAD_VEHICLE
distance_s: -6
stop_point {
x: 586575.19098307879
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册