如何让游戏手柄蓝牙设备始终保持开启状态?

如何让游戏手柄蓝牙设备始终保持开启状态?

我有这个蓝牙游戏手柄(它与 VR 一起使用,作为远程​​摄像机拍摄,作为操纵杆等):

如果我不触摸它,该设备会在 5 分钟后关闭。好吧,我不希望它这样做,例如,我想让它保持开启状态一小时。我尝试bluetoothctl connect 13:57:90:05:0E:31每 30 秒使用一次,但它不起作用:它会在 5 分钟后关闭。我没有尝试这样做,disconnect因为connect它可能会延迟执行该操作,并且可能无法连接,我必须手动关闭并打开它。我需要它始终开启并随时可用

有什么方法可以向该设备发送“某些东西”以使它在我需要的时间内保持开启状态?

我的系统:Debian 10 x64,TP-Link UB400 USB 蓝牙适配器,设备信息是:

[bluetooth]# info 13:57:90:05:0E:31 
Device 13:57:90:05:0E:31 (public)
    Name: Gamepad.
    Alias: Gamepad.
    Class: 0x00000540
    Icon: input-keyboard
    Paired: yes
    Trusted: yes
    Blocked: no
    Connected: yes
    LegacyPairing: no
    UUID: Human Interface Device... (00001124-0000-1000-8000-00805f9b34fb)
    UUID: PnP Information           (00001200-0000-1000-8000-00805f9b34fb)
    Modalias: usb:v05ACp3232d0001

使用 Python evdev,该设备的功能包括:

gamepad.capabilities()
{0: [0, 1, 3, 4], 1: [304, 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319], 3: [(0, AbsInfo(value=0, min=-127, max=127, fuzz=0, flat=15, resolution=0)), (1, AbsInfo(value=0, min=-127, max=127, fuzz=0, flat=15, resolution=0)), (2, AbsInfo(value=0, min=-127, max=127, fuzz=0, flat=15, resolution=0)), (5, AbsInfo(value=0, min=-127, max=127, fuzz=0, flat=15, resolution=0)), (16, AbsInfo(value=0, min=-1, max=1, fuzz=0, flat=0, resolution=0)), (17, AbsInfo(value=0, min=-1, max=1, fuzz=0, flat=0, resolution=0))], 4: [4]}

gamepad.capabilities(verbose=True)
{('EV_SYN', 0): [('SYN_REPORT', 0), ('SYN_CONFIG', 1), ('SYN_DROPPED', 3), ('?', 4)], ('EV_KEY', 1): [(['BTN_A', 'BTN_GAMEPAD', 'BTN_SOUTH'], 304), (['BTN_B', 'BTN_EAST'], 305), ('BTN_C', 306), (['BTN_NORTH', 'BTN_X'], 307), (['BTN_WEST', 'BTN_Y'], 308), ('BTN_Z', 309), ('BTN_TL', 310), ('BTN_TR', 311), ('BTN_TL2', 312), ('BTN_TR2', 313), ('BTN_SELECT', 314), ('BTN_START', 315), ('BTN_MODE', 316), ('BTN_THUMBL', 317), ('BTN_THUMBR', 318), ('?', 319)], ('EV_ABS', 3): [(('ABS_X', 0), AbsInfo(value=0, min=-127, max=127, fuzz=0, flat=15, resolution=0)), (('ABS_Y', 1), AbsInfo(value=0, min=-127, max=127, fuzz=0, flat=15, resolution=0)), (('ABS_Z', 2), AbsInfo(value=0, min=-127, max=127, fuzz=0, flat=15, resolution=0)), (('ABS_RZ', 5), AbsInfo(value=0, min=-127, max=127, fuzz=0, flat=15, resolution=0)), (('ABS_HAT0X', 16), AbsInfo(value=0, min=-1, max=1, fuzz=0, flat=0, resolution=0)), (('ABS_HAT0Y', 17), AbsInfo(value=0, min=-1, max=1, fuzz=0, flat=0, resolution=0))], ('EV_MSC', 4): [('MSC_SCAN', 4)]}

gamepad.leds()
[] # it has no leds to receive on/off data

相关内容