I've recently got a non-touchscreen hp laptop with a hdd accelerometer. After upgrading it to Debian testing I noticed that whenever I tilt my laptop upwards past +45 deg, the screen rotates upside down. The opposite happens when I tilt my laptop -45 deg. To clarify, I am facing my laptop with the screen facing me with the keyboard parallel to the ground. The screen also rotates whenever I tilt my laptop clockwise or counterclockwise.
Is there a file where I can edit to change the screen's rotational direction?
The accelerometer in /proc/bus/input/devices
shows this:
I: Bus=0019 Vendor=0000 Product=0000 Version=0000
N: Name="ST LIS3LV02DL Accelerometer"
P: Phys=lis3lv02d/input0
S: Sysfs=/devices/platform/lis3lv02d/input/input7
U: Uniq=
H: Handlers=event6 js0
B: PROP=0
B: EV=9
B: ABS=7
EDIT:
I found that watch -n 1 'cat /sys/devices/platform/lis3lv02d/position'
is similar to what is found with the command below. Except it just displays coordinates such as (18,18,1098)
.
evtest /dev/input/event6
shows this:
william@wksp0:~/Downloads$ sudo evtest /dev/input/event6
Input driver version is 1.0.1
Input device ID: bus 0x19 vendor 0x0 product 0x0 version 0x0
Input device name: "ST LIS3LV02DL Accelerometer"
Supported events:
Event type 0 (EV_SYN)
Event type 3 (EV_ABS)
Event code 0 (ABS_X)
Value 20
Min -2304
Max 2304
Fuzz 18
Flat 18
Event code 1 (ABS_Y)
Value -38
Min -2304
Max 2304
Fuzz 18
Flat 18
Event code 2 (ABS_Z)
Value 1105
Min -2304
Max 2304
Fuzz 18
Flat 18
Properties:
Testing ... (interrupt to exit)
Event: time 1483747056.088195, type 3 (EV_ABS), code 1 (ABS_Y), value -23
Event: time 1483747056.088195, -------------- SYN_REPORT ------------
Event: time 1483747056.124189, type 3 (EV_ABS), code 0 (ABS_X), value 20
Event: time 1483747056.124189, type 3 (EV_ABS), code 1 (ABS_Y), value -38
Event: time 1483747056.124189, type 3 (EV_ABS), code 2 (ABS_Z), value 1105
Event: time 1483747056.124189, -------------- SYN_REPORT ------------
Event: time 1483747056.210931, type 3 (EV_ABS), code 0 (ABS_X), value -18
Event: time 1483747056.210931, type 3 (EV_ABS), code 1 (ABS_Y), value -28
Event: time 1483747056.210931, type 3 (EV_ABS), code 2 (ABS_Z), value 1107...
EDIT2:
After some googling, I've come across this which lead me to some interesting files that have little to no help on this. :P
xrandr
show a rotated screen if the screen is rotated? What kind of events do you get for``evtest /dev/input/event6`? (assuming it's event6 on every boot, check the path).xrandr
shows that the screen is rotated when the event happens. From what I can tell, it's not a BIOS thing but either a kernel thing or a program thing.