Razer 蓝牙鼠标在 Linux 上断开连接

Razer 蓝牙鼠标在 Linux 上断开连接

我连接了鼠标bluetoothctl

sudo systemctl enable bluetooth.service
sudo systemctl start bluetooth.service
bluetoothctl
> power on
> default-agent
> scan on
> pair C0:56:C2:25:49:AE
> trust C0:56:C2:25:49:AE
> connect C0:56:C2:25:49:AE
> quit

鼠标已连接并正常工作,但是如果 2-3 秒不移动鼠标,它就会断开连接。

我已经创建了/etc/bluetooth/input.conf

[General]
IdleTimeout=0
UserspaceHID=true

还向 udev 添加了一些规则/etc/udev/rules.d/91-local.rules

ACTION=="add", SUBSYSTEM=="bluetooth", ATTR{product}=="Razer Atheris", ATTR{power/control}="on"

bluetoothctl可以看到它“创建”了一个新设备,然后2秒不动(它不打印任何东西),然后我移动鼠标,它开始打印[DEL](我必须一直移动鼠标),然后它开始打印[NEW](句柄十六进制数也是新的),然后打印[CHG] Device C0:56:C2:25:49:AE Paired: yes(我仍然必须移动鼠标),然后光标移动。

[CHG] Controller 48:D2:24:59:55:CD Alias: microbook
[CHG] Controller 48:D2:24:59:55:CD Class: 0x0000010c
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001801-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001800-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001200-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 0000110c-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 0000110e-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001801-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001800-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001200-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 0000110c-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 0000110e-0000-1000-8000-00805f9b34fb
[CHG] Device C0:56:C2:25:49:AE Connected: yes
[NEW] Primary Service (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000a
    00001801-0000-1000-8000-00805f9b34fb
    Generic Attribute Profile
[NEW] Primary Service (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b
    0000180a-0000-1000-8000-00805f9b34fb
    Device Information
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b/char000c
    00002a29-0000-1000-8000-00805f9b34fb
    Manufacturer Name String
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b/char000e
    00002a26-0000-1000-8000-00805f9b34fb
    Firmware Revision String
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b/char0010
    00002a50-0000-1000-8000-00805f9b34fb
    PnP ID
[NEW] Primary Service (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a
    52401523-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char003b
    52401524-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char003d
    52401525-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[NEW] Descriptor (Handle 0x000c)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char003d/desc003f
    00002902-0000-1000-8000-00805f9b34fb
    Client Characteristic Configuration
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char0040
    52401526-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[NEW] Descriptor (Handle 0x000c)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char0040/desc0042
    00002902-0000-1000-8000-00805f9b34fb
    Client Characteristic Configuration
[CHG] Device C0:56:C2:25:49:AE ServicesResolved: yes
[CHG] Device C0:56:C2:25:49:AE Paired: yes
[CHG] Controller 48:D2:24:59:55:CD Class: 0x00000000
[CHG] Controller 48:D2:24:59:55:CD Powered: no
[CHG] Controller 48:D2:24:59:55:CD Discovering: no
[CHG] Device C0:56:C2:25:49:AE ServicesResolved: no
[CHG] Device C0:56:C2:25:49:AE Connected: no
[DEL] Primary Service (Handle 0xa9e0)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000a
    00001801-0000-1000-8000-00805f9b34fb
    Generic Attribute Profile
[DEL] Characteristic (Handle 0xed00)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b/char000c
    00002a29-0000-1000-8000-00805f9b34fb
    Manufacturer Name String
[DEL] Characteristic (Handle 0xed00)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b/char000e
    00002a26-0000-1000-8000-00805f9b34fb
    Firmware Revision String
[DEL] Characteristic (Handle 0xed00)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b/char0010
    00002a50-0000-1000-8000-00805f9b34fb
    PnP ID
[DEL] Primary Service (Handle 0x9c60)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b
    0000180a-0000-1000-8000-00805f9b34fb
    Device Information
[DEL] Characteristic (Handle 0xed00)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char003b
    52401524-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[DEL] Descriptor (Handle 0x0006)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char003d/desc003f
    00002902-0000-1000-8000-00805f9b34fb
    Client Characteristic Configuration
[DEL] Characteristic (Handle 0xed00)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char003d
    52401525-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[DEL] Descriptor (Handle 0x0006)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char0040/desc0042
    00002902-0000-1000-8000-00805f9b34fb
    Client Characteristic Configuration
[DEL] Characteristic (Handle 0xed00)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char0040
    52401526-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[DEL] Primary Service (Handle 0xc4f0)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a
    52401523-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[DEL] Device C0:56:C2:25:49:AE Razer Atheris
[DEL] Device 30:21:45:5A:2A:E2 MO8726
[DEL] Controller 48:D2:24:59:55:CD microbook [default]
[NEW] Controller 48:D2:24:59:55:CD microbook [default]
[NEW] Device C0:56:C2:25:49:AE Razer Atheris
[NEW] Device 30:21:45:5A:2A:E2 MO8726
[CHG] Controller 48:D2:24:59:55:CD Powered: yes
[CHG] Controller 48:D2:24:59:55:CD Alias: microbook
[CHG] Controller 48:D2:24:59:55:CD Class: 0x0000010c
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001801-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001800-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001200-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 0000110c-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 0000110e-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001801-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001800-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 00001200-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 0000110c-0000-1000-8000-00805f9b34fb
[CHG] Controller 48:D2:24:59:55:CD UUIDs: 0000110e-0000-1000-8000-00805f9b34fb
[CHG] Device C0:56:C2:25:49:AE Connected: yes
[NEW] Primary Service (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000a
    00001801-0000-1000-8000-00805f9b34fb
    Generic Attribute Profile
[NEW] Primary Service (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b
    0000180a-0000-1000-8000-00805f9b34fb
    Device Information
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b/char000c
    00002a29-0000-1000-8000-00805f9b34fb
    Manufacturer Name String
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b/char000e
    00002a26-0000-1000-8000-00805f9b34fb
    Firmware Revision String
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service000b/char0010
    00002a50-0000-1000-8000-00805f9b34fb
    PnP ID
[NEW] Primary Service (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a
    52401523-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char003b
    52401524-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char003d
    52401525-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[NEW] Descriptor (Handle 0x000c)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char003d/desc003f
    00002902-0000-1000-8000-00805f9b34fb
    Client Characteristic Configuration
[NEW] Characteristic (Handle 0xe7ce)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char0040
    52401526-f97c-7f90-0e7f-6c6f4e36db1c
    Vendor specific
[NEW] Descriptor (Handle 0x000c)
    /org/bluez/hci0/dev_C0_56_C2_25_49_AE/service003a/char0040/desc0042
    00002902-0000-1000-8000-00805f9b34fb
    Client Characteristic Configuration
[CHG] Device C0:56:C2:25:49:AE ServicesResolved: yes
[CHG] Device C0:56:C2:25:49:AE Paired: yes

编辑:我发现,在 journalctl 中它会打印某种错误:

Jun 19 10:23:14 microbook audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:14 microbook kernel: audit: type=1130 audit(1592554994.617:528): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:14 microbook kernel: usb 6-2: new full-speed USB device number 74 using ohci-pci
Jun 19 10:23:14 microbook bluetoothd[479]: Endpoint unregistered: sender=:1.459 path=/MediaEndpoint/A2DPSink/sbc
Jun 19 10:23:14 microbook bluetoothd[479]: Endpoint unregistered: sender=:1.459 path=/MediaEndpoint/A2DPSource/sbc
Jun 19 10:23:14 microbook kernel: usb 6-2: New USB device found, idVendor=0cf3, idProduct=3004, bcdDevice= 0.01
Jun 19 10:23:14 microbook kernel: usb 6-2: New USB device strings: Mfr=0, Product=0, SerialNumber=0
Jun 19 10:23:14 microbook kernel: usb 6-2: USB disconnect, device number 74
Jun 19 10:23:15 microbook kernel: usb 6-2: new full-speed USB device number 75 using ohci-pci
Jun 19 10:23:19 microbook systemd[1]: systemd-rfkill.service: Succeeded.
-- Subject: Unit succeeded
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The unit systemd-rfkill.service has successfully entered the 'dead' state.
Jun 19 10:23:19 microbook audit[1]: SERVICE_STOP pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:19 microbook kernel: audit: type=1131 audit(1592554999.624:529): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:20 microbook kernel: usb 6-2: New USB device found, idVendor=0cf3, idProduct=3004, bcdDevice= 0.02
Jun 19 10:23:20 microbook kernel: usb 6-2: New USB device strings: Mfr=0, Product=0, SerialNumber=0
Jun 19 10:23:20 microbook systemd[1]: Starting Load/Save RF Kill Switch Status...
-- Subject: A start job for unit systemd-rfkill.service has begun execution
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- A start job for unit systemd-rfkill.service has begun execution.
--
-- The job identifier is 11789.
Jun 19 10:23:20 microbook systemd[429]: Reached target Bluetooth.
-- Subject: A start job for unit UNIT has finished successfully
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- A start job for unit UNIT has finished successfully.
--
-- The job identifier is 363.
Jun 19 10:23:20 microbook systemd[1]: Reached target Bluetooth.
-- Subject: A start job for unit bluetooth.target has finished successfully
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- A start job for unit bluetooth.target has finished successfully.
--
-- The job identifier is 11797.
Jun 19 10:23:20 microbook kernel: audit: type=1130 audit(1592555000.797:530): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:20 microbook audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:20 microbook systemd[1]: Started Load/Save RF Kill Switch Status.
-- Subject: A start job for unit systemd-rfkill.service has finished successfully
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- A start job for unit systemd-rfkill.service has finished successfully.
--
-- The job identifier is 11789.
Jun 19 10:23:20 microbook bluetoothd[479]: Endpoint registered: sender=:1.459 path=/MediaEndpoint/A2DPSink/sbc
Jun 19 10:23:20 microbook bluetoothd[479]: Endpoint registered: sender=:1.459 path=/MediaEndpoint/A2DPSource/sbc
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook bluetoothd[479]: bt_uhid_send: Invalid argument (22)
Jun 19 10:23:21 microbook kernel: input: Razer Atheris Mouse as /devices/virtual/misc/uhid/0005:1532:0061.0057/input/input426
Jun 19 10:23:21 microbook kernel: input: Razer Atheris Consumer Control as /devices/virtual/misc/uhid/0005:1532:0061.0057/input/input427
Jun 19 10:23:21 microbook kernel: input: Razer Atheris System Control as /devices/virtual/misc/uhid/0005:1532:0061.0057/input/input428
Jun 19 10:23:21 microbook kernel: input: Razer Atheris as /devices/virtual/misc/uhid/0005:1532:0061.0057/input/input429
Jun 19 10:23:21 microbook kernel: input: Razer Atheris Keyboard as /devices/virtual/misc/uhid/0005:1532:0061.0057/input/input430
Jun 19 10:23:21 microbook kernel: hid-generic 0005:1532:0061.0057: input,hidraw2: BLUETOOTH HID v0.01 Mouse [Razer Atheris] on 48:d2:24:59:55:cd
Jun 19 10:23:21 microbook systemd-logind[416]: Watching system buttons on /dev/input/event15 (Razer Atheris Consumer Control)
Jun 19 10:23:21 microbook systemd-logind[416]: Watching system buttons on /dev/input/event18 (Razer Atheris Keyboard)
Jun 19 10:23:21 microbook systemd-logind[416]: Watching system buttons on /dev/input/event16 (Razer Atheris System Control)
Jun 19 10:23:25 microbook systemd[1]: systemd-rfkill.service: Succeeded.
-- Subject: Unit succeeded
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The unit systemd-rfkill.service has successfully entered the 'dead' state.
Jun 19 10:23:25 microbook audit[1]: SERVICE_STOP pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:25 microbook kernel: audit: type=1131 audit(1592555005.804:531): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:45 microbook kernel: usb 6-2: USB disconnect, device number 75
Jun 19 10:23:45 microbook systemd[1]: Starting Load/Save RF Kill Switch Status...
-- Subject: A start job for unit systemd-rfkill.service has begun execution
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- A start job for unit systemd-rfkill.service has begun execution.
--
-- The job identifier is 11887.
Jun 19 10:23:45 microbook systemd[429]: Stopped target Bluetooth.
-- Subject: A stop job for unit UNIT has finished
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- A stop job for unit UNIT has finished.
--
-- The job identifier is 365 and the job result is done.
Jun 19 10:23:45 microbook systemd[1]: Stopped target Bluetooth.
-- Subject: A stop job for unit bluetooth.target has finished
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- A stop job for unit bluetooth.target has finished.
--
-- The job identifier is 11895 and the job result is done.
Jun 19 10:23:45 microbook systemd[1]: Started Load/Save RF Kill Switch Status.
-- Subject: A start job for unit systemd-rfkill.service has finished successfully
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- A start job for unit systemd-rfkill.service has finished successfully.
--
-- The job identifier is 11887.
Jun 19 10:23:45 microbook audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:45 microbook kernel: audit: type=1130 audit(1592555025.984:532): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-rfkill comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Jun 19 10:23:46 microbook bluetoothd[479]: Endpoint unregistered: sender=:1.459 path=/MediaEndpoint/A2DPSink/sbc
Jun 19 10:23:46 microbook bluetoothd[479]: Endpoint unregistered: sender=:1.459 path=/MediaEndpoint/A2DPSource/sbc
Jun 19 10:23:46 microbook kernel: usb 6-2: new full-speed USB device number 76 using ohci-pci
Jun 19 10:23:46 microbook kernel: usb 6-2: New USB device found, idVendor=0cf3, idProduct=3004, bcdDevice= 0.01
Jun 19 10:23:46 microbook kernel: usb 6-2: New USB device strings: Mfr=0, Product=0, SerialNumber=0
Jun 19 10:23:46 microbook kernel: usb 6-2: USB disconnect, device number 76
Jun 19 10:23:46 microbook kernel: usb 6-2: new full-speed USB device number 77 using ohci-pci

答案1

好的,通过结合更多来源,我找到了答案:

首先找到、配对并连接鼠标:

sudo systemctl enable bluetooth.service
sudo systemctl start bluetooth.service
bluetoothctl
> power on
> default-agent
> scan on
> pair C0:56:C2:25:49:AE
> trust C0:56:C2:25:49:AE
> connect C0:56:C2:25:49:AE
> quit

然后在 中找到idVendorand (在 less 中使用 find )idProductsudo lsusb -v | less/Procuct_name

然后在以下位置创建一个文件/etc/udev/rules.d/50-usb_power_save.rules

ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="<Your_Vendor_id>", ATTR{idProduct}=="<Your_Product_id>", ATTR{power/control}="on"
ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="<Your_Vendor_id>", ATTR{idProduct}=="<Your_Product_id>", TEST=="power/autosuspend" ATTR{power/autosuspend}="0"
ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="<Your_Vendor_id>", ATTR{idProduct}=="<Your_Product_id>", TEST=="power/autosuspend_delay_ms" ATTR{power/autosuspend_delay_ms}="0"

然后运行:

sudo udevadm control --reload
sudo systemctl daemon-reload

那么一切都会永远顺利:)

相关内容