From 9b8f665d00098365ab964d31859381be9ec43a8f Mon Sep 17 00:00:00 2001 From: andy <1414772332@qq.com> Date: Wed, 5 Mar 2025 22:31:40 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E7=82=B9=E5=87=BB=E5=81=8F?= =?UTF-8?q?=E7=A7=BB=20=E6=B7=BB=E5=8A=A0=E6=B5=8B=E8=AF=95=E5=87=BD?= =?UTF-8?q?=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- touch2.py | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/touch2.py b/touch2.py index e08b8e0..f893b89 100644 --- a/touch2.py +++ b/touch2.py @@ -121,7 +121,7 @@ class ser(object): time.sleep(0.05) self.togo(0,0) def enter(self): - self.togo(70+20,27) + self.togo(70+20,30) self.touch() def back(self): self.togo(70,132) @@ -138,15 +138,17 @@ class ser(object): time.sleep(2) def password(self,p:str): index=0 + touch_times=0 p_len=len(p) try_times=0 while indexdict: return {"index":0} +def test(): + identify_text() + get_scr(_ocr_pos[0],_ocr_pos[1],_ocr_pos[2],_ocr_pos[3],f"test") + find_input_count() + + + if __name__ == "__main__": + if len(sys.argv)>=2 and sys.argv[1]=='test': + test() + sys.exit(0) s=ser() s.open("com8") password=data_get().get("index",0)