N-trig configuration problem

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

N-trig configuration problem

Carlo Nucera
Hi,
I'm trying to set up the N-trig Duosense pen of a Sony Vaio Duo 11, in
Ubuntu 14.10
I have a problem with one of the two buttons on the side of the pen.

Here is the result of `xinput list`:

    carlo@med:~$ xinput list
    ⎡ Virtual core pointer                        id=2    [master pointer  (3)]
    ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
pointer  (2)]
    ⎜   ↳ N-trig DuoSense Pen                         id=10    [slave
pointer  (2)]
    ⎜   ↳ N-trig DuoSense                             id=11    [slave
pointer  (2)]
    ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
pointer  (2)]
    ⎣ Virtual core keyboard                       id=3    [master keyboard (2)]
        ↳ Virtual core XTEST keyboard                 id=5    [slave
keyboard (3)]
        ↳ Video Bus                                   id=6    [slave
keyboard (3)]
        ↳ Sony Vaio Keys                              id=7    [slave
keyboard (3)]
        ↳ Power Button                                id=8    [slave
keyboard (3)]
        ↳ USB2.0 Camera Front                         id=9    [slave
keyboard (3)]
        ↳ USB2.0 Camera Rear                          id=13    [slave
keyboard (3)]
        ↳ AT Translated Set 2 keyboard                id=14    [slave
keyboard (3)]

When I do `xinput test 10` to read the signal sent to the pen devices,
there is no particular signal I receive when using the problematic button.

However, the problematic button is not dead. In fact, if I create the
file /etc/X11/xorg.conf.d/52-wacom.conf and write in it these lines
(randomly found on the internet):

    Section "InputClass"
    Identifier "Wacom N-Trig class"
    MatchProduct "ID 1b96:0f04|N-trig DuoSense Pen"
    MatchDevicePath "/dev/input/event*"
    Driver "wacom"
    Option "Button3" "3"
    EndSection

Then my xinput --list becomes:

    carlo@med:~$ xinput list
    ⎡ Virtual core pointer                        id=2    [master pointer  (3)]
    ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
pointer  (2)]
    ⎜   ↳ N-trig DuoSense Pen stylus                  id=10    [slave
pointer  (2)]
    ⎜   ↳ N-trig DuoSense                             id=11    [slave
pointer  (2)]
    ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
pointer  (2)]
    ⎜   ↳ N-trig DuoSense Pen eraser                  id=15    [slave
pointer  (2)]
    ⎜   ↳ N-trig DuoSense Pen pad                     id=16    [slave
pointer  (2)]
    ⎣ Virtual core keyboard                       id=3    [master keyboard (2)]
        ↳ Virtual core XTEST keyboard                 id=5    [slave
keyboard (3)]
        ↳ Video Bus                                   id=6    [slave
keyboard (3)]
        ↳ Sony Vaio Keys                              id=7    [slave
keyboard (3)]
        ↳ Power Button                                id=8    [slave
keyboard (3)]
        ↳ USB2.0 Camera Front                         id=9    [slave
keyboard (3)]
        ↳ USB2.0 Camera Rear                          id=13    [slave
keyboard (3)]
        ↳ AT Translated Set 2 keyboard                id=14    [slave
keyboard (3)]

So I have more devices, and now, if I do `xinput test 15`, i.e. the
eraser, it correctly reports the pressure of my 'problematic
button'.

