بالإضافة إلى خيارات مطوّر Android
(التي يمكن استخدامها على كل من Android Auto وAndroid Automotive OS)، يتضمّن Android Auto وضع مطوّر خاصًا به يمكن استخدامه لتحسين تجربة التطوير. لتفعيلها، يُرجى اتّباع الخطوات التالية:
افتح إعدادات Android Auto.
الإصدار 10 من نظام التشغيل Android أو الإصدارات الأحدث: على الجهاز، انقر على الإعدادات > التطبيقات والإشعارات > عرض كل التطبيقات > Android Auto > الإعدادات المتقدّمة > إعدادات إضافية في التطبيق.
Android 9 أو الإصدارات الأقدم: في تطبيق Android Auto، انقر على القائمة، ثم انقر على الإعدادات.
انتقِل إلى قسم لمحة بالقرب من أسفل الصفحة، ثم انقر على الإصدار لعرض معلومات الإصدار والأذونات.
انقر على قسم معلومات الإصدارات والأذونات 10 مرات.
يظهر مربّع الحوار هل تريد السماح لإعدادات التطوير؟.
انقر على موافق.
تم الآن تفعيل "وضع المطوّرين"، ويمكنك الوصول إلى خيارات المطوّرين في قائمة الخيارات الإضافية. لن تحتاج إلى تفعيل "وضع مطوّر البرامج" سوى مرة واحدة. للخروج من وضع المطوّر، استخدِم الخيار من القائمة المنسدلة في شريط التطبيق.
متطلبات اختبار إضافية لتطبيقات الوسائط
إذا كنت تختبر تطبيق وسائط، اختبِر السيناريوهات الواردة في هذا القسم بالإضافة إلى اختبار تطبيقك على Android Auto أو Android Automotive OS أو كليهما.
اختبار سيناريوهات بدء تشغيل MediaBrowserService
للمساعدة في الحفاظ على سلامة السائقين والركاب، يتم فرض قيود إضافية على كيفية تفاعل المستخدمين مع التطبيقات أثناء القيادة. لهذا السبب، يتضمّن كل من Android Auto وAndroid Automotive OS بعض MediaBrowserServiceسيناريوهات بدء التشغيل التي يجب أن يتمكّن تطبيقك من التعامل معها حتى يتمكّن المستخدمون من مواصلة الاستمتاع بالمحتوى أثناء القيادة.
اختبِر تطبيقك للتأكّد من أنّه يمكنه التعامل مع كلّ من السيناريوهات التالية:
يتم تشغيل MediaBrowserService قبل فتح أي Activity.
يتم عرض MediaBrowserService عندما لا يمكن عرض أي Activity.
يتم تنفيذ MediaBrowserService عندما لا يكون المستخدم مسجّلاً الدخول.
أثناء اختبار هذه السيناريوهات، احرص على تجربة الطرق التالية:
افرِض إيقاف تطبيق الوسائط، ثم شغِّل Android Auto أو "نظام التشغيل Android Automotive".
امحُ بيانات تطبيق الوسائط، ثم شغِّل Android Auto أو Android Automotive OS.
يخضع كل من المحتوى وعيّنات التعليمات البرمجية في هذه الصفحة للتراخيص الموضحّة في ترخيص استخدام المحتوى. إنّ Java وOpenJDK هما علامتان تجاريتان مسجَّلتان لشركة Oracle و/أو الشركات التابعة لها.
تاريخ التعديل الأخير: 2025-08-27 (حسب التوقيت العالمي المتفَّق عليه)
[[["يسهُل فهم المحتوى.","easyToUnderstand","thumb-up"],["ساعَدني المحتوى في حلّ مشكلتي.","solvedMyProblem","thumb-up"],["غير ذلك","otherUp","thumb-up"]],[["لا يحتوي على المعلومات التي أحتاج إليها.","missingTheInformationINeed","thumb-down"],["الخطوات معقدة للغاية / كثيرة جدًا.","tooComplicatedTooManySteps","thumb-down"],["المحتوى قديم.","outOfDate","thumb-down"],["ثمة مشكلة في الترجمة.","translationIssue","thumb-down"],["مشكلة في العيّنات / التعليمات البرمجية","samplesCodeIssue","thumb-down"],["غير ذلك","otherDown","thumb-down"]],["تاريخ التعديل الأخير: 2025-08-27 (حسب التوقيت العالمي المتفَّق عليه)"],[],[],null,["While developing your app, there are a variety of tools available to run Android\nAuto and Android Automotive OS:\n\n- See [Test your app using the Desktop Head Unit](/training/cars/testing/dhu) for details on how to install and use the Desktop Head Unit to run Android Auto apps.\n- See [Test your app using the Android Automotive OS emulator](/training/cars/testing/emulator) for details on how to install and run Android Automotive OS images.\n- See [Test using Android Automotive OS on Pixel Tablet](/training/cars/testing/aaos-on-pixel) for details on how to install Android Automotive OS on a Pixel Tablet. Certain images also support use as an Android Auto receiver.\n- See [Access Android Automotive OS devices through Firebase Test Lab](/training/cars/testing/firebase) for details on how to test on real car hardware using Firebase Test Lab.\n- See [Test navigation app intents on Android Automotive OS](/training/cars/testing/gas-intents) on how to test the interoperability of Google Assistant and Google Maps with custom apps on Android Automotive OS.\n\n| **Important:** In addition to testing your app's user experience, ensure that your app meets all of the criteria listed on the [Android app quality for cars](/docs/quality-guidelines/car-app-quality) page for your app's category before you submit your app to Google Play for review.\n\nTest in real vehicles\n\nTo test your app in real vehicles, it must be installed from a trusted source\nsuch as the Play Store, with one exception detailed in [Allow unknown\nsources](#unknown-sources). You can use [Internal App\nSharing](https://play.google.com/console/about/internalappsharing/)\nor an [Internal Test Track](https://play.google.com/console/about/internal-testing/)\nto distribute your app to devices without going through the Play Store review\nprocess.\n\nAllow unknown sources\n\nOn Android Auto, there is a [developer option](#developer-mode) to enable\nrunning apps not installed from a trusted source. This setting applies to\n[media](/training/cars/media), [messaging notifications](/training/cars/communication/notification-messaging), and\n[parked](/training/cars/parked) apps but doesn't apply to apps built using the [Android for Cars App Library](/training/cars/apps).\n\n\u003cbr /\u003e\n\nEnable Android Auto developer mode\n\nIn addition to the [Android developer options](/studio/debug/dev-options)\n(usable on both Android Auto and Android Automotive OS), Android Auto has its\nown developer mode that can be used to improve the development experience. To\nenable it, follow these steps:\n\n1. Open the Android Auto settings.\n\n - Android 10 or higher: on the device, tap **Settings \\\u003e Apps \\&\n notifications \\\u003e See all apps \\\u003e Android Auto \\\u003e Advanced \\\u003e Additional\n settings in the app**.\n - Android 9 or lower: in the Android Auto app, tap the menu, then tap **Settings**.\n2. Scroll to the **About** section near the bottom and tap **Version** to\n display the version and permission information.\n\n3. Tap the **Version and permission info** section 10 times.\n\n The **Allow development settings?** dialog appears.\n4. Tap **OK**.\n\n Developer mode is now enabled, and you can access developer options in the\n overflow menu. You only need to enable developer mode once. To quit developer\n mode, use the option from the drop-down menu in the app bar.\n\nAdditional testing requirements for media apps\n\nIf you are testing a [media app](/training/cars#media), test for the scenarios\nthat are covered in this section in addition to testing your app on Android\nAuto, Android Automotive OS, or both.\n\nTest MediaBrowserService startup scenarios\n\nTo help keep drivers and passengers safe, users have additional restrictions on\nhow they can interact with apps while driving. For this reason, Android Auto and\nAndroid Automotive OS have some [`MediaBrowserService`](/reference/androidx/media/MediaBrowserServiceCompat)\nstartup scenarios that your app must be able to handle so that users can\ncontinue to enjoy your content while they're on the road.\n\nTest your app to make sure it can handle each of the following scenarios:\n\n- The `MediaBrowserService` is run before any `Activity` is opened.\n- The `MediaBrowserService` is run when no `Activity` can be shown.\n- The `MediaBrowserService` is run when the user is not signed in.\n\nWhile testing for these scenarios, be sure to try the following methods:\n\n- Force stop the media app, then launch Android Auto or Android Automotive OS.\n- Clear the media app data, then launch Android Auto or Android Automotive OS.\n\nAlso make sure to [set an appropriate error message](/training/cars/media/errors)\nwhen necessary.\n\nUse the Media Controller Test app\n\nThe [Media Controller Test](https://github.com/googlesamples/android-media-controller)\napp lets you test the intricacies of media playback on Android and helps\nverify your media session implementation. To get started with this tool, see\n[Using the media controller test app](/guide/topics/media-apps/audio-app/media-controller-test)."]]