From 1efab70b36e26f7d3da30027ec30a825eba01e44 Mon Sep 17 00:00:00 2001 From: modehua Date: Sat, 18 Nov 2023 01:06:42 -0800 Subject: [PATCH] =?UTF-8?q?=E5=BE=AE=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- zynq_7010_code/MultiFrameCapture.cpp | 1 - zynq_7010_code/Scanner.cpp | 18 ++++++------------ zynq_7010_code/USBProtocol.h | 1 - zynq_7010_code/UsbScanner.cpp | 1 - zynq_7010_code/main.cpp | 2 +- zynq_7010_code/scanservices_utils.h | 2 +- 6 files changed, 8 insertions(+), 17 deletions(-) delete mode 100644 zynq_7010_code/USBProtocol.h diff --git a/zynq_7010_code/MultiFrameCapture.cpp b/zynq_7010_code/MultiFrameCapture.cpp index 287849b..556cfe8 100644 --- a/zynq_7010_code/MultiFrameCapture.cpp +++ b/zynq_7010_code/MultiFrameCapture.cpp @@ -7,7 +7,6 @@ #include "CameraParam.h" #include "correct_ultis.h" -#include "USBProtocol.h" #include "utilsfunc.h" #include "CImageMerge.h" #include "Jpegcompress.h" diff --git a/zynq_7010_code/Scanner.cpp b/zynq_7010_code/Scanner.cpp index 527cc5f..5f06176 100644 --- a/zynq_7010_code/Scanner.cpp +++ b/zynq_7010_code/Scanner.cpp @@ -3,7 +3,6 @@ #include "MemoryInfo.h" #include "SysInforTool.h" -#include "USBProtocol.h" #include "StopWatch.h" #define BTN_START 0 @@ -31,7 +30,7 @@ Scanner::Scanner(ScannerGlue glue) capturer->SetParent(this); capturer->set_image_callback(&have_img_callback); - this_thread::sleep_for(std::chrono::milliseconds(50)); + //固件版本 int version=7010; @@ -66,22 +65,19 @@ Scanner::Scanner(ScannerGlue glue) } }; sensor = std::make_shared(sysEvent); - this_thread::sleep_for(std::chrono::milliseconds(50)); + + m_keyboard.reset(new huagao::Keyboard(btnevent)); m_keyboard->init(); - this_thread::sleep_for(std::chrono::milliseconds(50)); + motorZouzhi.enablePower(true); motorZouzhi.setSpeed(4000); motorCuozhi.setSpeed(3000); motorCuozhi.setDirection(false); - std::this_thread::sleep_for(std::chrono::milliseconds(50)); - FsmState::setScanner(this); threadRunMessageLoop = std::thread(&Scanner::runMessageLoop, this); Motor::enablePower(true); - this_thread::sleep_for(std::chrono::milliseconds(200)); - } Scanner::~Scanner() @@ -222,10 +218,8 @@ void Scanner::runScan() isPaperInit = true; } - this_thread::sleep_for(std::chrono::milliseconds(200)); - - sensor->resetPaperPin(); - + this_thread::sleep_for(std::chrono::milliseconds(200)); + sensor->resetPaperPin(); capturer->resetimageremain(); capturer->setScanFlag(true); diff --git a/zynq_7010_code/USBProtocol.h b/zynq_7010_code/USBProtocol.h deleted file mode 100644 index f23e7af..0000000 --- a/zynq_7010_code/USBProtocol.h +++ /dev/null @@ -1 +0,0 @@ -#pragma once diff --git a/zynq_7010_code/UsbScanner.cpp b/zynq_7010_code/UsbScanner.cpp index f5e1d38..11aae0d 100644 --- a/zynq_7010_code/UsbScanner.cpp +++ b/zynq_7010_code/UsbScanner.cpp @@ -1,7 +1,6 @@ #include "UsbScanner.h" #include #include "JsonConfig.h" -#include "USBProtocol.h" #include "logs_out.h" #include "JsonConfig.h" #include "StopWatch.h" diff --git a/zynq_7010_code/main.cpp b/zynq_7010_code/main.cpp index 08ef9a4..93bfdd4 100644 --- a/zynq_7010_code/main.cpp +++ b/zynq_7010_code/main.cpp @@ -23,7 +23,7 @@ #include "utilsfunc.h" #include "correct_ultis.h" #include -#include "USBProtocol.h" + #include "MotorConfig.h" #include diff --git a/zynq_7010_code/scanservices_utils.h b/zynq_7010_code/scanservices_utils.h index 883639b..2f8e444 100644 --- a/zynq_7010_code/scanservices_utils.h +++ b/zynq_7010_code/scanservices_utils.h @@ -63,7 +63,7 @@ typedef struct typedef void (*image_callback)(int element); static std::mapmapFradme_SP={ {1,{0x08ED1003,0x1ACC1002,CON(G34D,231027)}},//40 ppm - {2,{0x06DB1003,0x14A01002,CON(G3ZY,231102)}},//50 ppm + {2,{0x06DB1003,0x14A01002,CON(G3ZY,231118)}},//50 ppm {3,{0x05591003,0x100E1002,CON(G36D,231027)}},//60 ppm {4,{0x04421003,0x0CD11002,CON(G37D,231027)}},//70 ppm {5,{0x036c1003,0x0A421002,CON(G38D,231027)}},//80 ppm