NordLex / LogiOps

Adwaita baised UI configurator for PixelOne/LogiOps
GNU General Public License v3.0
23 stars 1 forks source link

logiops empty window #1

Open m-stefanski opened 4 months ago

m-stefanski commented 4 months ago

When I run compiled logiops binary, empty window is presented - with no error in console or GUI:

obraz

Build target is Ubuntu 24.04 x64

Mason setup output:

$ meson setup --reconfigure builddir
The Meson build system
Version: 1.3.2
Source dir: /home/marcin/repo/LogiOps
Build dir: /home/marcin/repo/LogiOps/builddir
Build type: native build
Project name: LogiOps
Project version: 0.1.0
C compiler for the host machine: cc (gcc 13.2.0 "cc (Ubuntu 13.2.0-23ubuntu4) 13.2.0")
C linker for the host machine: cc ld.bfd 2.42
Host machine cpu family: x86_64
Host machine cpu: x86_64
Configuring config.h using configuration
Compiler for C supports arguments -Wcast-align: YES (cached)
Compiler for C supports arguments -Wdeclaration-after-statement: YES (cached)
Compiler for C supports arguments -Werror=address: YES (cached)
Compiler for C supports arguments -Werror=array-bounds: YES (cached)
Compiler for C supports arguments -Werror=empty-body: YES (cached)
Compiler for C supports arguments -Werror=implicit: YES (cached)
Compiler for C supports arguments -Werror=implicit-function-declaration: YES (cached)
Compiler for C supports arguments -Werror=incompatible-pointer-types: YES (cached)
Compiler for C supports arguments -Werror=init-self: YES (cached)
Compiler for C supports arguments -Werror=int-conversion: YES (cached)
Compiler for C supports arguments -Werror=int-to-pointer-cast: YES (cached)
Compiler for C supports arguments -Werror=main: YES (cached)
Compiler for C supports arguments -Werror=misleading-indentation: YES (cached)
Compiler for C supports arguments -Werror=missing-braces: YES (cached)
Compiler for C supports arguments -Werror=missing-include-dirs: YES (cached)
Compiler for C supports arguments -Werror=nonnull: YES (cached)
Compiler for C supports arguments -Werror=overflow: YES (cached)
Compiler for C supports arguments -Werror=parenthesis: NO (cached)
Compiler for C supports arguments -Werror=pointer-arith: YES (cached)
Compiler for C supports arguments -Werror=pointer-to-int-cast: YES (cached)
Compiler for C supports arguments -Werror=redundant-decls: YES (cached)
Compiler for C supports arguments -Werror=return-type: YES (cached)
Compiler for C supports arguments -Werror=sequence-point: YES (cached)
Compiler for C supports arguments -Werror=shadow: YES (cached)
Compiler for C supports arguments -Werror=strict-prototypes: YES (cached)
Compiler for C supports arguments -Werror=trigraphs: YES (cached)
Compiler for C supports arguments -Werror=undef: YES (cached)
Compiler for C supports arguments -Werror=write-strings: YES (cached)
Compiler for C supports arguments -Wformat-nonliteral: YES (cached)
Compiler for C supports arguments -Wignored-qualifiers: YES (cached)
Compiler for C supports arguments -Wimplicit-function-declaration: YES (cached)
Compiler for C supports arguments -Wlogical-op: YES (cached)
Compiler for C supports arguments -Wmissing-declarations: YES (cached)
Compiler for C supports arguments -Wmissing-format-attribute: YES (cached)
Compiler for C supports arguments -Wmissing-include-dirs: YES (cached)
Compiler for C supports arguments -Wmissing-noreturn: YES (cached)
Compiler for C supports arguments -Wnested-externs: YES (cached)
Compiler for C supports arguments -Wno-cast-function-type: YES (cached)
Compiler for C supports arguments -Wno-dangling-pointer: YES (cached)
Compiler for C supports arguments -Wno-missing-field-initializers: YES (cached)
Compiler for C supports arguments -Wno-sign-compare: YES (cached)
Compiler for C supports arguments -Wno-unused-parameter: YES (cached)
Compiler for C supports arguments -Wold-style-definition: YES (cached)
Compiler for C supports arguments -Wpointer-arith: YES (cached)
Compiler for C supports arguments -Wredundant-decls: YES (cached)
Compiler for C supports arguments -Wstrict-prototypes: YES (cached)
Compiler for C supports arguments -Wswitch-default: YES (cached)
Compiler for C supports arguments -Wswitch-enum: YES (cached)
Compiler for C supports arguments -Wundef: YES (cached)
Compiler for C supports arguments -Wuninitialized: YES (cached)
Compiler for C supports arguments -Wunused: YES (cached)
Compiler for C supports arguments -fno-strict-aliasing: YES (cached)
Compiler for C supports arguments -Werror=format-security -Werror=format=2: YES (cached)
Compiler for C supports arguments -fstack-protector-strong: YES (cached)
Program msgfmt found: YES (/usr/bin/msgfmt)
Program desktop-file-validate found: YES (/usr/bin/desktop-file-validate)
Program appstream-util found: YES (/usr/bin/appstream-util)
Program glib-compile-schemas found: YES (/usr/bin/glib-compile-schemas)
Dependency gtk4 found: YES 4.14.2 (cached)
Dependency libadwaita-1 found: YES 1.5.0 (cached)
Found pkg-config: YES (/usr/bin/pkg-config) 1.8.1
Dependency gio-2.0 found: YES 2.80.0 (cached)
Program /usr/bin/glib-compile-resources found: YES (/usr/bin/glib-compile-resources)
Program msginit found: YES (/usr/bin/msginit)
Program msgmerge found: YES (/usr/bin/msgmerge)
Program xgettext found: YES (/usr/bin/xgettext)
Dependency gio-2.0 found: YES 2.80.0 (cached)
Program /usr/lib/x86_64-linux-gnu/glib-2.0/glib-compile-schemas found: YES (/usr/lib/x86_64-linux-gnu/glib-2.0/glib-compile-schemas)
Program gtk4-update-icon-cache found: YES (/usr/bin/gtk4-update-icon-cache)
Program update-desktop-database found: YES (/usr/bin/update-desktop-database)
Build targets in project: 8

