| | |
| | | #include "uart.h" |
| | | #include "upper_com_data_pro.h" |
| | | #include "mb.h" |
| | | #include "upper_com_iap_pro.h" |
| | | |
| | | UC_RECV_PARA_T __attribute__ ((aligned (4))) uc_recv_para_g = {.uc_recv_flag = RESET}; |
| | | |
| | |
| | | } |
| | | |
| | | |
| | | //?ÃÜÂëÑéÖ¤ |
| | | //ÃÜÂëÑéÖ¤ |
| | | if(uc_recv_data_union_p->uc_protocol_head_s.uc_admin==UC_SUPPER_ADMIN) |
| | | { |
| | | //²»ÐèÒªÑéÖ¤ÃÜÂë |
| | |
| | | }else if(uc_recv_data_union_p->uc_protocol_head_s.uc_admin==UC_MANAGE_USER) |
| | | { |
| | | // |
| | | |
| | | }else if(uc_recv_data_union_p->uc_protocol_head_s.uc_admin==UC_ADVANCED_USER) |
| | | { |
| | | |
| | |
| | | uint8_t *data_p; |
| | | if (uc_login_state_g == UC_OK && local_random_code_g == uc_recv_data_union_p->uc_protocol_head_s.random_number) |
| | | { |
| | | uc_respond_data_p->uc_protocol_head_s.data_table_id = uc_recv_data_union_p->uc_protocol_head_s.data_table_id; |
| | | data_category_ID= BSWAP_16(uc_recv_data_union_p->uc_protocol_head_s.data_table_id); |
| | | data_p = uc_recv_data_union_p->uc_recv_buf + UC_PROTOCOL_HEAD_LENGTH +sizeof (uc_recv_data_union_p->uc_protocol_head_s.data_table_id); |
| | | switch(data_category_ID)//?ÐèÒªÍêÉÆ |
| | |
| | | // case SYSTEM_FUNCTION_CTRL_WORD_ID : COM_system_function_ctrl_word_inf_handle(WriteOrRead, com_frame_receive_inf_in.data_category_ID,(DataPtr +2)) ;break; |
| | | // case SYSTEM_ALARM_CTRL_WORD_ID : COM_system_alarm_ctrl_word_inf_handle(WriteOrRead, com_frame_receive_inf_in.data_category_ID,(DataPtr +2)) ;break; |
| | | // case SYSTEM_ALARM_REPORT_CTRL_WORD_ID : COM_system_alarm_report_ctrl_word_inf_handle(WriteOrRead, com_frame_receive_inf_in.data_category_ID,(DataPtr +2)) ;break; |
| | | // case DEVICE_REAL_TIME_ID : COM_time_set_handle(WriteOrRead, com_frame_receive_inf_in.data_category_ID,(DataPtr +2)) ;break; |
| | | case DEVICE_REAL_TIME_ID : COM_time_set_handle(uc_recv_data_union_p->uc_protocol_head_s.cmd_code,data_category_ID,data_p,uc_respond_data_p) ;break; |
| | | // case DEBUG_STATE_SET_ID : COM_debug_state_handle(WriteOrRead, com_frame_receive_inf_in.data_category_ID,(DataPtr +2)) ;break; |
| | | // case DEBUG_PARA_SET_ID : COM_debug_para_set_handle(WriteOrRead, com_frame_receive_inf_in.data_category_ID,(DataPtr +2)) ;break; |
| | | // case ORIGINAL_WAVEFORM_DATA_READ_ID : COM_original_para_set_handle(WriteOrRead, com_frame_receive_inf_in.data_category_ID,(DataPtr +2)) ;break; |
| | |
| | | // { |
| | | // uc_rw_result_g = Upper_ComputerLogProcess(Upper_ComputerPermissionsGet(uc_rec_para_p->uc_recv_buf_union.uc_recv_buf[2]), |
| | | // &uc_rec_para_p->uc_recv_buf_union.uc_recv_buf[UC_PROTOCOL_HEAD_LENGTH], |
| | | // &uc_temp_result_buffer[0][UC_PROTOCOL_HEAD_LENGTH + UC_DATA_TABLE_BYTES_LENGTH + UC_LOG_NUM_AND_FLAG_LENGTH]); |
| | | // &uc_temp_result_buffer[0][UC_PROTOCOL_HEAD_LENGTH + UC_PROTOCOL_TABLE_ID_LENGTH + UC_LOG_NUM_AND_FLAG_LENGTH]); |
| | | // __SYS_DELAY_SEC_TIME_SET_(UC_active_time,UC_ACTIVE_TIME);//ÉèÖü¤»îʱ¼ä//ÖØÖü¤»îʱ¼ä |
| | | // } |
| | | break; |
| | | case UC_CMD_IAP://? |
| | | // uc_rw_result_g = Upper_ComputerIapProcess(uc_table_id, &uc_rec_para_p->uc_recv_buf_union.uc_recv_buf[UC_PROTOCOL_HEAD_LENGTH + UC_DATA_TABLE_BYTES_LENGTH]); |
| | | // __SYS_DELAY_SEC_TIME_SET_(UC_active_time,UC_ACTIVE_TIME);//ÉèÖü¤»îʱ¼ä//ÖØÖü¤»îʱ¼ä |
| | | case UC_CMD_IAP://Éý¼¶ |
| | | Upper_ComputerIapHandler(&uc_recv_para_g.uc_recv_buf_union,&uc_respond_data_g); |
| | | Upper_ComputerRespond(&uc_respond_data_g); |
| | | __SYS_DELAY_SEC_TIME_SET_(UC_active_time,UC_ACTIVE_TIME);//ÉèÖü¤»îʱ¼ä//ÖØÖü¤»îʱ¼ä |
| | | break; |
| | | default: |
| | | break; |