From 91b75ad2b9a80c14382ebdc7e2566ef56b1fe999 Mon Sep 17 00:00:00 2001 From: neodarz Date: Tue, 28 Mar 2017 11:04:19 +0200 Subject: Fix bug who don't send data to uinput --- touch.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'touch.py') diff --git a/touch.py b/touch.py index 71e88ca..4a5a358 100644 --- a/touch.py +++ b/touch.py @@ -16,8 +16,8 @@ def read_and_emulate_mouse(deviceFound): device = uinput.Device([ uinput.BTN_LEFT, uinput.BTN_RIGHT, - uinput.ABS_X, - uinput.ABS_Y, + uinput.ABS_X + (0, 1024, 0, 0), #or 800 + uinput.ABS_Y + (0, 600, 0, 0), #ok 480 ]) clicked = False @@ -33,7 +33,7 @@ def read_and_emulate_mouse(deviceFound): except: print('failed to read from deviceFound' + str(deviceFound)) return - + time.sleep(0.01) if btnLeft: -- cgit v1.2.1