Android Enthusiasts Stack Exchange is a question and answer site for enthusiasts and power users of the Android operating system. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How does the Android phone phone it has been docked in a car holder?

I think the HTC Desire car dock can launch Car Home, but how does the phone known it's been docked?

share|improve this question
up vote 4 down vote accepted

Some Android phones, like the Nexus One, have special contacts that tell the OS when the phone has been docked.

The Desire actually doesn't have these so can't automatically detect that it has been docked. Car Home can still be launched manually.

Another option is to look at an app like Tasker. You could configure Car Home to be launched when certain conditions are met, like the phone is on charge and in a vertical position (so docked). There are many other ways you could use tasker for this.

share|improve this answer
Once the phone is docked, it sends a special 'intent' signal to applications, in this case: android.intent.category.CAR_DOCK – Bryce Nov 30 '13 at 5:35

Typically, the phone knows whether it has been docked by the placement of a magnet on a certain area on the back of the phone. You can therefore create your own cheap dock using a magnet and some sort of stand. Here is an example with the Droid.

share|improve this answer
But then you loose your compass functionality... – Denis Nikolaenko Aug 3 '11 at 4:51
@Denis Most apps that use a compass (let's say while you are driving) will switch from using the magnetometer and accelerometer to using the GPS's velocity after you go faster than say 2mph. (This is what my app, Car Dashboard, does). The magnetic compass is not very accurate to begin with. – Bryan Denny Aug 3 '11 at 15:13
Agreed, but does a permanent magnet damage the sensor? By magnetizing internal components which are made of metal? I like to go outside and magnetic sensor works quite good for me. I just do not like the idea to run at 15 km/h to get the direction from GPS. And in dense forests GPS does not always work. – Denis Nikolaenko Aug 3 '11 at 20:07
The Droid one was designed to use a magnet. Depending on which pole is facing the phone, it either activates the car dock or the desk dock. But not all phones use a magnet. Some use pin connectors to the dock to enable the dock mode. Magnets should not damage the phone, you don't have a magnetic HDD in the device like desktop computers. It's all flash memory. – Bryan Denny Aug 4 '11 at 13:37
I was worried that a magnetic sensor would be damaged by permanent magnet, not flash :) For example electronic compass application reacts, when I place a real magnetic compass (it contains a permanent magnet) near the phone. After I remove the real compass, the reading in electronic compass does not return to what was before. It is offset by 10-15 degrees. If I move a phone around and place it on the same spot in the same orientation, the reading returns to normal. Assuming that the phone uses the same brand of magnetic sensor as in Droid it should be safe to use permanent magnet around... – Denis Nikolaenko Aug 4 '11 at 16:47

Your Answer


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.