是否可以在ios越狱软件上使用外部键盘模拟触摸事件?
在ios越狱和越狱涉及的所有元素上,是否有可能在特定屏幕坐标下,按下金融外部键盘(通过摄像头连接套件或蓝牙连接usb)上的特定键来模拟触摸事件 我会用脚按下应用程序中的按钮(振幅),我想用键盘作为脚踏开关 仅供私人使用。没有Appstore或Cydia。是否可以在ios越狱软件上使用外部键盘模拟触摸事件?,ios,events,keyboard,touch,external,Ios,Events,Keyboard,Touch,External,在ios越狱和越狱涉及的所有元素上,是否有可能在特定屏幕坐标下,按下金融外部键盘(通过摄像头连接套件或蓝牙连接usb)上的特定键来模拟触摸事件 我会用脚按下应用程序中的按钮(振幅),我想用键盘作为脚踏开关 仅供私人使用。没有Appstore或Cydia。 谢谢。您可以在计算机上编写脚本,并使用键盘和鼠标控制基于模拟触摸库的iOS设备 iOS13 SimulateTouch是一个开源库,允许您在系统级别模拟触摸事件。您可以使用任何编程语言编写脚本来模拟iOS设备上的触摸事件,无论是远程还是本地。请
谢谢。您可以在计算机上编写脚本,并使用键盘和鼠标控制基于模拟触摸库的iOS设备 iOS13 SimulateTouch是一个开源库,允许您在系统级别模拟触摸事件。您可以使用任何编程语言编写脚本来模拟iOS设备上的触摸事件,无论是远程还是本地。请在查看源代码
IOS13模拟触摸屏 iOS 11.0-13.6系统级触摸模拟iOS 13模拟触摸 需要越狱装置 此库使您能够用一行代码在iOS 11.0-13.6上模拟触摸事件!所有源代码将在稍后发布
Python版本
import socket
import time
# event types
TOUCH_UP = 0
TOUCH_DOWN = 1
TOUCH_MOVE = 2
SET_SCREEN_SIZE = 9
# you can copy and paste this method to your code
def formatSocketData(type, index, x, y):
return '{}{:02d}{:05d}{:05d}'.format(type, index, int(x*10), int(y*10))
s = socket.socket()
s.connect(("127.0.0.1", 6000)) # connect to the tweak. Replace "127.0.0.1" with the ip address of your device
s.send(("1"+formatSocketData(SET_SCREEN_SIZE, 0, 2048, 2732)).encode()) # tell the tweak that the screen size is 2048x2732 (your screen size might differ). This should be send to the tweak every time you kill the SpringBoard (just send once)
time.sleep(1) # sleep for 1 sec to get setting size process finished
s.send(("1"+formatSocketData(TOUCH_DOWN, 7, 300, 400)).encode()) # tell the tweak to touch 300x400 on the screen
# IMPORTANT: NOTE the "1" at the head of the data. This indicates the event count and CANNOT BE IGNORED.
s.close()
实际上,触摸仅由一行执行:
s.send(("1"+formatSocketData(TOUCH_DOWN, 7, 300, 400)).encode())
整洁而简单
执行触摸移动
s.send(("1"+formatSocketData(TOUCH_MOVE, 7, 800, 400)).encode()) # tell the tweak to move our finger "7" to (800, 400)
润色
s.send(("1"+formatSocketData(TOUCH_UP, 7, 800, 400)).encode()) # tell the tweak to touch up our finger "7" at (800, 400)
结合它们
s.send(("1"+formatSocketData(TOUCH_DOWN, 7, 300, 400)).encode())
time.sleep(1)
s.send(("1"+formatSocketData(TOUCH_MOVE, 7, 800, 400)).encode())
time.sleep(1)
s.send(("1"+formatSocketData(TOUCH_UP, 7, 800, 400)).encode())
首先手指触摸(300400),然后移动到(800400),然后“离开”屏幕。所有触摸事件均在无延迟的情况下执行
事件计数
(1位):指定单个事件的计数。如果同时要发送多个事件,只需增加事件计数并将事件附加到数据中即可
在单个事件中
类型
(1位):指定单个事件的类型
支持的事件类型:
触摸索引
(2位):苹果支持多点触摸,因此在发布触摸事件时必须指定手指索引。食指的范围为1-20(保留0,不要将0用作食指)
x坐标
(5位):要触摸的位置的x坐标。前4位为整数部分,后4位为小数部分。例如,如果您想在屏幕上触摸(123.42432.1),您应该为此填写“01234”
y坐标
(5位):要触摸的位置的y坐标。前4位为整数部分,后4位为小数部分。例如,如果您想在屏幕上触摸(123.42432.1),您应该为此填写“24321”
此外
因此,如果您想用手指“3”在屏幕上触碰(123.41032.1),只需使用插座连接到调整并发送“11030123410321”
数字0:“1”表示只有一个事件要执行
数字1:“1”表示事件类型:触碰向下(标志为1)
数字2-3:“03”表示此事件由手指“3”执行
数字4-8:“01234”表示x坐标123.4
数字9-13:“10321”表示y坐标1032.1
触摸坐标不取决于设备的方向。请参见下图以获取更多信息。无论您如何放置设备,屏幕上的点击点都不会改变。
您可以在计算机上编写脚本,并使用键盘和鼠标根据模拟触摸库控制iOS设备 iOS13 SimulateTouch是一个开源库,允许您在系统级别模拟触摸事件。您可以使用任何编程语言编写脚本来模拟iOS设备上的触摸事件,无论是远程还是本地。请在查看源代码
IOS13模拟触摸屏 iOS 11.0-13.6系统级触摸模拟iOS 13模拟触摸 需要越狱装置 此库使您能够用一行代码在iOS 11.0-13.6上模拟触摸事件!所有源代码将在稍后发布
Python版本
import socket
import time
# event types
TOUCH_UP = 0
TOUCH_DOWN = 1
TOUCH_MOVE = 2
SET_SCREEN_SIZE = 9
# you can copy and paste this method to your code
def formatSocketData(type, index, x, y):
return '{}{:02d}{:05d}{:05d}'.format(type, index, int(x*10), int(y*10))
s = socket.socket()
s.connect(("127.0.0.1", 6000)) # connect to the tweak. Replace "127.0.0.1" with the ip address of your device
s.send(("1"+formatSocketData(SET_SCREEN_SIZE, 0, 2048, 2732)).encode()) # tell the tweak that the screen size is 2048x2732 (your screen size might differ). This should be send to the tweak every time you kill the SpringBoard (just send once)
time.sleep(1) # sleep for 1 sec to get setting size process finished
s.send(("1"+formatSocketData(TOUCH_DOWN, 7, 300, 400)).encode()) # tell the tweak to touch 300x400 on the screen
# IMPORTANT: NOTE the "1" at the head of the data. This indicates the event count and CANNOT BE IGNORED.
s.close()
其实