From ae9d0463dac176941debe47e8f3fda22a7f43a59 Mon Sep 17 00:00:00 2001 From: Luke Date: Tue, 7 Jul 2020 16:14:18 +1200 Subject: [PATCH] Improvements to service init --- Cargo.lock | 2 +- Makefile | 2 + README.md | 31 ++++++++-- data/rog-core.rules | 1 + data/rog-core.service | 1 + debian/changelog | 6 ++ debian/control | 1 + debian/rog-core.postinst | 7 ++- debian/rog-core.postrm | 5 +- reverse_eng/g512lu/details | 4 ++ reverse_eng/g512lu/usbhid.log | 28 +++++++++ reverse_eng/gu502/laptop_info | 6 ++ reverse_eng/gu502/rog-core.log | 54 ++++++++++++++++++ reverse_eng/gu502/usbhid.log | 47 +++++++++++++++ .../airplane-mode-on-off-2.4.3.pcapng | Bin .../fan-button-2.4.3.pcapng | Bin .../screen-bright-2.4.3from.pcapng | Bin .../screen-off-on-button-2.4.3.pcapng | Bin .../screen-out-select-2.4.3-2.4.2.pcapng | Bin .../trackpad-off-on.pcapng | Bin ...e-yellow-green-lblue-blue-mag-black.pcapng | Bin .../gx502-rgb-dark-select-static-red.pcapng | Bin .../gx502-rgb-open-crate.pcapng | Bin .../gx502-rgb-select-breathing.pcapng | Bin .../gx502-rgb-select-rainbow.pcapng | Bin .../gx502-rgb-breathe-to-pulse.pcapng | Bin .../gx502-rgb-breathe.pcapng | Bin .../gx502-rgb-bright-1.pcapng | Bin .../gx502-rgb-bright-2.pcapng | Bin .../gx502-rgb-bright-3.pcapng | Bin .../gx502-rgb-colour-cycle-to-rainbow.pcapng | Bin .../gx502-rgb-pulse-to-colour-cycle.pcapng | Bin .../gx502-rgb-rainbow-to-static.pcapng | Bin .../{gx501 => gx502}/per_key_raw_bytes | 0 .../{gx501 => gx502}/per_key_raw_bytes.ods | Bin .../{gx501 => gx502}/rog-star-colour.pcapng | Bin .../{gx501 => gx502}/rog-star-random.pcapng | Bin .../rog_music_not_playing.pcapng | Bin .../{gx501 => gx502}/rog_starry_night.pcapng | Bin .../rog_starry_night_brighter.pcapng | Bin rog-core/Cargo.toml | 2 +- rog-core/src/main.rs | 2 +- rog-core/src/rogcore.rs | 4 +- 43 files changed, 190 insertions(+), 13 deletions(-) create mode 100644 data/rog-core.rules create mode 100644 reverse_eng/g512lu/details create mode 100644 reverse_eng/g512lu/usbhid.log create mode 100644 reverse_eng/gu502/laptop_info create mode 100644 reverse_eng/gu502/rog-core.log create mode 100644 reverse_eng/gu502/usbhid.log rename reverse_eng/{gx501 => gx502}/gx502-other-kb-functions/airplane-mode-on-off-2.4.3.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-other-kb-functions/fan-button-2.4.3.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-other-kb-functions/screen-bright-2.4.3from.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-other-kb-functions/screen-off-on-button-2.4.3.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-other-kb-functions/screen-out-select-2.4.3-2.4.2.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-other-kb-functions/trackpad-off-on.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-selecting/gx502-rgb-black-red-orange-yellow-green-lblue-blue-mag-black.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-selecting/gx502-rgb-dark-select-static-red.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-selecting/gx502-rgb-open-crate.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-selecting/gx502-rgb-select-breathing.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-selecting/gx502-rgb-select-rainbow.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-wireshark/gx502-rgb-breathe-to-pulse.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-wireshark/gx502-rgb-breathe.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-wireshark/gx502-rgb-bright-1.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-wireshark/gx502-rgb-bright-2.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-wireshark/gx502-rgb-bright-3.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-wireshark/gx502-rgb-colour-cycle-to-rainbow.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-wireshark/gx502-rgb-pulse-to-colour-cycle.pcapng (100%) rename reverse_eng/{gx501 => gx502}/gx502-rgb-wireshark/gx502-rgb-rainbow-to-static.pcapng (100%) rename reverse_eng/{gx501 => gx502}/per_key_raw_bytes (100%) rename reverse_eng/{gx501 => gx502}/per_key_raw_bytes.ods (100%) rename reverse_eng/{gx501 => gx502}/rog-star-colour.pcapng (100%) rename reverse_eng/{gx501 => gx502}/rog-star-random.pcapng (100%) rename reverse_eng/{gx501 => gx502}/rog_music_not_playing.pcapng (100%) rename reverse_eng/{gx501 => gx502}/rog_starry_night.pcapng (100%) rename reverse_eng/{gx501 => gx502}/rog_starry_night_brighter.pcapng (100%) diff --git a/Cargo.lock b/Cargo.lock index f2f638c6..00ecb6fe 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -710,7 +710,7 @@ dependencies = [ [[package]] name = "rog-daemon" -version = "0.14.3" +version = "0.14.4" dependencies = [ "dbus", "dbus-tokio", diff --git a/Makefile b/Makefile index bf98b26e..b948e953 100644 --- a/Makefile +++ b/Makefile @@ -34,11 +34,13 @@ distclean: install: all install -D -m 0755 "target/release/$(BIN)" "$(DESTDIR)$(bindir)/$(BIN)" + install -D -m 0644 "data/$(BIN).rules" "$(DESTDIR)$(sysconfdir)/udev/rules.d/99-$(BIN).rules" install -D -m 0644 "data/$(BIN).conf" "$(DESTDIR)$(sysconfdir)/dbus-1/system.d/$(BIN).conf" install -D -m 0644 "data/$(BIN).service" "$(DESTDIR)$(libdir)/systemd/system/$(BIN).service" uninstall: rm -f "$(DESTDIR)$(bindir)/$(BIN)" + rm -f "$(DESTDIR)$(sysconfdir)/udev/rules.d/99-$(BIN).conf" rm -f "$(DESTDIR)$(sysconfdir)/dbus-1/system.d/$(BIN).conf" rm -f "$(DESTDIR)$(libdir)/systemd/system/$(BIN).service" diff --git a/README.md b/README.md index 1024185c..c19fe475 100644 --- a/README.md +++ b/README.md @@ -91,6 +91,30 @@ gnome-shell extension, or at least limiting use of the power-management parts as (one or the other will overwrite pstates). I will create a shell extension at some point similar to system76, but using the rog-core parts. It is safe to leave `system76-power.service` enabled and use for switching between graphics modes. +## Arch Linux, and possibly others + +This method of enabling may become default. + +Currently there seems to be an issue where the device is not fully initialised and +when rog-core attempts to grab the keyboard it will fail, and you may be left without +input. A way around this is to disable the systemd service (rog-core) if enabled +and create a udev rule in `/etc/udev/rules.d/99-rogcore.rules` with the following +content: + +``` +ACTION=="bind", SUBSYSTEM=="usb", ATTRS{idVendor}=="0b05", ATTRS{idProduct}=="1866", TAG+="systemd", ENV{SYSTEMD_WANTS}="rog-core.service" +``` + +Double-check your `idProduct` with `lsusb |grep 0b05`, this will show a line such +as: + +``` +Bus 001 Device 006: ID 0b05:1866 ASUSTek Computer, Inc. N-KEY Device +``` + +where `1866` here is the `idProduct`. Modify the udev rule to suit. If there is +more than one line (such as with an AniMe laptop), prefer using the `N-Key` device. + ### Ubuntu PPA Alternatively, instead of building manually you can use the PPA. @@ -101,12 +125,7 @@ sudo apt-get update sudo apt-get install rog-core ``` -enable and start the service: - -``` -sudo systemctl start rog-core.service -sudo systemctl enable rog-core.service -``` +the rog-core service will run when the device is initialised. ### Gentoo ebuild diff --git a/data/rog-core.rules b/data/rog-core.rules new file mode 100644 index 00000000..3e5d6ac7 --- /dev/null +++ b/data/rog-core.rules @@ -0,0 +1 @@ +ACTION=="bind", SUBSYSTEM=="usb", ATTRS{idVendor}=="0b05", ATTRS{idProduct}=="18[0-9][0-9]", TAG+="systemd", ENV{SYSTEMD_WANTS}="rog-core.service" \ No newline at end of file diff --git a/data/rog-core.service b/data/rog-core.service index abbdb935..6b1d668b 100644 --- a/data/rog-core.service +++ b/data/rog-core.service @@ -1,5 +1,6 @@ [Unit] Description=ROG Core Daemon +After=dbus.service [Service] ExecStart=/usr/bin/rog-core -d diff --git a/debian/changelog b/debian/changelog index a09735bd..c9857e17 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +rog-core (0.14.4) focal; urgency=medium + + - Improve how service is initialised on boot + + -- Luke Jones Tue, 07 Jul 2020 16:14:48 +1200 + rog-core (0.14.3) focal; urgency=medium - Proper fix of laptop mode conversion bug diff --git a/debian/control b/debian/control index 7d084662..c6e993f8 100644 --- a/debian/control +++ b/debian/control @@ -18,6 +18,7 @@ Package: rog-core Architecture: amd64 Depends: dbus, + libc6, systemd, libusb-1.0-0, ${misc:Depends}, diff --git a/debian/rog-core.postinst b/debian/rog-core.postinst index 9f36e048..965e8a3e 100644 --- a/debian/rog-core.postinst +++ b/debian/rog-core.postinst @@ -4,7 +4,12 @@ set -e case "$1" in configure) - mv /etc/rogcore.conf /etc/rogcore.save || true + CONF='/etc/rogcore.conf' + if [ -f $CONF ]; then + mv $CONF $CONF.save + fi + #ROG=$(lsusb |grep 0b05 |cut -d ' ' -f 6 |cut -d ':' -f 2) + #sed -i -e "s|==/"1866/"|==/"${ROG}/"|g" /etc/udev/rules.d/99-rog-core.rules ;; *) diff --git a/debian/rog-core.postrm b/debian/rog-core.postrm index d0e919f6..2ce0d467 100644 --- a/debian/rog-core.postrm +++ b/debian/rog-core.postrm @@ -4,7 +4,10 @@ set -e case "$1" in remove) - rm -f /etc/rogcore.conf + CONF='/etc/rogcore.conf' + if [ -f $CONF ]; then + rm -rf $CONF + fi ;; *) diff --git a/reverse_eng/g512lu/details b/reverse_eng/g512lu/details new file mode 100644 index 00000000..a25c1eaa --- /dev/null +++ b/reverse_eng/g512lu/details @@ -0,0 +1,4 @@ +cat /sys/class/dmi/id/product_name:ROG Strix G512LU_G512LU +cat /sys/class/dmi/id/product_family: ROG Strix +cat /sys/class/dmi/id/board_name:G512LU + diff --git a/reverse_eng/g512lu/usbhid.log b/reverse_eng/g512lu/usbhid.log new file mode 100644 index 00000000..1da93615 --- /dev/null +++ b/reverse_eng/g512lu/usbhid.log @@ -0,0 +1,28 @@ +001:002:002:DESCRIPTOR 1593779817.131018 + 06 31 FF 09 76 A1 01 85 5A 19 00 2A FF 00 15 00 + 26 FF 00 75 08 95 05 81 00 19 00 2A FF 00 15 00 + 26 FF 00 75 08 95 3F B1 00 C0 05 0C 09 01 A1 01 + 85 02 19 00 2A 3C 02 15 00 26 3C 02 75 10 95 02 + 81 00 C0 06 31 FF 09 79 A1 01 85 5D 19 00 2A FF + 00 15 00 26 FF 00 75 08 95 1F 81 00 19 00 2A FF + 00 15 00 26 FF 00 75 08 95 3F 91 00 19 00 2A FF + 00 15 00 26 FF 00 75 08 95 3F B1 00 C0 06 31 FF + 09 80 A1 01 85 5E 19 00 2A FF 00 15 00 26 FF 00 + 75 08 95 05 81 00 19 00 2A FF 00 15 00 26 FF 00 + 75 08 95 3F B1 00 C0 + +001:002:001:DESCRIPTOR 1593779817.133253 + 05 01 09 06 A1 01 85 09 75 01 95 08 05 07 19 E0 + 29 E7 15 00 25 01 81 02 95 08 75 01 81 03 95 05 + 75 01 05 08 19 01 29 05 91 02 95 01 75 03 91 03 + 95 F0 75 01 05 07 19 00 29 EF 15 00 25 01 81 02 + C0 + +001:002:000:DESCRIPTOR 1593779817.134955 + 05 01 09 06 A1 01 85 01 75 01 95 08 05 07 19 E0 + 29 E7 15 00 25 01 81 02 95 01 75 08 81 03 95 05 + 75 01 05 08 19 01 29 05 91 02 95 01 75 03 91 03 + 95 06 75 08 15 00 26 FF 00 05 07 19 00 2A FF 00 + 81 00 95 C0 75 01 05 07 19 00 29 EF 15 00 25 01 + 81 02 C0 + diff --git a/reverse_eng/gu502/laptop_info b/reverse_eng/gu502/laptop_info new file mode 100644 index 00000000..73b9a800 --- /dev/null +++ b/reverse_eng/gu502/laptop_info @@ -0,0 +1,6 @@ +distro= Arch Linux +uname -r= 5.7.7-arch1-1 +product_name= Zephyrus G GU502DU_GA502DU +product_family= Zephyrus G +board_name= GU502DU +lsusb= Bus 003 Device 002: ID 0b05:1866 ASUSTek Computer, Inc. N-KEY Device \ No newline at end of file diff --git a/reverse_eng/gu502/rog-core.log b/reverse_eng/gu502/rog-core.log new file mode 100644 index 00000000..796eaec9 --- /dev/null +++ b/reverse_eng/gu502/rog-core.log @@ -0,0 +1,54 @@ +-- Logs begin at Thu 2020-07-02 17:11:02 CEST, end at Fri 2020-07-03 13:19:49 CEST. -- +júl 03 13:19:13 Zephyrus systemd[1]: Started ROG Core Daemon. +júl 03 13:19:13 Zephyrus rog-core[933380]: INFO: Product name: Zephyrus G GU502DU_GA502DU +júl 03 13:19:13 Zephyrus rog-core[933380]: INFO: Board name: GU502DU +júl 03 13:19:13 Zephyrus rog-core[933380]: thread 'main' panicked at 'Unsupported laptop, please request support at +júl 03 13:19:13 Zephyrus rog-core[933380]: https://github.com/flukejones/rog-core', rog-core/src/laptops.rs:89:9 +júl 03 13:19:13 Zephyrus rog-core[933380]: note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace +júl 03 13:19:13 Zephyrus systemd[1]: rog-core.service: Main process exited, code=dumped, status=6/ABRT +júl 03 13:19:13 Zephyrus systemd[1]: rog-core.service: Failed with result 'core-dump'. +júl 03 13:19:14 Zephyrus systemd[1]: rog-core.service: Scheduled restart job, restart counter is at 1. +júl 03 13:19:14 Zephyrus systemd[1]: Stopped ROG Core Daemon. +júl 03 13:19:14 Zephyrus systemd[1]: Started ROG Core Daemon. +júl 03 13:19:14 Zephyrus rog-core[933401]: INFO: Product name: Zephyrus G GU502DU_GA502DU +júl 03 13:19:14 Zephyrus rog-core[933401]: INFO: Board name: GU502DU +júl 03 13:19:14 Zephyrus rog-core[933401]: thread 'main' panicked at 'Unsupported laptop, please request support at +júl 03 13:19:14 Zephyrus rog-core[933401]: https://github.com/flukejones/rog-core', rog-core/src/laptops.rs:89:9 +júl 03 13:19:14 Zephyrus rog-core[933401]: note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace +júl 03 13:19:14 Zephyrus systemd[1]: rog-core.service: Main process exited, code=dumped, status=6/ABRT +júl 03 13:19:14 Zephyrus systemd[1]: rog-core.service: Failed with result 'core-dump'. +júl 03 13:19:14 Zephyrus systemd[1]: rog-core.service: Scheduled restart job, restart counter is at 2. +júl 03 13:19:14 Zephyrus systemd[1]: Stopped ROG Core Daemon. +júl 03 13:19:14 Zephyrus systemd[1]: Started ROG Core Daemon. +júl 03 13:19:14 Zephyrus rog-core[933420]: INFO: Product name: Zephyrus G GU502DU_GA502DU +júl 03 13:19:14 Zephyrus rog-core[933420]: INFO: Board name: GU502DU +júl 03 13:19:14 Zephyrus rog-core[933420]: thread 'main' panicked at 'Unsupported laptop, please request support at +júl 03 13:19:14 Zephyrus rog-core[933420]: https://github.com/flukejones/rog-core', rog-core/src/laptops.rs:89:9 +júl 03 13:19:14 Zephyrus rog-core[933420]: note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace +júl 03 13:19:15 Zephyrus systemd[1]: rog-core.service: Main process exited, code=dumped, status=6/ABRT +júl 03 13:19:15 Zephyrus systemd[1]: rog-core.service: Failed with result 'core-dump'. +júl 03 13:19:15 Zephyrus systemd[1]: rog-core.service: Scheduled restart job, restart counter is at 3. +júl 03 13:19:15 Zephyrus systemd[1]: Stopped ROG Core Daemon. +júl 03 13:19:15 Zephyrus systemd[1]: Started ROG Core Daemon. +júl 03 13:19:15 Zephyrus rog-core[933440]: INFO: Product name: Zephyrus G GU502DU_GA502DU +júl 03 13:19:15 Zephyrus rog-core[933440]: INFO: Board name: GU502DU +júl 03 13:19:15 Zephyrus rog-core[933440]: thread 'main' panicked at 'Unsupported laptop, please request support at +júl 03 13:19:15 Zephyrus rog-core[933440]: https://github.com/flukejones/rog-core', rog-core/src/laptops.rs:89:9 +júl 03 13:19:15 Zephyrus rog-core[933440]: note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace +júl 03 13:19:16 Zephyrus systemd[1]: rog-core.service: Main process exited, code=dumped, status=6/ABRT +júl 03 13:19:16 Zephyrus systemd[1]: rog-core.service: Failed with result 'core-dump'. +júl 03 13:19:16 Zephyrus systemd[1]: rog-core.service: Scheduled restart job, restart counter is at 4. +júl 03 13:19:16 Zephyrus systemd[1]: Stopped ROG Core Daemon. +júl 03 13:19:16 Zephyrus systemd[1]: Started ROG Core Daemon. +júl 03 13:19:16 Zephyrus rog-core[933457]: INFO: Product name: Zephyrus G GU502DU_GA502DU +júl 03 13:19:16 Zephyrus rog-core[933457]: INFO: Board name: GU502DU +júl 03 13:19:16 Zephyrus rog-core[933457]: thread 'main' panicked at 'Unsupported laptop, please request support at +júl 03 13:19:16 Zephyrus rog-core[933457]: https://github.com/flukejones/rog-core', rog-core/src/laptops.rs:89:9 +júl 03 13:19:16 Zephyrus rog-core[933457]: note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace +júl 03 13:19:17 Zephyrus systemd[1]: rog-core.service: Main process exited, code=dumped, status=6/ABRT +júl 03 13:19:17 Zephyrus systemd[1]: rog-core.service: Failed with result 'core-dump'. +júl 03 13:19:17 Zephyrus systemd[1]: rog-core.service: Scheduled restart job, restart counter is at 5. +júl 03 13:19:17 Zephyrus systemd[1]: Stopped ROG Core Daemon. +júl 03 13:19:17 Zephyrus systemd[1]: rog-core.service: Start request repeated too quickly. +júl 03 13:19:17 Zephyrus systemd[1]: rog-core.service: Failed with result 'core-dump'. +júl 03 13:19:17 Zephyrus systemd[1]: Failed to start ROG Core Daemon. diff --git a/reverse_eng/gu502/usbhid.log b/reverse_eng/gu502/usbhid.log new file mode 100644 index 00000000..3fe00324 --- /dev/null +++ b/reverse_eng/gu502/usbhid.log @@ -0,0 +1,47 @@ +003:003:001:DESCRIPTOR 1593775246.732819 + 05 01 09 02 A1 01 85 02 09 01 A1 00 05 09 19 01 + 29 10 15 00 25 01 95 10 75 01 81 02 05 01 16 01 + F8 26 FF 07 75 0C 95 02 09 30 09 31 81 06 15 81 + 25 7F 75 08 95 01 09 38 81 06 05 0C 0A 38 02 95 + 01 81 06 C0 C0 05 0C 09 01 A1 01 85 03 75 10 95 + 02 15 01 26 8C 02 19 01 2A 8C 02 81 00 C0 05 01 + 09 80 A1 01 85 04 75 02 95 01 15 01 25 03 09 82 + 09 81 09 83 81 60 75 06 81 03 C0 06 00 FF 09 01 + A1 01 85 10 75 08 95 06 15 00 26 FF 00 09 01 81 + 00 09 01 91 00 C0 06 00 FF 09 02 A1 01 85 11 75 + 08 95 13 15 00 26 FF 00 09 02 81 00 09 02 91 00 + C0 + +003:003:000:DESCRIPTOR 1593775246.736060 + 05 01 09 06 A1 01 05 07 19 E0 29 E7 15 00 25 01 + 75 01 95 08 81 02 81 03 95 05 05 08 19 01 29 05 + 91 02 95 01 75 03 91 01 95 06 75 08 15 00 26 A4 + 00 05 07 19 00 2A A4 00 81 00 C0 + +003:002:002:DESCRIPTOR 1593775246.738826 + 06 31 FF 09 76 A1 01 85 5A 19 00 2A FF 00 15 00 + 26 FF 00 75 08 95 05 81 00 19 00 2A FF 00 15 00 + 26 FF 00 75 08 95 3F B1 00 C0 05 0C 09 01 A1 01 + 85 02 19 00 2A 3C 02 15 00 26 3C 02 75 10 95 02 + 81 00 C0 06 31 FF 09 79 A1 01 85 5D 19 00 2A FF + 00 15 00 26 FF 00 75 08 95 1F 81 00 19 00 2A FF + 00 15 00 26 FF 00 75 08 95 3F 91 00 19 00 2A FF + 00 15 00 26 FF 00 75 08 95 3F B1 00 C0 06 31 FF + 09 80 A1 01 85 5E 19 00 2A FF 00 15 00 26 FF 00 + 75 08 95 05 81 00 19 00 2A FF 00 15 00 26 FF 00 + 75 08 95 3F B1 00 C0 + +003:002:001:DESCRIPTOR 1593775246.741819 + 05 01 09 06 A1 01 85 09 75 01 95 08 05 07 19 E0 + 29 E7 15 00 25 01 81 02 95 08 75 01 81 03 95 05 + 75 01 05 08 19 01 29 05 91 02 95 01 75 03 91 03 + 95 F0 75 01 05 07 19 00 29 EF 15 00 25 01 81 02 + C0 + +003:002:000:DESCRIPTOR 1593775246.744821 + 05 01 09 06 A1 01 85 01 75 01 95 08 05 07 19 E0 + 29 E7 15 00 25 01 81 02 95 01 75 08 81 03 95 05 + 75 01 05 08 19 01 29 05 91 02 95 01 75 03 91 03 + 95 1E 75 08 15 00 26 FF 00 05 07 19 00 2A FF 00 + 81 00 C0 + diff --git a/reverse_eng/gx501/gx502-other-kb-functions/airplane-mode-on-off-2.4.3.pcapng b/reverse_eng/gx502/gx502-other-kb-functions/airplane-mode-on-off-2.4.3.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-other-kb-functions/airplane-mode-on-off-2.4.3.pcapng rename to reverse_eng/gx502/gx502-other-kb-functions/airplane-mode-on-off-2.4.3.pcapng diff --git a/reverse_eng/gx501/gx502-other-kb-functions/fan-button-2.4.3.pcapng b/reverse_eng/gx502/gx502-other-kb-functions/fan-button-2.4.3.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-other-kb-functions/fan-button-2.4.3.pcapng rename to reverse_eng/gx502/gx502-other-kb-functions/fan-button-2.4.3.pcapng diff --git a/reverse_eng/gx501/gx502-other-kb-functions/screen-bright-2.4.3from.pcapng b/reverse_eng/gx502/gx502-other-kb-functions/screen-bright-2.4.3from.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-other-kb-functions/screen-bright-2.4.3from.pcapng rename to reverse_eng/gx502/gx502-other-kb-functions/screen-bright-2.4.3from.pcapng diff --git a/reverse_eng/gx501/gx502-other-kb-functions/screen-off-on-button-2.4.3.pcapng b/reverse_eng/gx502/gx502-other-kb-functions/screen-off-on-button-2.4.3.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-other-kb-functions/screen-off-on-button-2.4.3.pcapng rename to reverse_eng/gx502/gx502-other-kb-functions/screen-off-on-button-2.4.3.pcapng diff --git a/reverse_eng/gx501/gx502-other-kb-functions/screen-out-select-2.4.3-2.4.2.pcapng b/reverse_eng/gx502/gx502-other-kb-functions/screen-out-select-2.4.3-2.4.2.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-other-kb-functions/screen-out-select-2.4.3-2.4.2.pcapng rename to reverse_eng/gx502/gx502-other-kb-functions/screen-out-select-2.4.3-2.4.2.pcapng diff --git a/reverse_eng/gx501/gx502-other-kb-functions/trackpad-off-on.pcapng b/reverse_eng/gx502/gx502-other-kb-functions/trackpad-off-on.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-other-kb-functions/trackpad-off-on.pcapng rename to reverse_eng/gx502/gx502-other-kb-functions/trackpad-off-on.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-black-red-orange-yellow-green-lblue-blue-mag-black.pcapng b/reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-black-red-orange-yellow-green-lblue-blue-mag-black.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-black-red-orange-yellow-green-lblue-blue-mag-black.pcapng rename to reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-black-red-orange-yellow-green-lblue-blue-mag-black.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-dark-select-static-red.pcapng b/reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-dark-select-static-red.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-dark-select-static-red.pcapng rename to reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-dark-select-static-red.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-open-crate.pcapng b/reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-open-crate.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-open-crate.pcapng rename to reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-open-crate.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-select-breathing.pcapng b/reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-select-breathing.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-select-breathing.pcapng rename to reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-select-breathing.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-select-rainbow.pcapng b/reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-select-rainbow.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-selecting/gx502-rgb-select-rainbow.pcapng rename to reverse_eng/gx502/gx502-rgb-selecting/gx502-rgb-select-rainbow.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-breathe-to-pulse.pcapng b/reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-breathe-to-pulse.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-breathe-to-pulse.pcapng rename to reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-breathe-to-pulse.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-breathe.pcapng b/reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-breathe.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-breathe.pcapng rename to reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-breathe.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-bright-1.pcapng b/reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-bright-1.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-bright-1.pcapng rename to reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-bright-1.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-bright-2.pcapng b/reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-bright-2.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-bright-2.pcapng rename to reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-bright-2.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-bright-3.pcapng b/reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-bright-3.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-bright-3.pcapng rename to reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-bright-3.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-colour-cycle-to-rainbow.pcapng b/reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-colour-cycle-to-rainbow.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-colour-cycle-to-rainbow.pcapng rename to reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-colour-cycle-to-rainbow.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-pulse-to-colour-cycle.pcapng b/reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-pulse-to-colour-cycle.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-pulse-to-colour-cycle.pcapng rename to reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-pulse-to-colour-cycle.pcapng diff --git a/reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-rainbow-to-static.pcapng b/reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-rainbow-to-static.pcapng similarity index 100% rename from reverse_eng/gx501/gx502-rgb-wireshark/gx502-rgb-rainbow-to-static.pcapng rename to reverse_eng/gx502/gx502-rgb-wireshark/gx502-rgb-rainbow-to-static.pcapng diff --git a/reverse_eng/gx501/per_key_raw_bytes b/reverse_eng/gx502/per_key_raw_bytes similarity index 100% rename from reverse_eng/gx501/per_key_raw_bytes rename to reverse_eng/gx502/per_key_raw_bytes diff --git a/reverse_eng/gx501/per_key_raw_bytes.ods b/reverse_eng/gx502/per_key_raw_bytes.ods similarity index 100% rename from reverse_eng/gx501/per_key_raw_bytes.ods rename to reverse_eng/gx502/per_key_raw_bytes.ods diff --git a/reverse_eng/gx501/rog-star-colour.pcapng b/reverse_eng/gx502/rog-star-colour.pcapng similarity index 100% rename from reverse_eng/gx501/rog-star-colour.pcapng rename to reverse_eng/gx502/rog-star-colour.pcapng diff --git a/reverse_eng/gx501/rog-star-random.pcapng b/reverse_eng/gx502/rog-star-random.pcapng similarity index 100% rename from reverse_eng/gx501/rog-star-random.pcapng rename to reverse_eng/gx502/rog-star-random.pcapng diff --git a/reverse_eng/gx501/rog_music_not_playing.pcapng b/reverse_eng/gx502/rog_music_not_playing.pcapng similarity index 100% rename from reverse_eng/gx501/rog_music_not_playing.pcapng rename to reverse_eng/gx502/rog_music_not_playing.pcapng diff --git a/reverse_eng/gx501/rog_starry_night.pcapng b/reverse_eng/gx502/rog_starry_night.pcapng similarity index 100% rename from reverse_eng/gx501/rog_starry_night.pcapng rename to reverse_eng/gx502/rog_starry_night.pcapng diff --git a/reverse_eng/gx501/rog_starry_night_brighter.pcapng b/reverse_eng/gx502/rog_starry_night_brighter.pcapng similarity index 100% rename from reverse_eng/gx501/rog_starry_night_brighter.pcapng rename to reverse_eng/gx502/rog_starry_night_brighter.pcapng diff --git a/rog-core/Cargo.toml b/rog-core/Cargo.toml index b649059c..071368b5 100644 --- a/rog-core/Cargo.toml +++ b/rog-core/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rog-daemon" -version = "0.14.3" +version = "0.14.4" license = "MPL-2.0" readme = "README.md" authors = ["Luke "] diff --git a/rog-core/src/main.rs b/rog-core/src/main.rs index a5c02042..7be61317 100644 --- a/rog-core/src/main.rs +++ b/rog-core/src/main.rs @@ -9,7 +9,7 @@ use rog_client::{ }; use std::io::Write; -static VERSION: &str = "0.14.3"; +static VERSION: &str = "0.14.4"; #[derive(Options)] struct CLIStart { diff --git a/rog-core/src/rogcore.rs b/rog-core/src/rogcore.rs index 3163c689..c8382f4c 100644 --- a/rog-core/src/rogcore.rs +++ b/rog-core/src/rogcore.rs @@ -67,7 +67,7 @@ impl RogCore { if let Err(err) = dev_handle.set_auto_detach_kernel_driver(true) { warn!("Auto-detach kernel driver failed: {:?}", err); - let mut fail_count = 10; + let mut fail_count = 5; while fail_count > 0 { warn!("Trying device reset"); fail_count -= 1; @@ -84,7 +84,7 @@ impl RogCore { if let Err(err) = dev_handle.claim_interface(interface) { warn!("Could not claim keyboard device interface: {:?}", err); - let mut fail_count = 10; + let mut fail_count = 5; while fail_count > 0 { warn!("Sleeping"); fail_count -= 1;