At the same time, when I touch the problematic button, the
cursor briefly flickers to the top left corner of the screen, and
returns where my pen is (I'd like it to stop doing this).

Also, I'd like to use the button inside the xournal
application. Xournal has two customizable settings for "button 2" and
"button 3", and seems unable to detect when I press the problematic
button (the functioning one is controlled via "button 2")

So, I don't know how to modify the snippet I put there to correct this
problem. What should I do? I understand that N-Trig is not the focus
of linuxwacom, but the driver work good enough that I feel I could do
the last mile in configuration.

Thanks in advance
Carlo Nucera

------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Linuxwacom-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: N-trig configuration problem

Jason Gerecke
On 2/3/2015 12:45 AM, Carlo Nucera wrote:

> Hi,
> I'm trying to set up the N-trig Duosense pen of a Sony Vaio Duo 11, in
> Ubuntu 14.10
> I have a problem with one of the two buttons on the side of the pen.
>
> Here is the result of `xinput list`:
>
>      carlo@med:~$ xinput list
>      ⎡ Virtual core pointer                        id=2    [master pointer  (3)]
>      ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
> pointer  (2)]
>      ⎜   ↳ N-trig DuoSense Pen                         id=10    [slave
> pointer  (2)]
>      ⎜   ↳ N-trig DuoSense                             id=11    [slave
> pointer  (2)]
>      ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
> pointer  (2)]
>      ⎣ Virtual core keyboard                       id=3    [master keyboard (2)]
>          ↳ Virtual core XTEST keyboard                 id=5    [slave
> keyboard (3)]
>          ↳ Video Bus                                   id=6    [slave
> keyboard (3)]
>          ↳ Sony Vaio Keys                              id=7    [slave
> keyboard (3)]
>          ↳ Power Button                                id=8    [slave
> keyboard (3)]
>          ↳ USB2.0 Camera Front                         id=9    [slave
> keyboard (3)]
>          ↳ USB2.0 Camera Rear                          id=13    [slave
> keyboard (3)]
>          ↳ AT Translated Set 2 keyboard                id=14    [slave
> keyboard (3)]
>
> When I do `xinput test 10` to read the signal sent to the pen devices,
> there is no particular signal I receive when using the problematic button.
>
> However, the problematic button is not dead. In fact, if I create the
> file /etc/X11/xorg.conf.d/52-wacom.conf and write in it these lines
> (randomly found on the internet):
>
>      Section "InputClass"
>      Identifier "Wacom N-Trig class"
>      MatchProduct "ID 1b96:0f04|N-trig DuoSense Pen"
>      MatchDevicePath "/dev/input/event*"
>      Driver "wacom"
>      Option "Button3" "3"
>      EndSection
>
> Then my xinput --list becomes:
>
>      carlo@med:~$ xinput list
>      ⎡ Virtual core pointer                        id=2    [master pointer  (3)]
>      ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
> pointer  (2)]
>      ⎜   ↳ N-trig DuoSense Pen stylus                  id=10    [slave
> pointer  (2)]
>      ⎜   ↳ N-trig DuoSense                             id=11    [slave
> pointer  (2)]
>      ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
> pointer  (2)]
>      ⎜   ↳ N-trig DuoSense Pen eraser                  id=15    [slave
> pointer  (2)]
>      ⎜   ↳ N-trig DuoSense Pen pad                     id=16    [slave
> pointer  (2)]
>      ⎣ Virtual core keyboard                       id=3    [master keyboard (2)]
>          ↳ Virtual core XTEST keyboard                 id=5    [slave
> keyboard (3)]
>          ↳ Video Bus                                   id=6    [slave
> keyboard (3)]
>          ↳ Sony Vaio Keys                              id=7    [slave
> keyboard (3)]
>          ↳ Power Button                                id=8    [slave
> keyboard (3)]
>          ↳ USB2.0 Camera Front                         id=9    [slave
> keyboard (3)]
>          ↳ USB2.0 Camera Rear                          id=13    [slave
> keyboard (3)]
>          ↳ AT Translated Set 2 keyboard                id=14    [slave
> keyboard (3)]
>
> So I have more devices, and now, if I do `xinput test 15`, i.e. the
> eraser, it correctly reports the pressure of my 'problematic
> button'.
>
> At the same time, when I touch the problematic button, the
> cursor briefly flickers to the top left corner of the screen, and
> returns where my pen is (I'd like it to stop doing this).
>
> Also, I'd like to use the button inside the xournal
> application. Xournal has two customizable settings for "button 2" and
> "button 3", and seems unable to detect when I press the problematic
> button (the functioning one is controlled via "button 2")
>
> So, I don't know how to modify the snippet I put there to correct this
> problem. What should I do? I understand that N-Trig is not the focus
> of linuxwacom, but the driver work good enough that I feel I could do
> the last mile in configuration.
>
> Thanks in advance
> Carlo Nucera
>
You're right that we don't get too many N-Trig questions, but it does
sound like the hardware is pretty close to working with the driver. I'm
guessing that the kernel is sending events that don't quite match up
with what we expect from Wacom devices, which causes both the top-left
flicker and Xournal's inability to detect the button press.

I'd suggest running "evemu-record"[1] to capture the events sent by the
kernel whenever you press the button. Additionally, it would be good to
know the events that `xinput test` shows when the button is pressed.

[1]:
http://linuxwacom.sourceforge.net/wiki/index.php/Analysing_kernel_events

Jason
---
Now instead of four in the eights place /
you’ve got three, ‘Cause you added one /
(That is to say, eight) to the two, /
But you can’t take seven from three, /
So you look at the sixty-fours....


------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Linuxwacom-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: N-trig configuration problem

Carlo Nucera
Hi, so in what follows I report the behaviour you requested *without*
prior adding of the lines in /etc/X11/xorg.conf.d/52-wacom.conf I
talked of in my previous mail.

--------------------------------------------------
- Output of `sudo evemu-record /dev/input/event10`
--------------------------------------------------
event10 seems to be the stylus: I got these types of events:

E: 0.000000 0001 0140 0001    # EV_KEY / BTN_TOOL_PEN
When the pen gets in/out range of the device.

E: 0.037982 0001 014a 0001    # EV_KEY / BTN_TOUCH
When the pen touches/leaves the screen.

E: 0.397984 0001 014b 0001    # EV_KEY / BTN_STYLUS
When I click/release the button which works.

E: 1.374920 0001 0141 0000    # EV_KEY / BTN_TOOL_RUBBER
When I click/release the button which doesn't work in xournal.

Then there are the movement/pressure events, which I don't report, as
well as a few events like:
E: 1.208976 0004 0004 852034    # EV_MSC / MSC_SCAN             852034

which I didn't understand properly (they seem to occur before
BTN_STYLUS or BTN_TOUCH events).

----------------------------
- Output of `xinput test 14`
----------------------------
Here I got some motion/pressure commands, and an event like

button press 2
button release 2

when I click/release the button that works. I do not get anything for
the other button.

These are the output without the configuration I mentioned you
before. Which is the best way to go forward?

Thanks
Carlo Nucera

2015-02-04 3:17 GMT+01:00 Jason Gerecke <[hidden email]>:

