LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   Detecting the angle of HP x360 Laptops' screen (https://www.linuxquestions.org/questions/linux-hardware-18/detecting-the-angle-of-hp-x360-laptops-screen-4175591201/)

842Mono 10-11-2016 12:53 PM

Detecting the angle of HP x360 Laptops' screen
 
Hi :D

So I've been searching for a while about this. I want to do some scripting for HP x360 Laptops. These models have "hinge screens"; the screens can flip backwards till 360 degrees.

The first thing I need to do for my script is to detect the angle of the screen. How can I do that?? :D

...I have one x360 laptop with a standard Ubuntu 16.04 64bit. I installed it beside a windows 10 that was already there. win10 has a tablet mode. That's what I'm trying to do.

Later on I want to make the touchpad and keyboard buttons inactive when the screen is flipped beyond some angle. And to make the screen rotate.

Timothy Miller 10-11-2016 01:28 PM

It should have accelerometer to detect that. I have a very similar Lenovo laptop that I know with Windows detected through accelerometer. However, I kinda hate the screen flipping, so unfortunately I've never attempted to get it working in linux. But if you can get the accelerometer working, reading that will allow you to set scripts to do what you want.

842Mono 10-11-2016 01:30 PM

But how come can the accelerometer detect the screen's angle? Doesn't it detect the orientation of the device?

edit: or is it multi-functioned maybe?

Timothy Miller 10-11-2016 01:44 PM

Probably wouldn't be able to detect angle, but everything else you wanted to do. No idea for detecting angle. My Lenovo does detect angle and once it passes x* it disables the keyboard (although stupidly doesn't disable the touchpad), never looked into HOW it does it though.

842Mono 10-11-2016 01:56 PM

I see.

Does the Lenovo detect the angle on windows or on a Linux?

Timothy Miller 10-11-2016 01:59 PM

DEFINITELY Windows. I've never used it in "tablet" mode with linux to test (despite it being on it's 3rd distribution). I only bought it because I got a killer deal (they were still selling over $600 new, got it for $310 booted 1 time ever and his son decided he couldn't use such a small screen) and I use it strictly as a laptop, I don't even use the touchscreen.

842Mono 10-11-2016 02:02 PM

hehehe I see :D I wish I could have got that deal LOL XD

but how come you don't like the touch screen? It's very handy with pdfs and on-screen writing! I'm a student so I have to read lots of pdfs. I can't find a piece of software that's good with "writing on pdfs" though.

I really want to get that tablet mode going so that I can use it as a book without the keyboard or the touchpad interfering.

Timothy Miller 10-11-2016 02:05 PM

It leaves fingerprints. I HATE fingerprints. :D

I will test tonight when I get home if it disables the keyboard though in linux.

842Mono 10-11-2016 02:09 PM

awesome!! let me know! I'm not very optimistic though XD

jamison20000e 10-12-2016 07:09 PM

Hi, have fun! :hattip:

(I did not realize we had emojis here? ☔ LOL)

Timothy Miller 10-12-2016 07:56 PM

Quote:

Originally Posted by 842Mono (Post 5616640)
awesome!! let me know! I'm not very optimistic though XD


On my Lenovo Yoga 700 11, the keyboard is disabled after ~320* of rotation, so very nearly into full tablet mode. It's still active well past 180* (flat).

842Mono 10-19-2016 12:22 AM

LOL awesome! so it does work :D wish I can find out how so that I can make my hp do it too.

jamison20000e thanks you. I also like to make emojis up X-)


All times are GMT -5. The time now is 04:53 AM.