Hiding or minimising the mouse cursor

580 views
Skip to first unread message

Wing Chun Lau

unread,
Apr 22, 2019, 7:22:28 AM4/22/19
to Android-x86
Hi all,

Is it possible to hide or minimise the mouse cursor on Android x86 8.0 r1?
I want to do this such that when the stylus (Surface Go) is being used (e.g. onenote), the cursor won't be shown / can be minimised to a negligible size.

Thanks in advance!

Chih-Wei Huang

unread,
Apr 23, 2019, 4:17:08 AM4/23/19
to Android-x86
Wing Chun Lau <johnn...@gmail.com> 於 2019年4月22日 週一 下午7:22寫道:
>
> Hi all,
> Is it possible to hide or minimise the mouse cursor on Android x86 8.0 r1?
> I want to do this such that when the stylus (Surface Go) is being used (e.g. onenote), the cursor won't be shown / can be minimised to a negligible size.

Unload the mouse driver?


--
Chih-Wei
Android-x86 project
http://www.android-x86.org

Wing Chun Lau

unread,
Apr 23, 2019, 6:52:01 AM4/23/19
to Android-x86
Pardon me...how can i do this?
If i do this, would i render the stylus not working too?

4TechGuns

unread,
Apr 23, 2019, 4:19:16 PM4/23/19
to Android-x86
Press Alt+F1 to enter the terminal, and then type these two commands to see if the psmouse and hid drivers are there/loaded:

lsmod | grep psmouse
lsmod | grep hid

If they are there, type these:
su
modprobe -r psmouse
modprobe -r hid

Then press Alt+F7 and see if the cursor is gone.
If this renders the stylus unusable, go back to the terminal and then type:
modprobe psmouse
modprobe hid

Wing Chun Lau

unread,
Apr 23, 2019, 8:51:36 PM4/23/19
to Android-x86
The message "SELinux: Loaded file_contexts" appears after running "modprobe -r", and the modules were still there after the command.
(I have run "su" prior to running "modprobe -r" already)