> On 2/3/2015 12:45 AM, Carlo Nucera wrote:
>>
>> Hi,
>> I'm trying to set up the N-trig Duosense pen of a Sony Vaio Duo 11, in
>> Ubuntu 14.10
>> I have a problem with one of the two buttons on the side of the pen.
>>
>> Here is the result of `xinput list`:
>>
>>      carlo@med:~$ xinput list
>>      ⎡ Virtual core pointer                        id=2    [master pointer
>> (3)]
>>      ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
>> pointer  (2)]
>>      ⎜   ↳ N-trig DuoSense Pen                         id=10    [slave
>> pointer  (2)]
>>      ⎜   ↳ N-trig DuoSense                             id=11    [slave
>> pointer  (2)]
>>      ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
>> pointer  (2)]
>>      ⎣ Virtual core keyboard                       id=3    [master
>> keyboard (2)]
>>          ↳ Virtual core XTEST keyboard                 id=5    [slave
>> keyboard (3)]
>>          ↳ Video Bus                                   id=6    [slave
>> keyboard (3)]
>>          ↳ Sony Vaio Keys                              id=7    [slave
>> keyboard (3)]
>>          ↳ Power Button                                id=8    [slave
>> keyboard (3)]
>>          ↳ USB2.0 Camera Front                         id=9    [slave
>> keyboard (3)]
>>          ↳ USB2.0 Camera Rear                          id=13    [slave
>> keyboard (3)]
>>          ↳ AT Translated Set 2 keyboard                id=14    [slave
>> keyboard (3)]
>>
>> When I do `xinput test 10` to read the signal sent to the pen devices,
>> there is no particular signal I receive when using the problematic button.
>>
>> However, the problematic button is not dead. In fact, if I create the
>> file /etc/X11/xorg.conf.d/52-wacom.conf and write in it these lines
>> (randomly found on the internet):
>>
>>      Section "InputClass"
>>      Identifier "Wacom N-Trig class"
>>      MatchProduct "ID 1b96:0f04|N-trig DuoSense Pen"
>>      MatchDevicePath "/dev/input/event*"
>>      Driver "wacom"
>>      Option "Button3" "3"
>>      EndSection
>>
>> Then my xinput --list becomes:
>>
>>      carlo@med:~$ xinput list
>>      ⎡ Virtual core pointer                        id=2    [master pointer
>> (3)]
>>      ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
>> pointer  (2)]
>>      ⎜   ↳ N-trig DuoSense Pen stylus                  id=10    [slave
>> pointer  (2)]
>>      ⎜   ↳ N-trig DuoSense                             id=11    [slave
>> pointer  (2)]
>>      ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
>> pointer  (2)]
>>      ⎜   ↳ N-trig DuoSense Pen eraser                  id=15    [slave
>> pointer  (2)]
>>      ⎜   ↳ N-trig DuoSense Pen pad                     id=16    [slave
>> pointer  (2)]
>>      ⎣ Virtual core keyboard                       id=3    [master
>> keyboard (2)]
>>          ↳ Virtual core XTEST keyboard                 id=5    [slave
>> keyboard (3)]
>>          ↳ Video Bus                                   id=6    [slave
>> keyboard (3)]
>>          ↳ Sony Vaio Keys                              id=7    [slave
>> keyboard (3)]
>>          ↳ Power Button                                id=8    [slave
>> keyboard (3)]
>>          ↳ USB2.0 Camera Front                         id=9    [slave
>> keyboard (3)]
>>          ↳ USB2.0 Camera Rear                          id=13    [slave
>> keyboard (3)]
>>          ↳ AT Translated Set 2 keyboard                id=14    [slave
>> keyboard (3)]
>>
>> So I have more devices, and now, if I do `xinput test 15`, i.e. the
>> eraser, it correctly reports the pressure of my 'problematic
>> button'.
>>
>> At the same time, when I touch the problematic button, the
>> cursor briefly flickers to the top left corner of the screen, and
>> returns where my pen is (I'd like it to stop doing this).
>>
>> Also, I'd like to use the button inside the xournal
>> application. Xournal has two customizable settings for "button 2" and
>> "button 3", and seems unable to detect when I press the problematic
>> button (the functioning one is controlled via "button 2")
>>
>> So, I don't know how to modify the snippet I put there to correct this
>> problem. What should I do? I understand that N-Trig is not the focus
>> of linuxwacom, but the driver work good enough that I feel I could do
>> the last mile in configuration.
>>
>> Thanks in advance
>> Carlo Nucera
>>
> You're right that we don't get too many N-Trig questions, but it does sound
> like the hardware is pretty close to working with the driver. I'm guessing
> that the kernel is sending events that don't quite match up with what we
> expect from Wacom devices, which causes both the top-left flicker and
> Xournal's inability to detect the button press.
>
> I'd suggest running "evemu-record"[1] to capture the events sent by the
> kernel whenever you press the button. Additionally, it would be good to know
> the events that `xinput test` shows when the button is pressed.
>
> [1]:
> http://linuxwacom.sourceforge.net/wiki/index.php/Analysing_kernel_events
>
> Jason
> ---
> Now instead of four in the eights place /
> you’ve got three, ‘Cause you added one /
> (That is to say, eight) to the two, /
> But you can’t take seven from three, /
> So you look at the sixty-fours....
>

------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Linuxwacom-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: N-trig configuration problem

Carlo Nucera
Ah, I just discovered that I could get the same information through
evemu-describe. Here's the output:

# EVEMU 1.2
# Input device name: "N-trig DuoSense Pen"
# Input device ID: bus 0x03 vendor 0x1b96 product 0xf00 version 0x110
# Supported events:
#   Event type 0 (EV_SYN)
#     Event code 0 (SYN_REPORT)
#     Event code 1 (SYN_CONFIG)
#     Event code 3 (SYN_MAX)
#     Event code 4 (FF_STATUS_STOPPED)
#   Event type 1 (EV_KEY)
#     Event code 256 (BTN_0)
#     Event code 320 (BTN_TOOL_PEN)
#     Event code 321 (BTN_TOOL_RUBBER)
#     Event code 330 (BTN_TOUCH)
#     Event code 331 (BTN_STYLUS)
#   Event type 3 (EV_ABS)
#     Event code 0 (ABS_X)
#       Value   7443
#       Min        0
#       Max     9600
#       Fuzz       0
#       Flat       0
#       Resolution 37
#     Event code 1 (ABS_Y)
#       Value   2599
#       Min        0
#       Max     7200
#       Fuzz       0
#       Flat       0
#       Resolution 50
#     Event code 24 (ABS_PRESSURE)
#       Value      0
#       Min        0
#       Max      256
#       Fuzz       0
#       Flat       0
#       Resolution 0
#   Event type 4 (EV_MSC)
#     Event code 4 (MSC_SCAN)
# Properties:
N: N-trig DuoSense Pen
I: 0003 1b96 0f00 0110
P: 00 00 00 00 00 00 00 00
B: 00 1b 00 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 01 01 00 00 00 00 00 00 00
B: 01 03 0c 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 01 00 00 00 00 00 00 00 00
B: 02 00 00 00 00 00 00 00 00
B: 03 03 00 00 01 00 00 00 00
B: 04 10 00 00 00 00 00 00 00
B: 05 00 00 00 00 00 00 00 00
B: 11 00 00 00 00 00 00 00 00
B: 12 00 00 00 00 00 00 00 00
B: 15 00 00 00 00 00 00 00 00
B: 15 00 00 00 00 00 00 00 00
A: 00 0 9600 0 0 37
A: 01 0 7200 0 0 50
A: 18 0 256 0 0 0

2015-02-04 11:25 GMT+01:00 Carlo Nucera <[hidden email]>:

> Hi, so in what follows I report the behaviour you requested *without*
> prior adding of the lines in /etc/X11/xorg.conf.d/52-wacom.conf I
> talked of in my previous mail.
>
> --------------------------------------------------
> - Output of `sudo evemu-record /dev/input/event10`
> --------------------------------------------------
> event10 seems to be the stylus: I got these types of events:
>
> E: 0.000000 0001 0140 0001    # EV_KEY / BTN_TOOL_PEN
> When the pen gets in/out range of the device.
>
> E: 0.037982 0001 014a 0001    # EV_KEY / BTN_TOUCH
> When the pen touches/leaves the screen.
>
> E: 0.397984 0001 014b 0001    # EV_KEY / BTN_STYLUS
> When I click/release the button which works.
>
> E: 1.374920 0001 0141 0000    # EV_KEY / BTN_TOOL_RUBBER
> When I click/release the button which doesn't work in xournal.
>
> Then there are the movement/pressure events, which I don't report, as
> well as a few events like:
> E: 1.208976 0004 0004 852034    # EV_MSC / MSC_SCAN             852034
>
> which I didn't understand properly (they seem to occur before
> BTN_STYLUS or BTN_TOUCH events).
>
> ----------------------------
> - Output of `xinput test 14`
> ----------------------------
> Here I got some motion/pressure commands, and an event like
>
> button press 2
> button release 2
>
> when I click/release the button that works. I do not get anything for
> the other button.
>
> These are the output without the configuration I mentioned you
> before. Which is the best way to go forward?
>
> Thanks
> Carlo Nucera
>
> 2015-02-04 3:17 GMT+01:00 Jason Gerecke <[hidden email]>:
>> On 2/3/2015 12:45 AM, Carlo Nucera wrote:
>>>
>>> Hi,
>>> I'm trying to set up the N-trig Duosense pen of a Sony Vaio Duo 11, in
>>> Ubuntu 14.10
>>> I have a problem with one of the two buttons on the side of the pen.
>>>
>>> Here is the result of `xinput list`:
>>>
>>>      carlo@med:~$ xinput list
>>>      ⎡ Virtual core pointer                        id=2    [master pointer
>>> (3)]
>>>      ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
>>> pointer  (2)]
>>>      ⎜   ↳ N-trig DuoSense Pen                         id=10    [slave
>>> pointer  (2)]
>>>      ⎜   ↳ N-trig DuoSense                             id=11    [slave
>>> pointer  (2)]
>>>      ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
>>> pointer  (2)]
>>>      ⎣ Virtual core keyboard                       id=3    [master
>>> keyboard (2)]
>>>          ↳ Virtual core XTEST keyboard                 id=5    [slave
>>> keyboard (3)]
>>>          ↳ Video Bus                                   id=6    [slave
>>> keyboard (3)]
>>>          ↳ Sony Vaio Keys                              id=7    [slave
>>> keyboard (3)]
>>>          ↳ Power Button                                id=8    [slave
>>> keyboard (3)]
>>>          ↳ USB2.0 Camera Front                         id=9    [slave
>>> keyboard (3)]
>>>          ↳ USB2.0 Camera Rear                          id=13    [slave
>>> keyboard (3)]
>>>          ↳ AT Translated Set 2 keyboard                id=14    [slave
>>> keyboard (3)]
>>>
>>> When I do `xinput test 10` to read the signal sent to the pen devices,
>>> there is no particular signal I receive when using the problematic button.
>>>
>>> However, the problematic button is not dead. In fact, if I create the
>>> file /etc/X11/xorg.conf.d/52-wacom.conf and write in it these lines
>>> (randomly found on the internet):
>>>
>>>      Section "InputClass"
>>>      Identifier "Wacom N-Trig class"
>>>      MatchProduct "ID 1b96:0f04|N-trig DuoSense Pen"
>>>      MatchDevicePath "/dev/input/event*"
>>>      Driver "wacom"
>>>      Option "Button3" "3"
>>>      EndSection
>>>
>>> Then my xinput --list becomes:
>>>
>>>      carlo@med:~$ xinput list
>>>      ⎡ Virtual core pointer                        id=2    [master pointer
>>> (3)]
>>>      ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
>>> pointer  (2)]
>>>      ⎜   ↳ N-trig DuoSense Pen stylus                  id=10    [slave
>>> pointer  (2)]
>>>      ⎜   ↳ N-trig DuoSense                             id=11    [slave
>>> pointer  (2)]
>>>      ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
>>> pointer  (2)]
>>>      ⎜   ↳ N-trig DuoSense Pen eraser                  id=15    [slave
>>> pointer  (2)]
>>>      ⎜   ↳ N-trig DuoSense Pen pad                     id=16    [slave
>>> pointer  (2)]
>>>      ⎣ Virtual core keyboard                       id=3    [master
>>> keyboard (2)]
>>>          ↳ Virtual core XTEST keyboard                 id=5    [slave
>>> keyboard (3)]
>>>          ↳ Video Bus                                   id=6    [slave
>>> keyboard (3)]
>>>          ↳ Sony Vaio Keys                              id=7    [slave
>>> keyboard (3)]
>>>          ↳ Power Button                                id=8    [slave
>>> keyboard (3)]
>>>          ↳ USB2.0 Camera Front                         id=9    [slave
>>> keyboard (3)]
>>>          ↳ USB2.0 Camera Rear                          id=13    [slave
>>> keyboard (3)]
>>>          ↳ AT Translated Set 2 keyboard                id=14    [slave
>>> keyboard (3)]
>>>
>>> So I have more devices, and now, if I do `xinput test 15`, i.e. the
>>> eraser, it correctly reports the pressure of my 'problematic
>>> button'.
>>>
>>> At the same time, when I touch the problematic button, the
>>> cursor briefly flickers to the top left corner of the screen, and
>>> returns where my pen is (I'd like it to stop doing this).
>>>
>>> Also, I'd like to use the button inside the xournal
>>> application. Xournal has two customizable settings for "button 2" and
>>> "button 3", and seems unable to detect when I press the problematic
>>> button (the functioning one is controlled via "button 2")
>>>
>>> So, I don't know how to modify the snippet I put there to correct this
>>> problem. What should I do? I understand that N-Trig is not the focus
>>> of linuxwacom, but the driver work good enough that I feel I could do
>>> the last mile in configuration.
>>>
>>> Thanks in advance
>>> Carlo Nucera
>>>
>> You're right that we don't get too many N-Trig questions, but it does sound
>> like the hardware is pretty close to working with the driver. I'm guessing
>> that the kernel is sending events that don't quite match up with what we
>> expect from Wacom devices, which causes both the top-left flicker and
>> Xournal's inability to detect the button press.
>>
>> I'd suggest running "evemu-record"[1] to capture the events sent by the
>> kernel whenever you press the button. Additionally, it would be good to know
>> the events that `xinput test` shows when the button is pressed.
>>
>> [1]:
>> http://linuxwacom.sourceforge.net/wiki/index.php/Analysing_kernel_events
>>
>> Jason
>> ---
>> Now instead of four in the eights place /
>> you’ve got three, ‘Cause you added one /
>> (That is to say, eight) to the two, /
>> But you can’t take seven from three, /
>> So you look at the sixty-fours....
>>

------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Linuxwacom-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: N-trig configuration problem

Jason Gerecke
In reply to this post by Carlo Nucera
Based on that information, it looks like the kernel driver interprets a
press of the second button as an indication that the pen should act as
an eraser. Unfortunately, that isn't good news for how you want to use
it. IIRC, the default "evdev" driver ignores the eraser hint entirely
which makes that button entirely useless. Our driver /should/ start
sending events from the "eraser" device when you hold down the button,
but that's still not quite good enough for Xournal.

You might get in touch with the Xournal developers to see if they'd
consider adding an e.g. "Eraser Mapping" option. They already have an
"Eraser Tip" checkbox, but you don't always want the eraser end to act
as an eraser (GIMP, for instance, allows you to use any tool with the
eraser end if you choose).

--
Jason
---
Now instead of four in the eights place /
you’ve got three, ‘Cause you added one /
(That is to say, eight) to the two, /
But you can’t take seven from three, /
So you look at the sixty-fours....


On 2/4/2015 2:25 AM, Carlo Nucera wrote:

> Hi, so in what follows I report the behaviour you requested *without*
> prior adding of the lines in /etc/X11/xorg.conf.d/52-wacom.conf I
> talked of in my previous mail.
>
> --------------------------------------------------
> - Output of `sudo evemu-record /dev/input/event10`
> --------------------------------------------------
> event10 seems to be the stylus: I got these types of events:
>
> E: 0.000000 0001 0140 0001    # EV_KEY / BTN_TOOL_PEN
> When the pen gets in/out range of the device.
>
> E: 0.037982 0001 014a 0001    # EV_KEY / BTN_TOUCH
> When the pen touches/leaves the screen.
>
> E: 0.397984 0001 014b 0001    # EV_KEY / BTN_STYLUS
> When I click/release the button which works.
>
> E: 1.374920 0001 0141 0000    # EV_KEY / BTN_TOOL_RUBBER
> When I click/release the button which doesn't work in xournal.
>
> Then there are the movement/pressure events, which I don't report, as
> well as a few events like:
> E: 1.208976 0004 0004 852034    # EV_MSC / MSC_SCAN             852034
>
> which I didn't understand properly (they seem to occur before
> BTN_STYLUS or BTN_TOUCH events).
>
> ----------------------------
> - Output of `xinput test 14`
> ----------------------------
> Here I got some motion/pressure commands, and an event like
>
> button press 2
> button release 2
>
> when I click/release the button that works. I do not get anything for
> the other button.
>
> These are the output without the configuration I mentioned you
> before. Which is the best way to go forward?
>
> Thanks
> Carlo Nucera
>
> 2015-02-04 3:17 GMT+01:00 Jason Gerecke <[hidden email]>:
>> On 2/3/2015 12:45 AM, Carlo Nucera wrote:
>>> Hi,
>>> I'm trying to set up the N-trig Duosense pen of a Sony Vaio Duo 11, in
>>> Ubuntu 14.10
>>> I have a problem with one of the two buttons on the side of the pen.
>>>
>>> Here is the result of `xinput list`:
>>>
>>>       carlo@med:~$ xinput list
>>>       ⎡ Virtual core pointer                        id=2    [master pointer
>>> (3)]
>>>       ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
>>> pointer  (2)]
>>>       ⎜   ↳ N-trig DuoSense Pen                         id=10    [slave
>>> pointer  (2)]
>>>       ⎜   ↳ N-trig DuoSense                             id=11    [slave
>>> pointer  (2)]
>>>       ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
>>> pointer  (2)]
>>>       ⎣ Virtual core keyboard                       id=3    [master
>>> keyboard (2)]
>>>           ↳ Virtual core XTEST keyboard                 id=5    [slave
>>> keyboard (3)]
>>>           ↳ Video Bus                                   id=6    [slave
>>> keyboard (3)]
>>>           ↳ Sony Vaio Keys                              id=7    [slave
>>> keyboard (3)]
>>>           ↳ Power Button                                id=8    [slave
>>> keyboard (3)]
>>>           ↳ USB2.0 Camera Front                         id=9    [slave
>>> keyboard (3)]
>>>           ↳ USB2.0 Camera Rear                          id=13    [slave
>>> keyboard (3)]
>>>           ↳ AT Translated Set 2 keyboard                id=14    [slave
>>> keyboard (3)]
>>>
>>> When I do `xinput test 10` to read the signal sent to the pen devices,
>>> there is no particular signal I receive when using the problematic button.
>>>
>>> However, the problematic button is not dead. In fact, if I create the
>>> file /etc/X11/xorg.conf.d/52-wacom.conf and write in it these lines
>>> (randomly found on the internet):
>>>
>>>       Section "InputClass"
>>>       Identifier "Wacom N-Trig class"
>>>       MatchProduct "ID 1b96:0f04|N-trig DuoSense Pen"
>>>       MatchDevicePath "/dev/input/event*"
>>>       Driver "wacom"
>>>       Option "Button3" "3"
>>>       EndSection
>>>
>>> Then my xinput --list becomes:
>>>
>>>       carlo@med:~$ xinput list
>>>       ⎡ Virtual core pointer                        id=2    [master pointer
>>> (3)]
>>>       ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
>>> pointer  (2)]
>>>       ⎜   ↳ N-trig DuoSense Pen stylus                  id=10    [slave
>>> pointer  (2)]
>>>       ⎜   ↳ N-trig DuoSense                             id=11    [slave
>>> pointer  (2)]
>>>       ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
>>> pointer  (2)]
>>>       ⎜   ↳ N-trig DuoSense Pen eraser                  id=15    [slave
>>> pointer  (2)]
>>>       ⎜   ↳ N-trig DuoSense Pen pad                     id=16    [slave
>>> pointer  (2)]
>>>       ⎣ Virtual core keyboard                       id=3    [master
>>> keyboard (2)]
>>>           ↳ Virtual core XTEST keyboard                 id=5    [slave
>>> keyboard (3)]
>>>           ↳ Video Bus                                   id=6    [slave
>>> keyboard (3)]
>>>           ↳ Sony Vaio Keys                              id=7    [slave
>>> keyboard (3)]
>>>           ↳ Power Button                                id=8    [slave
>>> keyboard (3)]
>>>           ↳ USB2.0 Camera Front                         id=9    [slave
>>> keyboard (3)]
>>>           ↳ USB2.0 Camera Rear                          id=13    [slave
>>> keyboard (3)]
>>>           ↳ AT Translated Set 2 keyboard                id=14    [slave
>>> keyboard (3)]
>>>
>>> So I have more devices, and now, if I do `xinput test 15`, i.e. the
>>> eraser, it correctly reports the pressure of my 'problematic
>>> button'.
>>>
>>> At the same time, when I touch the problematic button, the
>>> cursor briefly flickers to the top left corner of the screen, and
>>> returns where my pen is (I'd like it to stop doing this).
>>>
>>> Also, I'd like to use the button inside the xournal
>>> application. Xournal has two customizable settings for "button 2" and
>>> "button 3", and seems unable to detect when I press the problematic
>>> button (the functioning one is controlled via "button 2")
>>>
>>> So, I don't know how to modify the snippet I put there to correct this
>>> problem. What should I do? I understand that N-Trig is not the focus
>>> of linuxwacom, but the driver work good enough that I feel I could do
>>> the last mile in configuration.
>>>
>>> Thanks in advance
>>> Carlo Nucera
>>>
>> You're right that we don't get too many N-Trig questions, but it does sound
>> like the hardware is pretty close to working with the driver. I'm guessing
>> that the kernel is sending events that don't quite match up with what we
>> expect from Wacom devices, which causes both the top-left flicker and
>> Xournal's inability to detect the button press.
>>
>> I'd suggest running "evemu-record"[1] to capture the events sent by the
>> kernel whenever you press the button. Additionally, it would be good to know
>> the events that `xinput test` shows when the button is pressed.
>>
>> [1]:
>> http://linuxwacom.sourceforge.net/wiki/index.php/Analysing_kernel_events
>>
>> Jason
>> ---
>> Now instead of four in the eights place /
>> you’ve got three, ‘Cause you added one /
>> (That is to say, eight) to the two, /
>> But you can’t take seven from three, /
>> So you look at the sixty-fours....
>>


------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Linuxwacom-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-discuss
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Fwd: N-trig configuration problem

Carlo Nucera
---------- Forwarded message ----------
From: Carlo Nucera <[hidden email]>
Date: 2015-02-04 21:53 GMT+01:00
Subject: Re: [Linuxwacom-discuss] N-trig configuration problem
To: Jason Gerecke <[hidden email]>


Ok, thanks for the info. The wacom drivers starts indeed events for
the eraser. I would gladly use the 'eraser' button as an eraser,
because that's one of the more common functions. The problem is that I
can't get that Eraser Tip checkbox to correctly identify the eraser
button. How could I do that?

2015-02-04 18:58 GMT+01:00 Jason Gerecke <[hidden email]>:

> Based on that information, it looks like the kernel driver interprets a
> press of the second button as an indication that the pen should act as an
> eraser. Unfortunately, that isn't good news for how you want to use it.
> IIRC, the default "evdev" driver ignores the eraser hint entirely which
> makes that button entirely useless. Our driver /should/ start sending events
> from the "eraser" device when you hold down the button, but that's still not
> quite good enough for Xournal.
>
> You might get in touch with the Xournal developers to see if they'd consider
> adding an e.g. "Eraser Mapping" option. They already have an "Eraser Tip"
> checkbox, but you don't always want the eraser end to act as an eraser
> (GIMP, for instance, allows you to use any tool with the eraser end if you
> choose).
>
> --
> Jason
> ---
> Now instead of four in the eights place /
> you’ve got three, ‘Cause you added one /
> (That is to say, eight) to the two, /
> But you can’t take seven from three, /
> So you look at the sixty-fours....
>
>
> On 2/4/2015 2:25 AM, Carlo Nucera wrote:
>>
>> Hi, so in what follows I report the behaviour you requested *without*
>> prior adding of the lines in /etc/X11/xorg.conf.d/52-wacom.conf I
>> talked of in my previous mail.
>>
>> --------------------------------------------------
>> - Output of `sudo evemu-record /dev/input/event10`
>> --------------------------------------------------
>> event10 seems to be the stylus: I got these types of events:
>>
>> E: 0.000000 0001 0140 0001    # EV_KEY / BTN_TOOL_PEN
>> When the pen gets in/out range of the device.
>>
>> E: 0.037982 0001 014a 0001    # EV_KEY / BTN_TOUCH
>> When the pen touches/leaves the screen.
>>
>> E: 0.397984 0001 014b 0001    # EV_KEY / BTN_STYLUS
>> When I click/release the button which works.
>>
>> E: 1.374920 0001 0141 0000    # EV_KEY / BTN_TOOL_RUBBER
>> When I click/release the button which doesn't work in xournal.
>>
>> Then there are the movement/pressure events, which I don't report, as
>> well as a few events like:
>> E: 1.208976 0004 0004 852034    # EV_MSC / MSC_SCAN             852034
>>
>> which I didn't understand properly (they seem to occur before
>> BTN_STYLUS or BTN_TOUCH events).
>>
>> ----------------------------
>> - Output of `xinput test 14`
>> ----------------------------
>> Here I got some motion/pressure commands, and an event like
>>
>> button press 2
>> button release 2
>>
>> when I click/release the button that works. I do not get anything for
>> the other button.
>>
>> These are the output without the configuration I mentioned you
>> before. Which is the best way to go forward?
>>
>> Thanks
>> Carlo Nucera
>>
>> 2015-02-04 3:17 GMT+01:00 Jason Gerecke <[hidden email]>:
>>>
>>> On 2/3/2015 12:45 AM, Carlo Nucera wrote:
>>>>
>>>> Hi,
>>>> I'm trying to set up the N-trig Duosense pen of a Sony Vaio Duo 11, in
>>>> Ubuntu 14.10
>>>> I have a problem with one of the two buttons on the side of the pen.
>>>>
>>>> Here is the result of `xinput list`:
>>>>
>>>>       carlo@med:~$ xinput list
>>>>       ⎡ Virtual core pointer                        id=2    [master
>>>> pointer
>>>> (3)]
>>>>       ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
>>>> pointer  (2)]
>>>>       ⎜   ↳ N-trig DuoSense Pen                         id=10    [slave
>>>> pointer  (2)]
>>>>       ⎜   ↳ N-trig DuoSense                             id=11    [slave
>>>> pointer  (2)]
>>>>       ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
>>>> pointer  (2)]
>>>>       ⎣ Virtual core keyboard                       id=3    [master
>>>> keyboard (2)]
>>>>           ↳ Virtual core XTEST keyboard                 id=5    [slave
>>>> keyboard (3)]
>>>>           ↳ Video Bus                                   id=6    [slave
>>>> keyboard (3)]
>>>>           ↳ Sony Vaio Keys                              id=7    [slave
>>>> keyboard (3)]
>>>>           ↳ Power Button                                id=8    [slave
>>>> keyboard (3)]
>>>>           ↳ USB2.0 Camera Front                         id=9    [slave
>>>> keyboard (3)]
>>>>           ↳ USB2.0 Camera Rear                          id=13    [slave
>>>> keyboard (3)]
>>>>           ↳ AT Translated Set 2 keyboard                id=14    [slave
>>>> keyboard (3)]
>>>>
>>>> When I do `xinput test 10` to read the signal sent to the pen devices,
>>>> there is no particular signal I receive when using the problematic
>>>> button.
>>>>
>>>> However, the problematic button is not dead. In fact, if I create the
>>>> file /etc/X11/xorg.conf.d/52-wacom.conf and write in it these lines
>>>> (randomly found on the internet):
>>>>
>>>>       Section "InputClass"
>>>>       Identifier "Wacom N-Trig class"
>>>>       MatchProduct "ID 1b96:0f04|N-trig DuoSense Pen"
>>>>       MatchDevicePath "/dev/input/event*"
>>>>       Driver "wacom"
>>>>       Option "Button3" "3"
>>>>       EndSection
>>>>
>>>> Then my xinput --list becomes:
>>>>
>>>>       carlo@med:~$ xinput list
>>>>       ⎡ Virtual core pointer                        id=2    [master
>>>> pointer
>>>> (3)]
>>>>       ⎜   ↳ Virtual core XTEST pointer                  id=4    [slave
>>>> pointer  (2)]
>>>>       ⎜   ↳ N-trig DuoSense Pen stylus                  id=10    [slave
>>>> pointer  (2)]
>>>>       ⎜   ↳ N-trig DuoSense                             id=11    [slave
>>>> pointer  (2)]
>>>>       ⎜   ↳ Crucialtek co.,LTD Optical Track Pad        id=12    [slave
>>>> pointer  (2)]
>>>>       ⎜   ↳ N-trig DuoSense Pen eraser                  id=15    [slave
>>>> pointer  (2)]
>>>>       ⎜   ↳ N-trig DuoSense Pen pad                     id=16    [slave
>>>> pointer  (2)]
>>>>       ⎣ Virtual core keyboard                       id=3    [master
>>>> keyboard (2)]
>>>>           ↳ Virtual core XTEST keyboard                 id=5    [slave
>>>> keyboard (3)]
>>>>           ↳ Video Bus                                   id=6    [slave
>>>> keyboard (3)]
>>>>           ↳ Sony Vaio Keys                              id=7    [slave
>>>> keyboard (3)]
>>>>           ↳ Power Button                                id=8    [slave
>>>> keyboard (3)]
>>>>           ↳ USB2.0 Camera Front                         id=9    [slave
>>>> keyboard (3)]
>>>>           ↳ USB2.0 Camera Rear                          id=13    [slave
>>>> keyboard (3)]
>>>>           ↳ AT Translated Set 2 keyboard                id=14    [slave
>>>> keyboard (3)]
>>>>
>>>> So I have more devices, and now, if I do `xinput test 15`, i.e. the
>>>> eraser, it correctly reports the pressure of my 'problematic
>>>> button'.
>>>>
>>>> At the same time, when I touch the problematic button, the
>>>> cursor briefly flickers to the top left corner of the screen, and
>>>> returns where my pen is (I'd like it to stop doing this).
>>>>
>>>> Also, I'd like to use the button inside the xournal
>>>> application. Xournal has two customizable settings for "button 2" and
>>>> "button 3", and seems unable to detect when I press the problematic
>>>> button (the functioning one is controlled via "button 2")
>>>>
>>>> So, I don't know how to modify the snippet I put there to correct this
>>>> problem. What should I do? I understand that N-Trig is not the focus
>>>> of linuxwacom, but the driver work good enough that I feel I could do
>>>> the last mile in configuration.
>>>>
>>>> Thanks in advance
>>>> Carlo Nucera
>>>>
>>> You're right that we don't get too many N-Trig questions, but it does
>>> sound
>>> like the hardware is pretty close to working with the driver. I'm
>>> guessing
>>> that the kernel is sending events that don't quite match up with what we
>>> expect from Wacom devices, which causes both the top-left flicker and
>>> Xournal's inability to detect the button press.
>>>
>>> I'd suggest running "evemu-record"[1] to capture the events sent by the
>>> kernel whenever you press the button. Additionally, it would be good to
>>> know
>>> the events that `xinput test` shows when the button is pressed.
>>>
>>> [1]:
>>> http://linuxwacom.sourceforge.net/wiki/index.php/Analysing_kernel_events
>>>
>>> Jason
>>> ---
>>> Now instead of four in the eights place /
>>> you’ve got three, ‘Cause you added one /
>>> (That is to say, eight) to the two, /
>>> But you can’t take seven from three, /
>>> So you look at the sixty-fours....
>>>
>

------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Linuxwacom-discuss mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-discuss
Loading...