1

We developed a Mobile app with Xamarin forms. Now we want to give support for Android-Auto (Cars).

Made all the necessary configurations to make it work for our media player-related app on Android Auto.But I am able to see the 2 apps on the Android auto console (DHU). From one of the app, we are able to see all the content whatever we are expecting. Due to this duplicate/ multiple apps issue. I am unable to see the media content playing when we play the audio from Mobile. I have added all the necessary changes in manifest file related to MediaBrowser service and intent filter. But still facing the above mentioned issues.

Am I missing something here? How to get it to work as expected?

I added in the manifest file about support for Android-auto.

<meta-data android:name="com.google.android.gms.car.application"
    android:resource="@xml/automotive_app_desc"/>
...
James Z
  • 12,209
  • 10
  • 24
  • 44
  • did You also add in `Manifest` File? – GGK stands for Ukraine Feb 19 '23 at 21:00
  • Thanks for the quick reply. Yes, I added that too. This is how I am declaring service in the class file. [Service(Exported = true, Label = "ADF Auto",Name = "mypackagename.MediaServiceAuto")] [IntentFilter(new[] { "android.media.browse.MediaBrowserService" })] public class MediaServiceAuto : Android.Service.Media.MediaBrowserService – user1613217 Feb 20 '23 at 11:16
  • And below are only 2 items I am declaring in the manifest file. – user1613217 Feb 20 '23 at 11:17
  • and `onGetRoot` and `onLoadChildren` are the same as in your other app? – GGK stands for Ukraine Feb 20 '23 at 21:52
  • Yes, onGetRoot and onLoadChildren also there same. Even I am able to see the content (MediaContent) and tabs as expected. The main issue here I am seeing the 2 apps on the Android auto console. One app displays the UI, Tabs according to the media item and so as per my expectation but this app not playing the audio when I am playing the audio from my Phone. – user1613217 Feb 21 '23 at 12:15
  • there must be a difference...between the two apps...you have to find it – GGK stands for Ukraine Feb 21 '23 at 18:48
  • It's not two different apps. It's a single app only on Xamarin forms. Xamarin forms for Android app, I added those services and so on so it's showing as 2 apps. – user1613217 Feb 22 '23 at 12:46

0 Answers0