commit c3674785ae4c15c13362db3f623ee17f320e472f
| author | 斟酌 鵬兄 <tgckpg@gmail.com> |
| date | 2026-10-04T13:05:28Z |
| subject | It's PN532 not PNC532 |
commit c3674785ae4c15c13362db3f623ee17f320e472f
Author: 斟酌 鵬兄 <tgckpg@gmail.com>
Date: 2026-10-04T13:05:28Z
It's PN532 not PNC532
---
esp32/main/CMakeLists.txt | 4 ++--
esp32/main/{pnc532.c => pn532.c} | 2 ++
esp32/main/{pnc532_test.c => pn532_test.c} | 0
3 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/esp32/main/CMakeLists.txt b/esp32/main/CMakeLists.txt
index e228784..5ba8686 100644
--- a/esp32/main/CMakeLists.txt
+++ b/esp32/main/CMakeLists.txt
@@ -9,14 +9,14 @@ if(PIN_TEST)
)
elseif(PNC532_TEST)
idf_component_register(
- SRCS "pnc532_test.c"
+ SRCS "pn532_test.c"
INCLUDE_DIRS "."
PRIV_REQUIRES nvs_flash driver esp_timer
esp_hw_support esp_driver_uart
)
else()
idf_component_register(
- SRCS "main.c" "pnc532.c"
+ SRCS "main.c" "pn532.c"
INCLUDE_DIRS "."
PRIV_REQUIRES bt nvs_flash driver esp_timer
esp_hw_support esp_driver_uart
diff --git a/esp32/main/pnc532.c b/esp32/main/pn532.c
similarity index 99%
rename from esp32/main/pnc532.c
rename to esp32/main/pn532.c
index d643767..9ab4009 100644
--- a/esp32/main/pnc532.c
+++ b/esp32/main/pn532.c
@@ -236,8 +236,10 @@ static bool initialize_reader(void)
/* Discard stale input before starting this attempt. */
ESP_ERROR_CHECK(uart_flush_input(PN532_UART));
+#ifdef FRAME_DEBUG
ESP_LOGI(TAG, "TX wakeup");
ESP_LOG_BUFFER_HEX_LEVEL(TAG, wakeup, sizeof(wakeup), ESP_LOG_INFO);
+#endif
if (!write_bytes(wakeup, sizeof(wakeup))) {
ESP_LOGE(TAG, "wakeup write failed");
return false;
diff --git a/esp32/main/pnc532_test.c b/esp32/main/pn532_test.c
similarity index 100%
rename from esp32/main/pnc532_test.c
rename to esp32/main/pn532_test.c