From 21e02a99474bffd4a6c6cdf4b4df9b841a226e18 Mon Sep 17 00:00:00 2001 From: BlueMatthew Date: Fri, 5 Jan 2024 23:04:27 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BE=93=E5=87=BA=E6=97=A5=E5=BF=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/cpp/GPIOControl.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/app/src/main/cpp/GPIOControl.cpp b/app/src/main/cpp/GPIOControl.cpp index 01c3a988..3a33a173 100644 --- a/app/src/main/cpp/GPIOControl.cpp +++ b/app/src/main/cpp/GPIOControl.cpp @@ -15,6 +15,9 @@ #include "GPIOControl.h" +#ifdef _DEBUG +#include +#endif #define IOT_PARAM_WRITE 0xAE #define IOT_PARAM_READ 0xAF @@ -54,7 +57,9 @@ int GpioControl::getInt(int cmd) IOT_PARAM param; param.cmd = cmd; ioctl(fd, IOT_PARAM_READ, ¶m); - // LOGE("get_int22 cmd=%d,value=%d,result=%d\r\n",param.cmd, param.value, param.result); +#ifdef _DEBUG + ALOGI("getInt cmd=%d,value=%d,result=%d\r\n",param.cmd, param.value, param.result); +#endif close(fd); return param.value; }