From c9f4412f897ba6767eced8a7bd8753845e40858a Mon Sep 17 00:00:00 2001 From: xin Date: Mon, 30 Jun 2025 16:02:51 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E4=BA=86test?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- myis11/src/is11/IS11Comon.cpp | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/myis11/src/is11/IS11Comon.cpp b/myis11/src/is11/IS11Comon.cpp index d3d484e..033ce56 100644 --- a/myis11/src/is11/IS11Comon.cpp +++ b/myis11/src/is11/IS11Comon.cpp @@ -1,15 +1,20 @@ #include "IS11Comon.h" #ifdef _WIN32 #include -#else +void delay(int ms){ + Sleep(ms); +} +#else +#include // For usleep + +void delay(int ms){ + usleep(ms * 1000); // Convert milliseconds to microseconds +} #include #include #endif -void delay(int ms){ - Sleep(ms); -} u_char BufferForRead[10000];