Skip to content

Add Android Auto MediaBrowserService to enable app discovery#17

Merged
j-almenara-r merged 3 commits intomainfrom
copilot/fix-android-auto-display-issue
Jan 2, 2026
Merged

Add Android Auto MediaBrowserService to enable app discovery#17
j-almenara-r merged 3 commits intomainfrom
copilot/fix-android-auto-display-issue

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Jan 1, 2026

App doesn't appear in Android Auto because it lacks the required MediaBrowserService that Android Auto uses for app discovery.

Changes

  • Added MediaBrowserService implementation (VoiceNotesMediaBrowserService.kt)

    • Implements minimal service required for Android Auto discovery
    • Validates client packages against trusted Android Auto package names
    • Returns empty media list since app is voice notes, not media playback
  • Added automotive descriptor (res/xml/automotive_app_desc.xml)

    • Declares "media" category usage for Android Auto
  • Updated AndroidManifest.xml

    • Declared MediaBrowserService with android.media.browse.MediaBrowserService intent filter
    • Added automotive metadata reference
    • Added android.hardware.type.automotive feature (not required)
  • Added dependency (build.gradle)

    • androidx.media:media:1.7.0 for MediaBrowserServiceCompat
override fun onGetRoot(clientPackageName: String, clientUid: Int, rootHints: Bundle?): BrowserRoot? {
    return if (ALLOWED_PACKAGES.contains(clientPackageName)) {
        BrowserRoot(ROOT_ID, null)
    } else {
        null  // Reject untrusted clients
    }
}

App will now appear in Android Auto's app list when phone is connected to a car.

Original prompt

This section details on the original issue you should resolve

<issue_title>App not displayed in Android Auto</issue_title>
<issue_description>I connected the phone to my car, clicked on the apps button, and didn't see it.</issue_description>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 2 commits January 1, 2026 20:50
Co-authored-by: j-almenara-r <246562873+j-almenara-r@users.noreply.github.com>
Co-authored-by: j-almenara-r <246562873+j-almenara-r@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix app not displayed in Android Auto Add Android Auto MediaBrowserService to enable app discovery Jan 1, 2026
Copilot AI requested a review from j-almenara-r January 1, 2026 20:55
@j-almenara-r j-almenara-r marked this pull request as ready for review January 2, 2026 13:54
@j-almenara-r j-almenara-r merged commit 419bbf9 into main Jan 2, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

App not displayed in Android Auto

2 participants