Od 27 marca 2025 r. zalecamy używanie android-latest-release
zamiast aosp-main
do kompilowania i wspołtworzenia AOSP. Więcej informacji znajdziesz w artykule o zmianach w AOSP.
Przewodnik po przekierowywaniu USB w emulatorze
Zadbaj o dobrą organizację dzięki kolekcji
Zapisuj i kategoryzuj treści zgodnie ze swoimi preferencjami.
Na tej stronie opisano, jak włączyć urządzenia peryferyjne Bluetooth z przekierowaniem USB w emulatorze AAOS.
Aby skonfigurować połączenie przez przekierowanie USB, użyj adaptera USB Asus USB-BT400 Bluetooth 4.0. Dotyczy to Androida 13 lub nowszego.
- Podłącz kluczyk do komputera z systemem Linux.
Aby sprawdzić, czy urządzenie działa zgodnie z oczekiwaniami, uruchom polecenie lsusb
.
Wyświetlane są wartości VendorId(0x0b05)
i ProductId (0x17cb)
adaptera Asus BT-400.
$ lsusb
Bus 001 Device 010: ID 0b05:17cb ASUSTek Computer, Inc. Broadcom BCM20702A0 Bluetooth
Uruchom emulator z informacjami o przesyłaniu przez USB.
$ emulator -cores 4 -memory 6144 -usb-passthrough vendorid=0x0b05,productid=0x17cb
Testowane klucze:
Inne dongle'e mogą działać, ale nie były testowane.
Treść strony i umieszczone na niej fragmenty kodu podlegają licencjom opisanym w Licencji na treści. Java i OpenJDK są znakami towarowymi lub zastrzeżonymi znakami towarowymi należącymi do firmy Oracle lub jej podmiotów stowarzyszonych.
Ostatnia aktualizacja: 2025-03-26 UTC.
[[["Łatwo zrozumieć","easyToUnderstand","thumb-up"],["Rozwiązało to mój problem","solvedMyProblem","thumb-up"],["Inne","otherUp","thumb-up"]],[["Brak potrzebnych mi informacji","missingTheInformationINeed","thumb-down"],["Zbyt skomplikowane / zbyt wiele czynności do wykonania","tooComplicatedTooManySteps","thumb-down"],["Nieaktualne treści","outOfDate","thumb-down"],["Problem z tłumaczeniem","translationIssue","thumb-down"],["Problem z przykładami/kodem","samplesCodeIssue","thumb-down"],["Inne","otherDown","thumb-down"]],["Ostatnia aktualizacja: 2025-03-26 UTC."],[],[],null,["# Emulator USB passthrough guide\n\nThis page describes how to enable Bluetooth peripherals with USB passthrough for\nthe AAOS emulator.\n\nUse The Asus USB-BT400 Bluetooth 4.0 USB adapter to set up the USB passthrough\nconnection. This applies for Android 13 and higher.\n\n1. Connect the dongle to the Linux host machine.\n2. To confirm the device functions as intended, run the `lsusb` command.\n Values for the `VendorId(0x0b05)` and `ProductId (0x17cb)` of the Asus\n BT-400 adapter are displayed.\n\n $ lsusb\n\n Bus 001 Device 010: ID 0b05:17cb ASUSTek Computer, Inc. Broadcom BCM20702A0 Bluetooth\n\n3. Launch the emulator with the usb-passthrough information.\n\n $ emulator -cores 4 -memory 6144 -usb-passthrough vendorid=0x0b05,productid=0x17cb\n\nThe dongles tested are:\n\n- [ASUS USB-BT400 USB Adapter](https://www.asus.com/us/Networking-IoT-Servers/Adapters/All-series/USBBT400/)\n\nOther dongles may work, however, not tested."]]