Your message dated Sat, 21 May 2022 12:33:52 +0000
with message-id <[email protected]>
and subject line Bug#1005349: fixed in joystick 1:1.8.1-1
has caused the Debian Bug report #1005349,
regarding joystick: jscal needs an option to not continue with any button
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
1005349: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1005349
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: joystick
Version: 1:1.7.1-1
Severity: normal

Dear Maintainer,

jscal asks user to move axis to a position and push any button.
This causes a problem when a trigger of a gamepad is both axis and a
button. In this case when user pulls the trigger, a button event is sent
and jscal continues before user has had a change to move the trigger to
the requested position. The problem appears with ZEROPLUS P4 Wired Gamepad.

I wrote a patch to add -b option to jscal to choose one button to use as
the continue button.

-- Package-specific info:

  looking at device 
'/devices/pci0000:00/0000:00:01.2/0000:20:00.0/0000:21:08.0/0000:2a:00.3/usb3/3-6/3-6.2/3-6.2:1.3/0003:0C12:0E16.000A/input/input38/js0':
    KERNEL=="js0"
    SUBSYSTEM=="input"
    DRIVER==""
    ATTR{power/async}=="disabled"
    ATTR{power/control}=="auto"
    ATTR{power/runtime_active_kids}=="0"
    ATTR{power/runtime_active_time}=="0"
    ATTR{power/runtime_enabled}=="disabled"
    ATTR{power/runtime_status}=="unsupported"
    ATTR{power/runtime_suspended_time}=="0"
    ATTR{power/runtime_usage}=="0"

  looking at parent device 
'/devices/pci0000:00/0000:00:01.2/0000:20:00.0/0000:21:08.0/0000:2a:00.3/usb3/3-6/3-6.2/3-6.2:1.3/0003:0C12:0E16.000A/input/input38':
    KERNELS=="input38"
    SUBSYSTEMS=="input"
    DRIVERS==""
    ATTRS{capabilities/abs}=="3003f"
    ATTRS{capabilities/ev}=="1b"
    ATTRS{capabilities/ff}=="0"
    ATTRS{capabilities/key}=="3fff000000000000 0 0 0 0"
    ATTRS{capabilities/led}=="0"
    ATTRS{capabilities/msc}=="10"
    ATTRS{capabilities/rel}=="0"
    ATTRS{capabilities/snd}=="0"
    ATTRS{capabilities/sw}=="0"
    ATTRS{id/bustype}=="0003"
    ATTRS{id/product}=="0e16"
    ATTRS{id/vendor}=="0c12"
    ATTRS{id/version}=="0111"
    ATTRS{inhibited}=="0"
    ATTRS{name}=="ZEROPLUS P4 Wired Gamepad"
    ATTRS{phys}=="usb-0000:2a:00.3-6.2/input3"
    ATTRS{power/async}=="disabled"
    ATTRS{power/control}=="auto"
    ATTRS{power/runtime_active_kids}=="0"
    ATTRS{power/runtime_active_time}=="0"
    ATTRS{power/runtime_enabled}=="disabled"
    ATTRS{power/runtime_status}=="unsupported"
    ATTRS{power/runtime_suspended_time}=="0"
    ATTRS{power/runtime_usage}=="0"
    ATTRS{properties}=="0"
    ATTRS{uniq}==""

-- System Information:
Debian Release: 11.2
  APT prefers stable-security
  APT policy: (500, 'stable-security'), (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 5.15.11 (SMP w/24 CPU threads)
Kernel taint flags: TAINT_UNSIGNED_MODULE
Locale: LANG=fi_FI.UTF-8, LC_CTYPE=fi_FI.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages joystick depends on:
ii  libc6          2.31-13+deb11u2
ii  libsdl2-2.0-0  2.0.14+dfsg2-3

Versions of packages joystick recommends:
ii  evtest       1:1.34-1
ii  inputattach  1:1.7.1-1

joystick suggests no packages.

-- no debconf information
diff -ur a/utils/jscal.c b/utils/jscal.c
--- a/utils/jscal.c     2019-10-05 22:52:45.000000000 +0300
+++ b/utils/jscal.c     2022-02-11 20:26:46.574281686 +0200
@@ -76,6 +76,8 @@
 
 }
 
