14

Is it possible to read vehicle information like speed,distance traveled ,fuel details, in android auto apps?
I've checked https://developer.android.com/training/auto
They are not mentioning anything about it. Do Android auto have any Interface/API to get vehicle related information.

Vishnudev K
  • 2,874
  • 3
  • 27
  • 42
  • 2
    Please let me know why the question down voted – Vishnudev K Jun 30 '15 at 07:32
  • Speed and distance are something that can be learned from the GPS module. How are you going to get fuel details though? Unless the automobile's manufacturer has installed some sort of interface that can give you relevant information the only thing you can do is estimations. – George Daramouskas Jun 30 '15 at 07:44
  • 2
    Fuel and speed details should be passed by from manufacturer. My question is, do android auto have any Interface/API to get those informations – Vishnudev K Jun 30 '15 at 09:41
  • What do you mean `should`? – George Daramouskas Jun 30 '15 at 09:42
  • 1
    lets take a mobile phone for example, GPS is an optional feature it has. Android provides an API to access GPS. Using that we can access location information regardless of manufacture of phone/GPS module (There are some phones without GPS itself, we cannot do anything about them) – Vishnudev K Jun 30 '15 at 09:43
  • I think Android Auto is more like the CD player in your car. If you need fuel and speed details, you should look into Automatic. – kaho Jul 10 '15 at 00:38
  • 1
    Can you even ask what the car make/model/year is? Android Auto right now seems like nothing more than an extension for your phone than a platform to build new interesting things. – linagee Jun 06 '17 at 18:54

3 Answers3

3

An OBD interface is a good option - Mojio, Zubie, and Automatic are commercial options, or you could even build your own with OpenXC !

But... it is coming. The 5th tab on the display is currently is a dead end, but if you enable developer mode, you can see placeholder options in the UI, and there IS a library with event listeners that the OS (which is probable Win CE or RIM's QNX, skinned by the OEM - pretty much like the Android hardware ecosystem as a metaphor) can choose to post events to... so, the API is just not public right now, presumably while Android negotiates with the OEMs to get a larger-than-piecemeal buyin...

(see this article for how to enable developer mode and to preview the placeholder information...)

jesses.co.tt
  • 2,689
  • 1
  • 30
  • 49
  • Apparently, it's not so soon. It's 2017 already. I am working with an OEM to implement a custom android auto app, and they do have a private library to implement custom UI in the last tab. However, there are not many APIs for sensors available (I mean, only a very very few available). Only the OEM is able to implement more, since they manufacture the device. – Quan To Mar 15 '17 at 08:03
  • yeah, this was a little optimistic :D – jesses.co.tt Sep 13 '17 at 19:53
  • @QuanTo Do you know whether OEMs can make available sensor events to their own Android Auto apps? I have posted this question here: https://stackoverflow.com/questions/69266574/is-it-possible-for-oem-to-share-can-bus-events-to-android-auto-app – Oleh Liskovych Sep 21 '21 at 09:55
  • 1
    @OlehLiskovych It's possible, but very limited. I answered with more details in your question. – Quan To Oct 07 '21 at 10:39
1

As of mid-2021, Android Auto apps built using the Android for Cars App Library can read this type of data and more using the CarHardwareManager API available as part of that library. The same API can also be used on Android Automotive OS devices.

Ben Sagmoe
  • 440
  • 2
  • 9
0

android auto currently allows only media and messaging services that are completely within android echo system. Android apps that provide these services can be accessed through android auto.

Anything related to vehicle sensors are not supported now. You can check obd interface for such needs.

Aun
  • 1,883
  • 1
  • 17
  • 26