add:增加文档和上位机
This commit is contained in:
@@ -134,7 +134,7 @@ void host_computer_on_get_status(uint8_t id, cJSON *json_pack)
|
||||
udp_send_to_server(str, strlen(str));
|
||||
free(str);
|
||||
cJSON_Delete(root);
|
||||
printf("get_status 回复已发送 \r\n");
|
||||
printf("[ 上位机 ] get_status 回复已发送 \r\n");
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -146,7 +146,7 @@ void host_computer_on_get_status(uint8_t id, cJSON *json_pack)
|
||||
void host_computer_on_reboot(uint8_t id, cJSON *json)
|
||||
{
|
||||
(void) id;
|
||||
printf("host_computer_on_reboot\r\n");
|
||||
printf("[ 上位机 ] host_computer_on_reboot\r\n");
|
||||
__ASM volatile("cpsid i");
|
||||
HAL_NVIC_SystemReset();
|
||||
}
|
||||
@@ -285,11 +285,11 @@ void host_computer_report_data(uint8_t stake_index, uint8_t gun_id)
|
||||
{
|
||||
udp_send_to_server(str, strlen(str));
|
||||
free(str);
|
||||
printf("南向:主动上报桩 %d 枪 %d 主动上报数据成功 \r\n", stake_index, gun_id);
|
||||
printf("[ 上位机 ] 南向:主动上报桩 %d 枪 %d 主动上报数据成功 \r\n", stake_index, gun_id);
|
||||
}
|
||||
else
|
||||
{
|
||||
printf("Failed to print JSON for report_data\r\n");
|
||||
printf("[ 上位机 ] Failed to print JSON for report_data\r\n");
|
||||
}
|
||||
|
||||
cJSON_Delete(root);
|
||||
|
||||
Reference in New Issue
Block a user