|
@@ -181,8 +181,8 @@ void PickupProcessTask::Main()
|
|
|
msg.reset(m_command_response_msg.base_info(),m_command_response_msg.SerializeAsString());
|
|
|
Message_communicator::get_instance_pointer()->send_msg(&msg);
|
|
|
LOG_IF(ERROR, code != SUCCESS) << "查询失败,取车终端:"<<m_terminor_id
|
|
|
- <<", 车牌号:"<<m_car_info.license();
|
|
|
- LOG(WARNING)<<"查询成功:"<<m_terminor_id
|
|
|
+ <<", 车牌号:"<<m_car_info.license()<<code.get_error_description();
|
|
|
+ LOG_IF(WARNING,code==SUCCESS)<<"查询成功,终端号:"<<m_terminor_id
|
|
|
<<", 车牌号:"<<m_car_info.license();
|
|
|
m_current_step_type = (code != SUCCESS) ? message::eBackComplete : message::eDispatch_step;
|
|
|
}
|
|
@@ -279,7 +279,7 @@ void PickupProcessTask::Main()
|
|
|
{
|
|
|
//异常结束
|
|
|
usleep(1000*1000);
|
|
|
- LOG(ERROR)<<"异常停车,回退结束"<<"车牌号:"<<m_car_info.license()
|
|
|
+ LOG(ERROR)<<"异常取车,回退结束"<<"车牌号:"<<m_car_info.license()
|
|
|
<<",xxxxxxxxxxxxxx 终端:"<<m_terminor_id<<" xxxxxxxxxxxxxx";
|
|
|
}
|
|
|
if(m_current_step_type== message::eComplete)
|
|
@@ -310,28 +310,27 @@ Error_manager PickupProcessTask::dispatch_step()
|
|
|
if(code!=SUCCESS)
|
|
|
return code;
|
|
|
|
|
|
- message::Dispatch_request_msg request;
|
|
|
message::Base_info base_info;
|
|
|
base_info.set_msg_type(message::eDispatch_request_msg);
|
|
|
base_info.set_sender(message::eMain);
|
|
|
base_info.set_receiver(message::eDispatch);
|
|
|
base_info.set_timeout_ms(1000*300); //测量超时300s
|
|
|
- request.mutable_base_info()->CopyFrom(base_info);
|
|
|
+ m_dispatch_request_msg.mutable_base_info()->CopyFrom(base_info);
|
|
|
|
|
|
message::Parkspace_info space_info=m_search_response_msg.car_position();
|
|
|
- request.set_dispatch_motion_direction(message::E_PICKUP_CAR);
|
|
|
- request.set_parkspace_id(space_info.parkspace_id());
|
|
|
- request.set_terminal_id(m_terminor_id);
|
|
|
+ m_dispatch_request_msg.set_dispatch_motion_direction(message::E_PICKUP_CAR);
|
|
|
+ m_dispatch_request_msg.set_parkspace_id(space_info.parkspace_id());
|
|
|
+ m_dispatch_request_msg.set_terminal_id(m_terminor_id);
|
|
|
+
|
|
|
+ m_dispatch_request_msg.set_command_key(create_key());
|
|
|
|
|
|
- request.set_command_key(create_key());
|
|
|
|
|
|
|
|
|
- message::Dispatch_response_msg response;
|
|
|
- code=Dispatch_excutor::get_instance_pointer()->dispatch_request(request,response,m_cancel_condition);
|
|
|
+ code=Dispatch_excutor::get_instance_pointer()->dispatch_request(m_dispatch_request_msg,m_dispatch_response_msg,m_cancel_condition);
|
|
|
if(code!=SUCCESS)
|
|
|
return code;
|
|
|
|
|
|
- if(response.error_manager().error_code()==0) {
|
|
|
+ if(m_dispatch_response_msg.error_manager().error_code()==0) {
|
|
|
return SUCCESS;
|
|
|
}
|
|
|
else
|