Found ninja-1.11.1 at /usr/bin/ninja
Cleaning... 0 files.

Build output:

$ meson compile
INFO: autodetecting backend as ninja
INFO: calculating backend command to run: /usr/bin/ninja
[1/31] Generating src/l-resources_h with a custom command
xml-stripblanks preprocessing requested, but XMLLINT is not set, and xmllint is not in PATH
[6/31] Generating src/l-resources_c with a custom command
xml-stripblanks preprocessing requested, but XMLLINT is not set, and xmllint is not in PATH
[29/31] Compiling C object src/logiops.p/data_l-bus-manager.c.o
../src/data/l-bus-manager.c:156:1: warning: 'get_button_proxy' defined but not used [-Wunused-function]
  156 | get_button_proxy(LBusManager *self, GString *button) {
      | ^~~~~~~~~~~~~~~~
[31/31] Linking target src/logiops

Any help appreciated!

NordLex commented 4 months ago

The PixlOne/LogiOps daemon must be running. At the same time, he should see the connected devices. Otherwise there will be a blank window.

m-stefanski commented 4 months ago

I have started daemon and confirmed it is running:

$ sudo systemctl status logid
* logid.service - Logitech Configuration Daemon
     Loaded: loaded (/usr/lib/systemd/system/logid.service; enabled; preset: enabled)
     Active: active (running) since Wed 2024-05-22 22:10:03 CEST; 10h ago
   Main PID: 38321 (logid)
      Tasks: 9 (limit: 38071)
     Memory: 1.5M (peak: 2.0M)
        CPU: 4.525s
     CGroup: /system.slice/logid.service
             `-38321 /usr/bin/logid

May 22 22:22:41 marcin-PC logid[38321]: [INFO] /dev/hidraw0:2 woke up.
May 22 22:22:42 marcin-PC logid[38321]: [INFO] /dev/hidraw0:3 woke up.
May 22 22:48:28 marcin-PC logid[38321]: [INFO] /dev/hidraw0:2 fell asleep.
May 22 23:52:12 marcin-PC logid[38321]: [INFO] /dev/hidraw0:3 fell asleep.
May 23 07:33:25 marcin-PC logid[38321]: [INFO] /dev/hidraw0:3 woke up.
May 23 07:33:41 marcin-PC logid[38321]: [INFO] /dev/hidraw0:2 woke up.
May 23 08:15:10 marcin-PC logid[38321]: [INFO] /dev/hidraw0:2 fell asleep.
May 23 08:15:41 marcin-PC logid[38321]: [INFO] /dev/hidraw0:2 woke up.
May 23 08:39:14 marcin-PC logid[38321]: [INFO] /dev/hidraw0:2 fell asleep.
May 23 08:50:36 marcin-PC logid[38321]: [INFO] /dev/hidraw0:2 woke up.

And it detects device (only with sudo, otherwise it throws Permission denied):

$ sudo logid status
[INFO] Detected receiver at /dev/hidraw0
NordLex commented 4 months ago

At the moment the program can only display MX Master3 and MX Anywhere 3, and only some of their settings. Without the ability to change daemon settings. What device are you using?

m-stefanski commented 4 months ago

Ah, that would be the reason. I am using Mx Master 2S. I am looking through your code to see if I can hack in support for it.

NordLex commented 4 months ago

Search in "src/ui/device-description". The images are in "src/resources/media"