|
@@ -57,7 +57,7 @@ Error_manager Dispatch_plc::dispatch_plc_uninit()
|
|
|
//调度plc 执行请求
|
|
|
Error_manager Dispatch_plc::execute_for_dispatch_request_msg(message::Dispatch_request_msg& dispatch_request_msg)
|
|
|
{
|
|
|
-
|
|
|
+
|
|
|
if ( m_dispatch_plc_status == Dispatch_plc::Dispatch_plc_status::DISPATCH_PLC_READY )
|
|
|
{
|
|
|
std::unique_lock<std::mutex> t_lock(m_lock);
|
|
@@ -87,7 +87,7 @@ Error_manager Dispatch_plc::execute_for_dispatch_request_msg(message::Dispatch_r
|
|
|
else
|
|
|
{
|
|
|
return Error_manager(Error_code::DISPATCH_PLC_REQUEST_ERROR, Error_level::MINOR_ERROR,
|
|
|
- " dispatch_request_msg.dispatch_motion_direction() PARAMRTER ERROR ");
|
|
|
+ " dispatch_request_msg.dispatch_motion_direction() PARAMRTER ERROR ");
|
|
|
}
|
|
|
|
|
|
m_dispatch_process_type = Common_data::Dispatch_process_type::DISPATCH_PROCESS_TYPE_UNKNOW;
|
|
@@ -95,8 +95,8 @@ Error_manager Dispatch_plc::execute_for_dispatch_request_msg(message::Dispatch_r
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- return Error_manager(Error_code::DISPATCH_PLC_STATUS_ERROR, Error_level::MINOR_ERROR,
|
|
|
- " m_dispatch_plc_status error ");
|
|
|
+ return Error_manager(Error_code::DISPATCH_PLC_STATUS_ERROR, Error_level::MINOR_ERROR,
|
|
|
+ " m_dispatch_plc_status error ");
|
|
|
}
|
|
|
|
|
|
return Error_code::SUCCESS;
|
|
@@ -130,7 +130,7 @@ void Dispatch_plc::execute_thread_fun()
|
|
|
|
|
|
std::cout << " huli test :::: " << " m_plc_id = " << m_plc_id << std::endl;
|
|
|
std::cout << " huli test :::: " << " m_dispatch_plc_status = " << m_dispatch_plc_status << std::endl;
|
|
|
-
|
|
|
+
|
|
|
switch ((Dispatch_plc_status) m_dispatch_plc_status)
|
|
|
{
|
|
|
case DISPATCH_PLC_READY:
|
|
@@ -400,7 +400,7 @@ Error_manager Dispatch_plc::update_dispatch_plc_communication()
|
|
|
*/
|
|
|
|
|
|
|
|
|
- //请求消息, 调度->plc
|
|
|
+ //请求消息, 调度->plc
|
|
|
Dispatch_communication::Dispatch_request_from_manager_to_plc_for_data * tp_dispatch_request_from_manager_to_plc_for_data =
|
|
|
& Dispatch_communication::get_instance_references().m_dispatch_request_from_manager_to_plc_for_data;
|
|
|
Dispatch_communication::Dispatch_request_from_manager_to_plc_for_key * m_dispatch_request_from_manager_to_plc_for_key =
|
|
@@ -429,7 +429,7 @@ Error_manager Dispatch_plc::update_dispatch_plc_communication()
|
|
|
memset(tp_dispatch_request_from_manager_to_plc_for_data->m_request_car_license, 0, 20);
|
|
|
int t_size2 = m_request_key.size()<=20 ? m_request_key.size() : 20 ;
|
|
|
memcpy(tp_dispatch_request_from_manager_to_plc_for_data->m_request_car_license, m_request_car_license.c_str(), t_size2);
|
|
|
- tp_dispatch_request_from_manager_to_plc_for_data->m_request_car_type = m_request_car_type;
|
|
|
+ tp_dispatch_request_from_manager_to_plc_for_data->m_request_car_type = m_request_car_type;
|
|
|
tp_dispatch_request_from_manager_to_plc_for_data->m_request_uniformed_car_x = m_request_uniformed_car_x;
|
|
|
tp_dispatch_request_from_manager_to_plc_for_data->m_request_uniformed_car_y = m_request_uniformed_car_y;
|
|
|
|