+static int button = -1;
+
 int get_time(void)
 {
        struct timeval tv;
@@ -154,6 +156,7 @@
        puts("Usage: jscal <device>");
        putchar('\n');
        puts("  -c             --calibrate         Calibrate the joystick");
+       puts("  -b <number>    --button            Button to continue 
calibrating");
        puts("  -h             --help              Display this help");
        puts("  -s <x,y,z...>  --set-correction    Sets correction to specified 
values");
        puts("  -t             --test-center       Tests if joystick is 
corectly calibrated");
@@ -265,16 +268,29 @@
 
 
        b = js.buttons;
+       const char * push_msg;
+       if(button == -1) {
+               push_msg = "Move axis %d to %s position and push any button.\n";
+       }else{
+               push_msg = "Move axis %d to %s position and push the button.\n";
+       }
 
        for (axis = 0; axis < axes; axis++)
                for (pos = 0; pos < NUM_POS; pos++) {
                        while(b ^ js.buttons) wait_for_event(fd, &js);
-                       printf("Move axis %d to %s position and push any 
button.\n", axis, pos_name[pos]);
+                       printf(push_msg, axis, pos_name[pos]);
 
-                       while (!(b ^ js.buttons)) {
-                               print_position(axis, js.axis[axis]);
-                               wait_for_event(fd, &js);
-                       }
+                       if(button == -1) 
+                               while (!(b ^ js.buttons)) {
+                                       print_position(axis, js.axis[axis]);
+                                       wait_for_event(fd, &js);
+                               }
+                       else
+                                while (!(js.buttons & button)) {
+                                        print_position(axis, js.axis[axis]);
+                                        wait_for_event(fd, &js);
+                                }
+                         
 
                        putcs("Hold ... ");
 
@@ -670,6 +686,7 @@
   // /usr/include/getopt.h
        static struct option long_options[] =
        {
+               {"button", required_argument, NULL, 'b'},
                {"calibrate", no_argument, NULL, 'c'},
                {"help", no_argument, NULL, 'h'},
                {"set-correction", required_argument, NULL, 's'},
@@ -687,7 +704,7 @@
        }
 
        do {
-               t = getopt_long(argc, argv, "chpqu:s:vVt", long_options, 
&option_index);
+               t = getopt_long(argc, argv, "b:chpqu:s:vVt", long_options, 
&option_index);
                switch (t) {
                        case 'p':
                        case 'q':
@@ -704,6 +721,9 @@
                                        parameter = optarg;
                                }
                                break;
+                       case 'b':
+                               button = 1 << atoi(optarg);
+                               break;
                        case 'h':
                                help();
                                exit(0);

--- End Message ---
--- Begin Message ---
Source: joystick
Source-Version: 1:1.8.1-1
Done: Stephen Kitt <[email protected]>

We believe that the bug you reported is fixed in the latest version of
joystick, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Stephen Kitt <[email protected]> (supplier of updated joystick package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Sat, 21 May 2022 14:12:26 +0200
Source: joystick
Architecture: source
Version: 1:1.8.1-1
Distribution: unstable
Urgency: medium
Maintainer: Stephen Kitt <[email protected]>
Changed-By: Stephen Kitt <[email protected]>
Closes: 1005349 1010041
Changes:
 joystick (1:1.8.1-1) unstable; urgency=medium
 .
   [ Debian Janitor ]
   * Remove constraints unnecessary since buster:
     + joystick: Drop versioned constraint on stella in Replaces.
     + joystick: Drop versioned constraint on stella in Breaks.
     + inputattach: Drop versioned constraint on joystick in Breaks.
 .
   [ Stephen Kitt ]
   * New upstream release:
     - Fix regexes for empty lines. Closes: #1010041.
     - Allow specifying a specific button to confirm. Closes: #1005349.
   * Standards-Version 4.6.1, no change required.
Checksums-Sha1:
 dc443da208c45a3c298f0594d1004500442a87b5 2209 joystick_1.8.1-1.dsc
 321715cfd2c389cfc3be10aaabc074a7d2de3af2 53715 joystick_1.8.1.orig.tar.bz2
 a8ec80a6d9a83917b73c88d164fc3d1f55351c5b 833 joystick_1.8.1.orig.tar.bz2.asc
 651ba2eb3d03fc7cc686bc098b953b09ffacef6a 18540 joystick_1.8.1-1.debian.tar.xz
 889032f3a2e42a290256cc608aebc95bdf929d28 11088 
joystick_1.8.1-1_source.buildinfo
Checksums-Sha256:
 01926fb67e9557c7368da00d45e19f60fb8f14217ec1f3ff07d606c80b012b77 2209 
joystick_1.8.1-1.dsc
 4da29745c782b7db18f5f37c49e77bf163121dd3761e2fc7636fa0cbf35c2456 53715 
joystick_1.8.1.orig.tar.bz2
 437f190c084b19dc37123dd9abdbd815a3e64af194e64139e71702cdf9f173a4 833 
joystick_1.8.1.orig.tar.bz2.asc
 3f42dad1f4860b5a14dd778c43d48ea6bd575867230624752d39d19713333b29 18540 
joystick_1.8.1-1.debian.tar.xz
 abe8cd3e7c9e890451fd888c87620bfe88ae43de77647863833fcb384ec8caaf 11088 
joystick_1.8.1-1_source.buildinfo
Files:
 d939932e3e82d3fc6478aaf16e4e51cd 2209 utils optional joystick_1.8.1-1.dsc
 e68b6f473d81715e7be836b88fff6afe 53715 utils optional 
joystick_1.8.1.orig.tar.bz2
 e2ea1233e7e8d2c40b21edfe51fadf74 833 utils optional 
joystick_1.8.1.orig.tar.bz2.asc
 5278e78ef7c8a3cb492edef25d495805 18540 utils optional 
joystick_1.8.1-1.debian.tar.xz
 0522d152d7ac700af7fe34049fee7eeb 11088 utils optional 
joystick_1.8.1-1_source.buildinfo

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEnPVX/hPLkMoq7x0ggNMC9Yhtg5wFAmKI1z0ACgkQgNMC9Yht
g5w7WxAAkNENXGFtZnVbv+skVmOSNwmFaIiNeH4BZ+kdM6cbGFHaVVb/cP6b6VpG
sflFJwsrHirXwqmlTf2kI5jmDNdWovBiotAwCOTz65oOVHR+Njz4yiDu5Zw5TQyO
AU1rawVod9uLKqYXE4tGM3ia402RNDoQHL9Y1tZo2A+5zgqE/sV4YJILwJgqmGDX
ox+pLQ2RAWAzBEAl+PBn4bt4sAUfZVDrLBa4tMUXay4bghd6GfsU5p0q18o+GYXC
R+vhn5JSUACLtaOKiGKCbqTK7IwIShVxfA3lwmQ1+dyxuzaocs3HeD8NNole9MHQ
opvdKp+Nom8jupMnIP0atb0Pq778QRvd75rNdPoePBYCw4kLBxebfmUCFWy0LJqX
EC49AZJUnda0WOH43yNApwMOlDgd8eefTXGFFx3y9YcIbvNOay6hcJOENTGPBn5G
nYweV8uGH+gSZ4MmjoFRV5vJrSCW5Jxl7VS2daRGQZh07Goibuajz5kAS5oU7mej
YhxCMPnt9dEHG31cq+5BR6mhptW4CNmTLI5tLFb6U37H1QLEqZ4C1jmRkgEs8uhw
Nyg5ketcZa8J6ysYGwvuVlUFMtqOLZ4g6xIQsbwgcsUkrWMYFAYPVM/8iTaHIl4O
5APLPeSknkUGzkUknP6I0u9S0TBJPwPsjz9sT4jeXvGzBN+uzGI=
=9It4
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to