Announcement

Collapse
No announcement yet.

Trouble with screen auto rotation (as in, its not working)

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [Monitors] Trouble with screen auto rotation (as in, its not working)

    Hi, I am trying to get the auto-rotation working on my Lenovo N23, but cant get it to work.

    If I run a `systemctl status iio-sensor-proxy`I get the following:

    Code:
    iio-sensor-proxy.service - IIO Sensor Proxy service
    Loaded: loaded (/lib/systemd/system/iio-sensor-proxy.service; static)
    Active: active (running) since Mon 2022-10-17 00:02:26 BST; 11min ago
    Main PID: 682 (iio-sensor-prox)
    Tasks: 3 (limit: 4451)
    Memory: 1.2M
    CPU: 473ms
    CGroup: /system.slice/iio-sensor-proxy.service
    └─682 /usr/libexec/iio-sensor-proxy
    
    Oct 17 00:02:25 pigeon-Lenovo-N23 systemd[1]: Starting IIO Sensor Proxy service>
    Oct 17 00:02:26 pigeon-Lenovo-N23 systemd[1]: Started IIO Sensor Proxy service.
    lines 1-12/12 (END)
    Running `monitor-sensor` gets me:

    Code:
    $ monitor-sensor
    Waiting for iio-sensor-proxy to appear
    +++ iio-sensor-proxy appeared
    === Has accelerometer (orientation: normal)
    === No ambient light sensor
    === No proximity sensor
    And, when I rotate the laptop it prints as expected:

    Code:
    Accelerometer orientation changed: right-up
    Accelerometer orientation changed: bottom-up
    Accelerometer orientation changed: left-up
    Accelerometer orientation changed: normal
    When I put `cat /proc/bus/input/devices` this is the printout:

    Code:
    : Bus=0019 Vendor=0000 Product=0005 Version=0000
    N: Name="Lid Switch"
    P: Phys=PNP0C0D/button/input0
    S: Sysfs=/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0C0D:00/input/input0
    U: Uniq=
    H: Handlers=event0
    B: PROP=0
    B: EV=21
    B: SW=1
    
    I: Bus=0019 Vendor=0000 Product=0001 Version=0000
    N: Name="Power Button"
    P: Phys=PNP0C0C/button/input0
    S: Sysfs=/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0C0C:00/input/input1
    U: Uniq=
    H: Handlers=kbd event1
    B: PROP=0
    B: EV=3
    B: KEY=10000000000000 0
    
    I: Bus=0019 Vendor=0000 Product=0001 Version=0000
    N: Name="Power Button"
    P: Phys=LNXPWRBN/button/input0
    S: Sysfs=/devices/LNXSYSTM:00/LNXPWRBN:00/input/input2
    U: Uniq=
    H: Handlers=kbd event2
    B: PROP=0
    B: EV=3
    B: KEY=10000000000000 0
    
    I: Bus=0011 Vendor=0001 Product=0001 Version=ab41
    N: Name="AT Translated Set 2 keyboard"
    P: Phys=isa0060/serio0/input0
    S: Sysfs=/devices/platform/i8042/serio0/input/input3
    U: Uniq=
    H: Handlers=sysrq kbd event3 leds
    B: PROP=0
    B: EV=120013
    B: KEY=402000000 3803078f800d001 feffffdfffefffff fffffffffffffffe
    B: MSC=10
    B: LED=7
    
    I: Bus=0011 Vendor=0002 Product=000e Version=0000
    N: Name="ETPS/2 Elantech Touchpad"
    P: Phys=isa0060/serio1/input0
    S: Sysfs=/devices/platform/i8042/serio1/input/input5
    U: Uniq=
    H: Handlers=mouse1 event5
    B: PROP=9
    B: EV=b
    B: KEY=6420 30000 0 0 0 0
    B: ABS=260800011000003
    
    I: Bus=0019 Vendor=0000 Product=0000 Version=0000
    N: Name="Ideapad extra buttons"
    P: Phys=ideapad/input0
    S: Sysfs=/devices/pci0000:00/0000:00:1f.0/PNP0C09:00/VPC2004:00/input/input8
    U: Uniq=
    H: Handlers=rfkill kbd event6
    B: PROP=0
    B: EV=13
    B: KEY=81000800100c03 4400000000300000 0 2
    B: MSC=10
    
    I: Bus=0018 Vendor=06cb Product=17c3 Version=0100
    N: Name="SYNA7060:00 06CB:17C3"
    P: Phys=i2c-SYNA7060:00
    S: Sysfs=/devices/pci0000:00/808622C1:05/i2c-1/i2c-SYNA7060:00/0018:06CB:17C3.0001/input/input9
    U: Uniq=
    H: Handlers=mouse0 event4
    B: PROP=2
    B: EV=1b
    B: KEY=400 0 0 0 0 0
    B: ABS=260800000000003
    B: MSC=20
    
    I: Bus=0003 Vendor=04f2 Product=b5a2 Version=1034
    N: Name="Lenovo EasyCamera: EasyCamera"
    P: Phys=usb-0000:00:14.0-5/button
    S: Sysfs=/devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5:1.0/input/input11
    U: Uniq=
    H: Handlers=kbd event7
    B: PROP=0
    B: EV=3
    B: KEY=100000 0 0 0
    
    I: Bus=0019 Vendor=0000 Product=0006 Version=0000
    N: Name="Video Bus"
    P: Phys=LNXVIDEO/video/input0
    S: Sysfs=/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0A08:00/LNXVIDEO:00/input/input12
    U: Uniq=
    H: Handlers=kbd event8
    B: PROP=0
    B: EV=3
    B: KEY=3e000b00000000 0 0 0
    
    I: Bus=0000 Vendor=0000 Product=0000 Version=0000
    N: Name="HDA Intel PCH Mic"
    P: Phys=ALSA
    S: Sysfs=/devices/pci0000:00/0000:00:1b.0/sound/card0/input13
    U: Uniq=
    H: Handlers=event9
    B: PROP=0
    B: EV=21
    B: SW=10
    
    I: Bus=0000 Vendor=0000 Product=0000 Version=0000
    N: Name="HDA Intel PCH Headphone"
    P: Phys=ALSA
    S: Sysfs=/devices/pci0000:00/0000:00:1b.0/sound/card0/input14
    U: Uniq=
    H: Handlers=event10
    B: PROP=0
    B: EV=21
    B: SW=4
    
    I: Bus=0000 Vendor=0000 Product=0000 Version=0000
    N: Name="HDA Intel PCH HDMI/DP,pcm=3"
    P: Phys=ALSA
    S: Sysfs=/devices/pci0000:00/0000:00:1b.0/sound/card0/input15
    U: Uniq=
    H: Handlers=event11
    B: PROP=0
    B: EV=21
    B: SW=140
    I am completely stuck on how to get this working, and throw myself on your mercy!

    #2

    Switch from Xorg to Wayland and see if it works --it probably will
    You will need to install a package to add it as an option on your login screen:
    Code:
    sudo apt install plasma-workspace-wayland
    However.....You won't have an on-screen keyboard. Kubuntu is missing maliit keyboard still, for some reason? I keep forgetting that.
    KDE Neon has it.

    The other option is to find and modify scripts that handle this in Xorg, and use Onboard as a keyboard.
    I did this when I had such a laptop. I can;t find my notes, but they were sort of hardware-specific, even though it was a lenovo laptop.
    I chucked them when I switched to Wayland
    Being a 'vintage' Chromebook, at least hardware-wise, might make it a little more "interesting"


    Two year old post mentioning a 6 year old script:
    https://www.kubuntuforums.net/forum/...230#post629230
    As far as I recall at the time, that was the ahem *easy*, but reliable method in xorg. For me rotation was molasses slow, and 90 degree resolution was always off. I never did get it tweaked to look nice and be readable.

    Comment


      #3
      Originally posted by claydoh View Post
      Switch from Xorg to Wayland and see if it works --it probably will
      You will need to install a package to add it as an option on your login screen:
      Code:
      sudo apt install plasma-workspace-wayland
      Ok, installed, but could do with some help on adding it as an option to the login screen (could also do with help on changing to having to put in a password at login, and I ticked the wrong box and now it boots straight into the desktop)

      Originally posted by claydoh View Post
      However.....You won't have an on-screen keyboard. Kubuntu is missing maliit keyboard still, for some reason? I keep forgetting that.
      KDE Neon has it.
      Fine with no keyboard, just really want it to view PDF files in portrait.

      Comment


        #4

        Login settings: System Settings Search 'login'
        In the SDDM settings, select 'Behavior' and change the autologin settings from there


        At the login screen, look at the bottom left corner , you will now see the option. This is also where you would select different desktop environments/sessions, if you install any.

        Comment


          #5
          Thank you so much for walking me through that.

          But, still getting no rotation on the screen, so strange as the accelerometer has no issue with printing out what the orientation should be

          Code:
          $ monitor-sensor
          Waiting for iio-sensor-proxy to appear
          +++ iio-sensor-proxy appeared
          === Has accelerometer (orientation: normal)
          === No ambient light sensor
          === No proximity sensor
          
          Accelerometer orientation changed: right-up
          Accelerometer orientation changed: bottom-up
          Accelerometer orientation changed: left-up
          Accelerometer orientation changed: normal

          Comment


            #6
            Try checking that the setting for 'only rotate in Tablet mode' in System Settings monitor section is un-checked. I think I had to do this on my laptop. I forgot this setting.
            I don't have that Lenovo Flex any more, I sold it so I could get a Duet 5 Chromebook - Arm based, auto-Rotation does work, but I configured the OS build wrong for this Arm64 device, so the screen is 180 degrees off when not connected to the keyboard.
            And I have forgotten exactly where to go to adjust this lol.

            Hopefully being an SoC type of system as opposed to a 'normal laptop isn't an issue here, as these can have unique hardware oddities and can sometimes NOT be plug-n-play. A and B may both work, but might not be connected in the right way.

            Comment


              #7
              Originally posted by claydoh View Post
              Try checking that the setting for 'only rotate in Tablet mode' in System Settings monitor section is un-checked.
              Thank you so much, this was the problem, went back into Xorg just to sanity check, as I was sure I had looked for that option, and sure enough, it doesn't show up Xorg, just Wayland!

              Now I just need to work out how to make a macro that presses the 2 function keys to turn off Keyboard and trackpad for when I have it folded up like a tablet as it doesn't seem to go into a "tablet mode" when folded up.

              Comment

              Working...
              X