my phone app needs to launch Google map (or navigation) on the dashboard automatically when it meets some requirements. However when checking this link https://developer.android.com/auto/index.html it looks like they only allow audio and messages or am I missing anything? Thanks
2 Answers
I guess from a notification reply your app could start a google map intent.
You would define a MyMessageReplyReceiver in your app Manifest:
<receiver android:name=".MyMessageReplyReceiver">
<intent-filter>
<action android:name="com.myapp.messagingservice.MY_ACTION_MESSAGE_REPLY"/>
</intent-filter>
</receiver>
Then following these explanations on How to Handle User Action, you would launch Google Maps from your app using an intent:
public class MyMessageReplyReceiver extends BroadcastReceiver {
@Override
public void onReceive(Context context, Intent intent) {
/* Intent code to start Google Maps */
// Create a Uri from an intent string. Use the result to create an Intent.
Uri gmmIntentUri = Uri.parse("google.streetview:cbll=46.414382,10.013988");
// Create an Intent from gmmIntentUri. Set the action to ACTION_VIEW
Intent mapIntent = new Intent(Intent.ACTION_VIEW, gmmIntentUri);
// Make the Intent explicit by setting the Google Maps package
mapIntent.setPackage("com.google.android.apps.maps");
// Attempt to start an activity that can handle the Intent
context.startActivity(mapIntent);
}
}
FYI: I haven't tested it, just a thought about how I would do it

- 33
- 6
The Android Auto platform isn't on your phone. It's a completely new device. Like a board computer in modern cars, but then with Android Auto installed.
If you want to launch the Google Maps app you'll need to look at your phone instead of looking at your cars computer. If that's what you want, I recommend to write a broadcast receiver that receives the bluetooth connected message, check if it is the right device, and open the Google Maps app.

- 2,256
- 2
- 17
- 28
-
I want to launch Googlemap of the dashboard device, not my phone since the driver alelready look at the dashboard. Like in their promo screenshot I do see a map. – EyeQ Tech Mar 26 '15 at 00:59