12

I have an HP Pavilion DM3 notebook, running Debian Squeeze GNU/Linux (although I doubt that's relevant to my question). Browsing through the device manager listing, I found an entry for an "ST LIS3LV02DL Accelerometer."

What is this actually for? And can I do anything really nifty with it?

detly
  • 513
  • 3
  • 8
  • 24
  • I was struggling with screen rotation problem in my Ubuntu 18.04 for last two weeks and I thought it's a bug with Ubuntu itself because I couldn't undo it! I just realized it's because of this accelerometer, thanks for lighting me up =)) – Arman Safikhani Dec 05 '19 at 14:25

2 Answers2

11

It's for HDD protection, most likely. If it detects high speed movement (ie: exceeds the set 'safe zone'), the HDD stops and it protects the HDD. Pretty nice.

How to get it working...
On Windows, you need to install the driver from your manufacturer to enable the sensor. Once installed, you will find the device in your Device Manager. On a Dell Latitude, it's called "Free Fall Sensor".

On Linux, you must have a 'Linux compatible laptop'. By that I mean your laptop needs to have a module for this functionality in the kernel. ThinkPad laptops for example with recent kernels have it out of the box. It may also be possible that your laptop model has a module somewhere available that you can compile and load yourself.

You can use this sensor for many thing... like...
http://www.youtube.com/watch?v=xIFdGQNf0-c
http://www.youtube.com/watch?v=2NzmEkwynmo

For this, you need to find the sensor's raw value 'somewhere'. One example. On Linux, you should check the kernel module's source code. Once you find the location (ie. under /dev), you have to read the raw value, and using that, implement some kind of controls for games and applications. Either you can convert the input into some kind of virtual joystick input - thus getting a universal input method. Or, you can simply use the value from your application.

** This was the case in 2010, when I posted this answer back then.
Since then, Dell also became a big Linux player.

Apache
  • 15,981
  • 25
  • 100
  • 152
1

It is indeed for protecting your hard drive. If the accelerometer detects the laptop is suddenly in free-fall, it will disengage the read head, significantly reducing the chance of your hdd being destroyed in the fall.

Phoshi
  • 23,233
  • 2
  • 61
  • 81
  • Aren't read head and write head the same physical device? :) – Catherine Jun 06 '10 at 13:03
  • @whitequark: I don't know why I've always called it the read head rather than read/write head, but yes. – Phoshi Jun 06 '10 at 15:29
  • My laptop has no spinning platter HDD, it's an NVMe SSD. Is this still what it's for? – MrMesees Oct 22 '18 at 07:26
  • 1
    @MrMesees: I doubt it, solid state has no moving parts and turning it off for a fall doesn't make sense. These days it could be for orientation detection, if your laptop is a hybrid that can rotate the screen? Could also just be there because they're cheap and the board is used in something that _does_ have a use for it, or as a mechanism for denying warranty claims due to falls, or _something_. Not gonna be this any more, though. – Phoshi Oct 22 '18 at 07:45