From 742ede30d4ad9232c5a003cabda7bca8af5854a5 Mon Sep 17 00:00:00 2001 From: yelvlab Date: Sun, 1 Jun 2025 10:14:23 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E8=BE=93=E5=87=BA=E5=BC=80?= =?UTF-8?q?=E5=85=B3=EF=BC=8CM1=E6=8C=87=E4=BB=A4=E5=BC=80=E5=90=AF?= =?UTF-8?q?=E8=BE=93=E5=87=BA=EF=BC=8CM2=E6=8C=87=E4=BB=A4=E5=85=B3?= =?UTF-8?q?=E9=97=AD=E8=BE=93=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- inc/board_config.h | 2 +- src/main.c | 2 +- src/rs485.c | 5 +---- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/inc/board_config.h b/inc/board_config.h index a9ba484..0a5b9be 100644 --- a/inc/board_config.h +++ b/inc/board_config.h @@ -9,7 +9,7 @@ // #define DEBUG_VERBOES -#define RS485_MAX13487 +// #define RS485_MAX13487 // #define DEBUG_VOFA_TOOL diff --git a/src/main.c b/src/main.c index 267c1a6..6c6b0d8 100644 --- a/src/main.c +++ b/src/main.c @@ -42,7 +42,7 @@ int main(void) { while (1) { - delay_ms(1000); + delay_ms(10); fwdgt_counter_reload(); if (g_statusSwitch) {eddy_current_value_report();} diff --git a/src/rs485.c b/src/rs485.c index 98c0708..dd0a815 100644 --- a/src/rs485.c +++ b/src/rs485.c @@ -89,15 +89,12 @@ void process_command(uint8_t *cmd, size_t length) { // printf("%d", length); sprintf(combined_str, "%c%c", cmd[3], cmd[4]); if (strcmp(combined_str, "M1") == 0) { - printf("ok"); g_statusSwitch = true; - // eddy_current_value_report(); } else if (strcmp(combined_str, "M2") == 0) { g_statusSwitch = false; - // tempture_value_report(); } else if (strcmp(combined_str, "M3") == 0) { printf("%c%c%c%c%c%c", 0xB5, 0xF1, 0x02, 0x6F, 0x6B, 0xCC); - // fwdgt_reset_mcu(); + fwdgt_reset_mcu(); } else { printf("%c%c%c%c%c%c%c", 0xB5, 0xF0, 0x03, 0x65, 0x72, 0x72, 0x3C); return;