Tell me more ×
Electrical Engineering Stack Exchange is a question and answer site for electronics and electrical engineering professionals, students, and enthusiasts. It's 100% free, no registration required.

Forgive me if this is off-topic. I haven't been very successful in my search attempts. I keep coming up with how to detect orientation programatically, and that's not what I'm after. What I'm looking for is more of a hardware/electrical engineering question.

How do tablets detect orientation of the tablet? Some can automatically switch from landscape to portrait when the screen is tilted a certain way, for example. What hardware is used to detect this, and how does it work?

share|improve this question

3 Answers

up vote 17 down vote accepted

They use an accelerometer, which measures acceleration. Since gravity and acceleration are indistinguishable, they can also measure gravity.

MEMS accelerometer

They come in the form of a little chip, like that one. You can get chips with three accelerometers on them, one pointing up, one pointing left, and one pointing forward. This way, the chip cam tell exactly which orientation it is in, and thus which way up the phone is.

Hack-a-Day also has a good article on How MEMS accelerometer chips work. How MEMS accelerometers work.

This man has his mouth open, which means he is speaking.

But how does the accelerometer work? Amazingly, inside the chip is a mass connected by a tiny spring. Gravity pulls on the mass, moving it around.

MEMS operating principle

The chip also contains a system for measuring the exact displacement of the mass, and thus the force of gravity in that direction. This is what the mass and spring actually look like:

MEMS electron micrograph

share|improve this answer
3  
Thank you for the detailed, excellent answer. I'm not sure if "This man has his mouth open, which means he is speaking." is a jab at my intelligence for asking such a basic question, but I'm laughing too hard at it to be offended if it is. Thanks for the laugh as well. – David Stratton Jun 20 '12 at 15:35
2  
@DavidStratton - Thanks! No offence intended. I just thought it was a funny picture, and deserved a funny comment. – Rocketmagnet Jun 20 '12 at 15:38
I was laughing too, otherwise I wouldn't have read the whole answer ;) – kenny Jun 20 '12 at 16:09
5  
+1 for This man has his mouth open, which means he is speaking. – AndrejaKo Jun 20 '12 at 17:48
Gravitation and acceleration are definitely NOT "the same thing"! It's true that both can be measured with the same accelerometer, but it will also give you a reading when accelerating in the absence of a gravitational field, like stevenvh says. -1 until fixed. – Federico Russo Jun 21 '12 at 4:35
show 9 more comments

They use accelerometers. These are a MEMS (Micro Electro Mechanical System) devices which have a movable part on the chip, whose capacity with the fixed part is variable. When the device is accelerated, due to its inertia the movable part will have a small displacement relative to the rest of the chip, which changes the capacity, and that's being measured.

But gravity is acceleration as well, so you will get a different signal if you hold the device vertically versus horizontally.

share|improve this answer

The sensor used to detect orientation in devices such as tablets is called an accelerometer.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.