提交 1a0fab64 编写于 作者: W Wang Yu 提交者: Qi Luo

Control: replace check_gt with AERROR on loading control_conf

上级 4311a0fb
......@@ -97,7 +97,10 @@ bool LatController::LoadControlConf(const ControlConf *control_conf) {
common::VehicleConfigHelper::Instance()->GetConfig().vehicle_param();
ts_ = control_conf->lat_controller_conf().ts();
CHECK_GT(ts_, 0.0) << "[LatController] Invalid control update interval.";
if (ts_ <= 0.0) {
AERROR << "[MPCController] Invalid control update interval.";
return false;
}
cf_ = control_conf->lat_controller_conf().cf();
cr_ = control_conf->lat_controller_conf().cr();
preview_window_ = control_conf->lat_controller_conf().preview_window();
......
......@@ -81,7 +81,10 @@ bool MPCController::LoadControlConf(const ControlConf *control_conf) {
vehicle_param_ = VehicleConfigHelper::Instance()->GetConfig().vehicle_param();
ts_ = control_conf->mpc_controller_conf().ts();
CHECK_GT(ts_, 0.0) << "[MPCController] Invalid control update interval.";
if (ts_ <= 0.0) {
AERROR << "[MPCController] Invalid control update interval.";
return false;
}
cf_ = control_conf->mpc_controller_conf().cf();
cr_ = control_conf->mpc_controller_conf().cr();
wheelbase_ = vehicle_param_.wheel_base();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册