Any ideas? My current SElinux mode is permissive (haven't touched it after installation)

x86_64:/ $ lsmod | grep psmouse
1|x86_64:/ $ lsmod | grep hid
intel_hid 3649 0
sparse_keymap 4629 1 intel_hid
hid_sensor_rotation 5003 0
hid_sensor_accel_3d 5280 2
hid_sensor_gyro_3d 5267 0
hid_sensor_als 4729 0
hid_sensor_trigger 4493 6 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als
industrialio_triggered_buffer 3022 4 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als
industrialio 61586 9 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als,hid_sensor_trigger,industrialio_triggered_buffer,kfifo_buf
hid_sensor_iio_common 6401 5 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als,hid_sensor_trigger
hid_sensor_hub 12617 6 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als,hid_sensor_trigger,hid_sensor_iio_common
intel_ishtp_hid 12811 0
intel_ishtp 33074 2 intel_ishtp_hid,intel_ish_ipc
mac_hid 4052 0
hid_multitouch 12082 0
i2c_hid 14815 0
x86_64:/ $ su
x86_64:/ # modprobe -r psmouse
SELinux: Loaded file_contexts
1|x86_64:/ # modprobe -r hid
SELinux: Loaded file_contexts
1|x86_64:/ # lsmod | grep psmouse
1|x86_64:/ # lsmod | grep hid
intel_hid 3649 0
sparse_keymap 4629 1 intel_hid
hid_sensor_rotation 5003 0
hid_sensor_accel_3d 5280 2
hid_sensor_gyro_3d 5267 0
hid_sensor_als 4729 0
hid_sensor_trigger 4493 6 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als
industrialio_triggered_buffer 3022 4 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als
industrialio 61586 9 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als,hid_sensor_trigger,industrialio_triggered_buffer,kfifo_buf
hid_sensor_iio_common 6401 5 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als,hid_sensor_trigger
hid_sensor_hub 12617 6 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als,hid_sensor_trigger,hid_sensor_iio_common
intel_ishtp_hid 12811 0
intel_ishtp 33074 2 intel_ishtp_hid,intel_ish_ipc
mac_hid 4052 0
hid_multitouch 12082 0
i2c_hid 14815 0
x86_64:/ #

Chih-Wei Huang

unread,
Apr 23, 2019, 11:20:51 PM4/23/19
to Android-x86
Wing Chun Lau <johnn...@gmail.com> 於 2019年4月24日 週三 上午8:51寫道:
>
> The message "SELinux: Loaded file_contexts" appears after running "modprobe -r", and the modules were still there after the command.
> (I have run "su" prior to running "modprobe -r" already)
>
> Any ideas? My current SElinux mode is permissive (haven't touched it after installation)

The SELinux message is insignificant.

> x86_64:/ $ lsmod | grep psmouse

Your mouse driver is not psmouse (it's not loaded at all).

> 1|x86_64:/ $ lsmod | grep hid
> intel_hid 3649 0
> sparse_keymap 4629 1 intel_hid
> hid_sensor_rotation 5003 0
> hid_sensor_accel_3d 5280 2
> hid_sensor_gyro_3d 5267 0
> hid_sensor_als 4729 0
> hid_sensor_trigger 4493 6 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als
> industrialio_triggered_buffer 3022 4 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als
> industrialio 61586 9 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als,hid_sensor_trigger,industrialio_triggered_buffer,kfifo_buf
> hid_sensor_iio_common 6401 5 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als,hid_sensor_trigger
> hid_sensor_hub 12617 6 hid_sensor_rotation,hid_sensor_accel_3d,hid_sensor_gyro_3d,hid_sensor_als,hid_sensor_trigger,hid_sensor_iio_common
> intel_ishtp_hid 12811 0
> intel_ishtp 33074 2 intel_ishtp_hid,intel_ish_ipc
> mac_hid 4052 0
> hid_multitouch 12082 0
> i2c_hid 14815 0
> x86_64:/ $ su
> x86_64:/ # modprobe -r psmouse
> SELinux: Loaded file_contexts
> 1|x86_64:/ # modprobe -r hid

You can't unload hid since
there is not module called hid.

Basically it's not very easy to determine what the driver is.

First, use 'getevent -p' to get all input device names and
their event queues in your device.
For example, in my device I saw

getevent -p

...
add device 1: /dev/input/event6
name: " KYE Optical Mouse"
events:
KEY (0001): 0110 0111 0112
REL (0002): 0000 0001 0008
MSC (0004): 0004
input props:
<none>
...

It means the " KYE Optical Mouse" has event queue
in /dev/input/event6. Then find the driver of event6 by

ls -l /sys/class/input/event6/device/device/

...
lrwxrwxrwx 1 root root 0 2019-04-24 11:01 driver ->
../../../../../../../../bus/hid/drivers/hid-generic
...

So the driver is hid-generic.

Another way to disable it is to add its name to
/etc/excluded-input-devices.xml

(in the above example, its " KYE Optical Mouse")

Wing Chun Lau

unread,
Apr 24, 2019, 11:05:01 AM4/24/19
to Android-x86
I was able to disable my touchpad by adding "Microsoft Surface Type Cover Touchpad" to excluded_devices.xml

Still, when I hover my stylus (Surface pen) over the screen or touch the screen, the mouse cursor would appear.

Any ideas?

Chih-Wei Huang

unread,
Apr 24, 2019, 11:03:26 PM4/24/19
to Android-x86
Wing Chun Lau <johnn...@gmail.com> 於 2019年4月24日 週三 下午11:05寫道:
>
> I was able to disable my touchpad by adding "Microsoft Surface Type Cover Touchpad" to excluded_devices.xml
>
> Still, when I hover my stylus (Surface pen) over the screen or touch the screen, the mouse cursor would appear.

Use 'getevent -l' and then use the pen
to see which input device it is.
You may need to disable more.

Wing Chun Lau

unread,
Apr 27, 2019, 1:21:05 AM4/27/19
to Android-x86
Per testing, I think the stylus input corresponds to below device:

add device 16: /dev/input/event11
  name:     "ELAN9038:00 04F3:261A Pen"
  events:
    KEY (0001): 0140  0141  014a  014b 
    ABS (0003): 0000  : value 0, min 0, max 13312, fuzz 0, flat 0, resolution 63
                0001  : value 0, min 0, max 8960, fuzz 0, flat 0, resolution 64
                0018  : value 0, min 0, max 4096, fuzz 0, flat 0, resolution 0
                001a  : value 0, min -9000, max 9000, fuzz 0, flat 0, resolution 5730
                001b  : value 0, min -9000, max 9000, fuzz 0, flat 0, resolution 5730
                0028  : value 0, min 0, max 36000, fuzz 0, flat 0, resolution 0
    MSC (0004): 0004 
  input props:
    <none>

Interestingly, I installed cm-x86_64-14.1-r2 and found it does support stylus and the cursor is not shown. (however, the graphics acceleration seems a bit slow when using onenote app)

add device 16: /dev/input/event6
  name:     "ELAN9038:00 04F3:261A Pen"
  events:
    KEY (0001): 0100  0140  0141  014a  014b 
    ABS (0003): 0000  : value 9145, min 0, max 13312, fuzz 0, flat 0, resolution 63
                0001  : value 4172, min 0, max 8960, fuzz 0, flat 0, resolution 64
                0018  : value 0, min 0, max 4096, fuzz 0, flat 0, resolution 0
                001a  : value 1, min -9000, max 9000, fuzz 0, flat 0, resolution 5730
                001b  : value 1, min -9000, max 9000, fuzz 0, flat 0, resolution 5730
                0028  : value 1, min 0, max 100, fuzz 0, flat 0, resolution 0
                0029  : value 0, min 0, max 36000, fuzz 0, flat 0, resolution 0
    MSC (0004): 0004 
  input props:
    <none>

I found cm x86 has key 0100 and abs 0029 which is not found on x86 8.1 r1.
Is this a possible reason?

Chih-Wei Huang

unread,
Apr 28, 2019, 10:46:27 PM4/28/19
to Android-x86
Wing Chun Lau <johnn...@gmail.com> 於 2019年4月27日 週六 下午1:21寫道:
You may use 'dumpsys input' to check
the detected device type. In particular,
compare the difference between cm-x86-14.1 and 8.1-r1.
I'm afraid it's due to the the patch:

https://osdn.net/projects/android-x86/scm/git/frameworks-native/commits/bf8d48c1742e9df94bf25742248a1a282011f5cc

If yes, you may overwrite the touch.deviceType by an idc file.
See

https://source.android.com/devices/input/touch-devices

Wing Chun Lau

unread,
Apr 29, 2019, 3:49:08 AM4/29/19
to Android-x86
Done a dumpsys comp:

I spotted:
R1:
    Touch Input Mapper (mode - pointer):
      Parameters:
        GestureMode: multi-touch
        DeviceType: pointer
        AssociatedDisplay: hasAssociatedDisplay=true, isExternal=false, displayId=''
        OrientationAware: false

cm-x86:
    Touch Input Mapper:
      Parameters:
        GestureMode: multi-touch
        DeviceType: touchScreen
        AssociatedDisplay: hasAssociatedDisplay=true, isExternal=false
        OrientationAware: true

Does it mean I am indeed hit by the patch and need to overwrite the touch.deviceType?

In one section:

R1:
    5: ELAN9038:00 04F3:261A Pen
      Classes: 0x00000105
      Path: /dev/input/event6
      Enabled: true
      Descriptor: e6624875cf115cc89faf0383b2aae5d9586d8ed0
      Location: i2c-ELAN9038:00
      ControllerNumber: 0
      UniqueId: 
      Identifier: bus=0x0018, vendor=0x04f3, product=0x261a, version=0x0100
      KeyLayoutFile: /system/usr/keylayout/Generic.kl
      KeyCharacterMapFile: /system/usr/keychars/Generic.kcm
      ConfigurationFile: 
      HaveKeyboardLayoutOverlay: false

cm-x86:
    12: ELAN9038:00 04F3:261A Pen
      Classes: 0x00000105
      Path: /dev/input/event7
      Descriptor: 3d898175c563392bba5b35ca55cd58c5d6d3a811
      Location: i2c-ELAN9038:00
      ControllerNumber: 0
      UniqueId: 
      Identifier: bus=0x0018, vendor=0x04f3, product=0x261a, version=0x0100
      KeyLayoutFile: /system/usr/keylayout/Generic.kl
      KeyCharacterMapFile: /system/usr/keychars/Generic.kcm
      ConfigurationFile: 
      HaveKeyboardLayoutOverlay: false

Another section:
R1:
  Device 5: ELAN9038:00 04F3:261A Pen
    Generation: 34
    IsExternal: false
    HasMic:     false
    Sources: 0x01006113
    KeyboardType: 1
    Motion Ranges:
      X: source=0x00006002, min=0.000, max=1799.000, flat=0.000, fuzz=0.000, resolution=8.518
      Y: source=0x00006002, min=0.000, max=1199.000, flat=0.000, fuzz=0.000, resolution=8.570
      PRESSURE: source=0x00006002, min=0.000, max=1.000, flat=0.000, fuzz=0.000, resolution=0.000
      ORIENTATION: source=0x00006002, min=-3.142, max=3.142, flat=0.000, fuzz=0.000, resolution=0.000
      TILT: source=0x00006002, min=0.000, max=1.571, flat=0.000, fuzz=0.000, resolution=0.000
      GENERIC_1: source=0x01000010, min=0.000, max=1.000, flat=0.000, fuzz=0.000, resolution=0.000
      GENERIC_2: source=0x01000010, min=0.000, max=1.000, flat=0.000, fuzz=0.000, resolution=0.000
    Keyboard Input Mapper:
      Parameters:
        HasAssociatedDisplay: false
        OrientationAware: false
        HandlesKeyRepeat: false
      KeyboardType: 1
      Orientation: 0
      KeyDowns: 0 keys currently down
      MetaState: 0x0
      DownTime: 0
    Touch Input Mapper (mode - pointer):
      Parameters:
        GestureMode: multi-touch
        DeviceType: pointer
        AssociatedDisplay: hasAssociatedDisplay=true, isExternal=false, displayId=''
        OrientationAware: false
      Raw Touch Axes:
        X: min=0, max=13312, flat=0, fuzz=0, resolution=63
        Y: min=0, max=8960, flat=0, fuzz=0, resolution=64
        Pressure: min=0, max=4096, flat=0, fuzz=0, resolution=0
        TouchMajor: unknown range
        TouchMinor: unknown range
        ToolMajor: unknown range
        ToolMinor: unknown range
        Orientation: unknown range
        Distance: unknown range
        TiltX: min=-9000, max=9000, flat=0, fuzz=0, resolution=5730
        TiltY: min=-9000, max=9000, flat=0, fuzz=0, resolution=5730
        TrackingId: unknown range
        Slot: unknown range
      Calibration:
        touch.size.calibration: none
        touch.pressure.calibration: physical
        touch.orientation.calibration: none
        touch.distance.calibration: none
        touch.coverage.calibration: none
      Affine Transformation:
        X scale: 1.000
        X ymix: 0.000
        X offset: 0.000
        Y xmix: 0.000
        Y scale: 1.000
        Y offset: 0.000
      Viewport: displayId=0, orientation=0, logicalFrame=[0, 0, 1800, 1200], physicalFrame=[0, 0, 1800, 1200], deviceSize=[1800, 1200]
      SurfaceWidth: 1800px
      SurfaceHeight: 1200px
      SurfaceLeft: 0
      SurfaceTop: 0
      SurfaceOrientation: 0
      Translation and Scaling Factors:
        XTranslate: 0.000
        YTranslate: 0.000
        XScale: 0.135
        YScale: 0.134
        XPrecision: 7.396
        YPrecision: 7.468
        GeometricScale: 0.135
        PressureScale: 0.000
        SizeScale: 0.000
        OrientationScale: 0.000
        DistanceScale: 0.000
        HaveTilt: true
        TiltXCenter: 0.000
        TiltXScale: 0.017
        TiltYCenter: 0.000
        TiltYScale: 0.017
      Last Raw Button State: 0x00000000
      Last Raw Touch: pointerCount=0
      Last Cooked Button State: 0x00000000
      Last Cooked Touch: pointerCount=0
      Stylus Fusion:
        ExternalStylusConnected: false
        External Stylus ID: -1
        External Stylus Data Timeout: 9223372036854775807
      External Stylus State:
        When: 9223372036854775807
        Pressure: 0.000000
        Button State: 0x00000000
        Tool Type: 0
      Pointer Gesture Detector:
        XMovementScale: 0.108
        YMovementScale: 0.108
        XZoomScale: 0.040
        YZoomScale: 0.040
        MaxSwipeWidth: 4011.978027
    Joystick Input Mapper:
      Axes:
        GENERIC_1: min=0.00000, max=1.00000, flat=0.00000, fuzz=0.00000, resolution=0.00000
          scale=0.01000, offset=0.00000, highScale=0.01000, highOffset=0.00000
          rawAxis=40, rawMin=0, rawMax=100, rawFlat=0, rawFuzz=0, rawResolution=0
        GENERIC_2: min=0.00000, max=1.00000, flat=0.00000, fuzz=0.00000, resolution=0.00000
          scale=0.00003, offset=0.00000, highScale=0.00003, highOffset=0.00000
          rawAxis=41, rawMin=0, rawMax=36000, rawFlat=0, rawFuzz=0, rawResolution=0

cm-14:
  Device 11: ELAN9038:00 04F3:261A
    Generation: 34
    IsExternal: false
    HasMic:     false
    Sources: 0x00001002
    KeyboardType: 0
    Motion Ranges:
      X: source=0x00001002, min=0.000, max=1799.000, flat=0.000, fuzz=0.000, resolution=8.650
      Y: source=0x00001002, min=0.000, max=1199.000, flat=0.000, fuzz=0.000, resolution=8.566
      PRESSURE: source=0x00001002, min=0.000, max=1.000, flat=0.000, fuzz=0.000, resolution=0.000
      SIZE: source=0x00001002, min=0.000, max=1.000, flat=0.000, fuzz=0.000, resolution=0.000
      TOUCH_MAJOR: source=0x00001002, min=0.000, max=2163.331, flat=0.000, fuzz=0.000, resolution=0.000
      TOUCH_MINOR: source=0x00001002, min=0.000, max=2163.331, flat=0.000, fuzz=0.000, resolution=0.000
      TOOL_MAJOR: source=0x00001002, min=0.000, max=2163.331, flat=0.000, fuzz=0.000, resolution=0.000
      TOOL_MINOR: source=0x00001002, min=0.000, max=2163.331, flat=0.000, fuzz=0.000, resolution=0.000
      ORIENTATION: source=0x00001002, min=-1.571, max=1.571, flat=0.000, fuzz=0.000, resolution=0.000
    Touch Input Mapper:
      Parameters:
        GestureMode: multi-touch
        DeviceType: touchScreen
        AssociatedDisplay: hasAssociatedDisplay=true, isExternal=false
        OrientationAware: true
      Raw Touch Axes:
        X: min=0, max=2496, flat=0, fuzz=0, resolution=12
        Y: min=0, max=1680, flat=0, fuzz=0, resolution=12
        Pressure: unknown range
        TouchMajor: min=0, max=255, flat=0, fuzz=0, resolution=0
        TouchMinor: min=0, max=255, flat=0, fuzz=0, resolution=0
        ToolMajor: unknown range
        ToolMinor: unknown range
        Orientation: min=0, max=1, flat=0, fuzz=0, resolution=0
        Distance: unknown range
        TiltX: unknown range
        TiltY: unknown range
        TrackingId: min=0, max=65535, flat=0, fuzz=0, resolution=0
        Slot: min=0, max=9, flat=0, fuzz=0, resolution=0
      Calibration:
        touch.size.calibration: geometric
        touch.pressure.calibration: none
        touch.orientation.calibration: interpolated
        touch.distance.calibration: none
        touch.coverage.calibration: none
      Affine Transformation:
        X scale: 1.000
        X ymix: 0.000
        X offset: 0.000
        Y xmix: 0.000
        Y scale: 1.000
        Y offset: 0.000
      Viewport: displayId=0, orientation=0, logicalFrame=[0, 0, 1800, 1200], physicalFrame=[0, 0, 1800, 1200], deviceSize=[1800, 1200]
      SurfaceWidth: 1800px
      SurfaceHeight: 1200px
      SurfaceLeft: 0
      SurfaceTop: 0
      SurfaceOrientation: 0
      Translation and Scaling Factors:
        XTranslate: 0.000
        YTranslate: 0.000
        XScale: 0.721
        YScale: 0.714
        XPrecision: 1.387
        YPrecision: 1.401
        GeometricScale: 0.717
        PressureScale: 0.000
        SizeScale: 0.004
        OrientationScale: 1.571
        DistanceScale: 0.000
        HaveTilt: false
        TiltXCenter: 0.000
        TiltXScale: 0.000
        TiltYCenter: 0.000
        TiltYScale: 0.000
      Last Raw Button State: 0x00000000
      Last Raw Touch: pointerCount=0
      Last Cooked Button State: 0x00000000
      Last Cooked Touch: pointerCount=0
      Stylus Fusion:
        ExternalStylusConnected: false
        External Stylus ID: -1
        External Stylus Data Timeout: 9223372036854775807
      External Stylus State:
        When: 9223372036854775807
        Pressure: 0.000000
        Button State: 0x00000000
        Tool Type: 0
  Device 12: ELAN9038:00 04F3:261A Pen
    Generation: 35
    IsExternal: false
    HasMic:     false
    Sources: 0x01006113
    KeyboardType: 1
    Motion Ranges:
      X: source=0x00006002, min=0.000, max=1799.000, flat=0.000, fuzz=0.000, resolution=8.518
      Y: source=0x00006002, min=0.000, max=1199.000, flat=0.000, fuzz=0.000, resolution=8.570
      PRESSURE: source=0x00006002, min=0.000, max=1.000, flat=0.000, fuzz=0.000, resolution=0.000
      ORIENTATION: source=0x00006002, min=-3.142, max=3.142, flat=0.000, fuzz=0.000, resolution=0.000
      TILT: source=0x00006002, min=0.000, max=1.571, flat=0.000, fuzz=0.000, resolution=0.000
      GENERIC_1: source=0x01000010, min=0.000, max=1.000, flat=0.000, fuzz=0.000, resolution=0.000
      GENERIC_2: source=0x01000010, min=0.000, max=1.000, flat=0.000, fuzz=0.000, resolution=0.000
    Keyboard Input Mapper:
      Parameters:
        HasAssociatedDisplay: true
        OrientationAware: true
        HandlesKeyRepeat: false
      KeyboardType: 1
      Orientation: 0
      KeyDowns: 0 keys currently down
      MetaState: 0x0
      DownTime: 0
    Touch Input Mapper:
      Parameters:
        GestureMode: multi-touch
        DeviceType: pointer
        AssociatedDisplay: hasAssociatedDisplay=true, isExternal=false
        OrientationAware: false
      Raw Touch Axes:
        X: min=0, max=13312, flat=0, fuzz=0, resolution=63
        Y: min=0, max=8960, flat=0, fuzz=0, resolution=64
        Pressure: min=0, max=4096, flat=0, fuzz=0, resolution=0
        TouchMajor: unknown range
        TouchMinor: unknown range
        ToolMajor: unknown range
        ToolMinor: unknown range
        Orientation: unknown range
        Distance: unknown range
        TiltX: min=-9000, max=9000, flat=0, fuzz=0, resolution=5730
        TiltY: min=-9000, max=9000, flat=0, fuzz=0, resolution=5730
        TrackingId: unknown range
        Slot: unknown range
      Calibration:
        touch.size.calibration: none
        touch.pressure.calibration: physical
        touch.orientation.calibration: none
        touch.distance.calibration: none
        touch.coverage.calibration: none
      Affine Transformation:
        X scale: 1.000
        X ymix: 0.000
        X offset: 0.000
        Y xmix: 0.000
        Y scale: 1.000
        Y offset: 0.000
      Viewport: displayId=0, orientation=0, logicalFrame=[0, 0, 1800, 1200], physicalFrame=[0, 0, 1800, 1200], deviceSize=[1800, 1200]
      SurfaceWidth: 1800px
      SurfaceHeight: 1200px
      SurfaceLeft: 0
      SurfaceTop: 0
      SurfaceOrientation: 0
      Translation and Scaling Factors:
        XTranslate: 0.000
        YTranslate: 0.000
        XScale: 0.135
        YScale: 0.134
        XPrecision: 7.396
        YPrecision: 7.468
        GeometricScale: 0.135
        PressureScale: 0.000
        SizeScale: 0.000
        OrientationScale: 0.000
        DistanceScale: 0.000
        HaveTilt: true
        TiltXCenter: 0.000
        TiltXScale: 0.017
        TiltYCenter: 0.000
        TiltYScale: 0.017
      Last Raw Button State: 0x00000000
      Last Raw Touch: pointerCount=0
      Last Cooked Button State: 0x00000000
      Last Cooked Touch: pointerCount=0
      Stylus Fusion:
        ExternalStylusConnected: false
        External Stylus ID: -1
        External Stylus Data Timeout: 9223372036854775807
      External Stylus State:
        When: 9223372036854775807
        Pressure: 0.000000
        Button State: 0x00000000
        Tool Type: 0
      Pointer Gesture Detector:
        XMovementScale: 0.108
        YMovementScale: 0.108
        XZoomScale: 0.040
        YZoomScale: 0.040
        MaxSwipeWidth: 4011.978027
    Joystick Input Mapper:
      Axes:
        GENERIC_1: min=0.00000, max=1.00000, flat=0.00000, fuzz=0.00000, resolution=0.00000
          scale=0.01000, offset=0.00000, highScale=0.01000, highOffset=0.00000
          rawAxis=40, rawMin=0, rawMax=100, rawFlat=0, rawFuzz=0, rawResolution=0
        GENERIC_2: min=0.00000, max=1.00000, flat=0.00000, fuzz=0.00000, resolution=0.00000
          scale=0.00003, offset=0.00000, highScale=0.00003, highOffset=0.00000
          rawAxis=41, rawMin=0, rawMax=36000, rawFlat=0, rawFuzz=0, rawResolution=0

Chih-Wei Huang

unread,
Apr 29, 2019, 4:34:38 AM4/29/19
to Android-x86
Wing Chun Lau <johnn...@gmail.com> 於 2019年4月29日 週一 下午3:49寫道:
>
> Done a dumpsys comp:
>
> I spotted:
> R1:
> Touch Input Mapper (mode - pointer):
> Parameters:
> GestureMode: multi-touch
> DeviceType: pointer
> AssociatedDisplay: hasAssociatedDisplay=true, isExternal=false, displayId=''
> OrientationAware: false
>
> cm-x86:
> Touch Input Mapper:
> Parameters:
> GestureMode: multi-touch
> DeviceType: touchScreen
> AssociatedDisplay: hasAssociatedDisplay=true, isExternal=false
> OrientationAware: true
>
> Does it mean I am indeed hit by the patch and need to overwrite the touch.deviceType?

Right.
You need to set the deviceType to touchScreen by an idc file.

Wing Chun Lau

unread,
Apr 29, 2019, 7:53:11 PM4/29/19
to Android-x86
Thanks Chih-Wei for the guidance.

I was able to draw with Surface Pen on r8.1 r1 without showing the cursor after placing an idc file into /system/usr/idc directory.

Just in case anyone stumble upon this issue too (esp. if you have a Surface Go), here's what I did:
- Alt-F1 to show terminal
- Type `cat /proc/bus/input/devices`, look for the pen device:
I: Bus=0018 Vendor=04f3 Product=261a Version=0100
N: Name="ELAN9038:00 04F3:261A Pen"

- Create a text file with the filename:
Vendor_XXXX_Product_YYYY_Version_ZZZZ.idc, by referring to the above info shown from "I:" line:

Vendor_04f3_Product_261a_Version_0100.idc

- Below is the content of the idc file (Not sure if there are tweaks to minimise the small delay observed when writing with Surface pen on Surface Go):
# touch.deviceType = touchScreen | touchPad | pointer | default
touch.deviceType = touchScreen

# orientationAware
# touch.orientationAware = 0 or 1
touch.orientationAware = 1

- Reboot after saving the file

Cheers!

Chih-Wei Huang

unread,
Apr 30, 2019, 4:54:28 AM4/30/19
to Android-x86
I've added the idc file.
Thanks!

Wing Chun Lau <johnn...@gmail.com> 於 2019年4月30日 週二 上午7:53寫道:
Reply all
Reply to author
Forward
0 new messages