A partire dal 27 marzo 2025, ti consigliamo di utilizzare android-latest-release anziché aosp-main per compilare e contribuire ad AOSP. Per ulteriori informazioni, vedi Modifiche ad AOSP.
Mantieni tutto organizzato con le raccolte
Salva e classifica i contenuti in base alle tue preferenze.
Android Flash Tool è uno strumento basato sul web che ti consente di eseguire il flashing di una build Android precompilata sul tuo dispositivo per lo sviluppo e i test.
Un browser che supporta WebUSB, come Chrome o Edge 79 e versioni successive
Attivare la connessione USB
Prima di eseguire Android su un dispositivo, devi attivare la connessione USB:
Attiva lo sblocco OEM e il debug USB nelle opzioni sviluppatore:
Nell'app Impostazioni, tocca Informazioni sul telefono.
Tocca Numero build sette volte.
Quando viene visualizzato il messaggio Ora sei uno sviluppatore, tocca <-.
Tocca Sistema, quindi Opzioni sviluppatore.
Attiva Sblocco OEM e Debug USB. Se lo sblocco OEM non è disponibile, connettiti a internet in modo che il dispositivo possa eseguire il check-in. Se il problema persiste, puoi forzare un check-in: nell'app Telefono, inserisci *#*#CHECKIN#*#* (*#*#2432546#*#*)
(non è richiesta la SIM). Dopo aver inserito il numero (non è necessario premere Chiama),
il testo scompare e viene visualizzata una notifica di esito positivo.
Se lo sblocco OEM rimane non disponibile, il tuo dispositivo potrebbe essere vincolato all'operatore tramite la SIM e il bootloader non può essere sbloccato.
Collega il dispositivo a una porta USB della workstation.
Eseguire il flashing del dispositivo
Se hai eseguito
Android Debug Bridge (adb)
sulla tua macchina, interrompi il servizio adb prima di procedere in modo che
non interferisca con la procedura di flashing. Per interrompere adb, esegui:
adbkill-server
In un browser sulla tua stazione di lavoro di sviluppo, apri
flash.android.com. Viene visualizzata la pagina di benvenuto.
Fai clic su Consenti accesso ADB per consentire allo strumento di comunicare con il tuo dispositivo di test tramite adb.
Fai clic su Aggiungi nuovo dispositivo.
Seleziona il tuo dispositivo dall'elenco e fai clic su Connetti. Questo elenco potrebbe
non contenere il nome completo del dispositivo.
Sullo schermo del dispositivo, seleziona Consenti sempre da questo computer
e fai clic su OK per accettare la connessione di debug USB.
Seleziona il dispositivo connesso nel browser.
Cerca e seleziona la build dall'elenco. Puoi anche selezionare opzioni, ad esempio resettare il dispositivo o forzare il flashing di tutte le partizioni.
Per avviare il flashing, fai clic su Installa. Il dispositivo si riavvia ed entra in modalità
fastboot.
Dopo aver visualizzato il messaggio Flash completato, scollega il dispositivo dal cavo USB.
Dispositivi Flash non in grado di avviarsi
Se il dispositivo non riesce ad avviarsi normalmente, potresti non riuscire a eseguire il flashing del dispositivo utilizzando le istruzioni precedenti. In alternativa, puoi provare a eseguire il flashing con
Fastboot.
Per farlo, devi prima avviare il dispositivo in modalità Fastboot utilizzando una combinazione di tasti:
Determina la combinazione di tasti per il tuo dispositivo. Per una tabella delle combinazioni di tasti di Fastboot, consulta Combinazioni di tasti di Fastboot.
Spegni il dispositivo.
Accendi il dispositivo e tieni immediatamente premuta la combinazione di tasti per il tuo
dispositivo (determinata nel passaggio 1).
A volte i dispositivi Android hanno difficoltà a comunicare tramite determinate porte USB o hub a causa dell'elevato throughput dei dati. Per risolvere gli errori di trasferimento:
Non utilizzare hub USB. Sono incluse le connessioni tramite monitor.
Se possibile, non utilizzare cavi di prolunga o alimentatori USB.
Prova a utilizzare un'altra porta USB. Le porte posteriori sono spesso più affidabili di quelle anteriori.
Se utilizzi una porta USB-C, prova a utilizzare una porta USB-A.
I campioni di contenuti e codice in questa pagina sono soggetti alle licenze descritte nella Licenza per i contenuti. Java e OpenJDK sono marchi o marchi registrati di Oracle e/o delle sue società consociate.
Ultimo aggiornamento 2025-07-27 UTC.
[[["Facile da capire","easyToUnderstand","thumb-up"],["Il problema è stato risolto","solvedMyProblem","thumb-up"],["Altra","otherUp","thumb-up"]],[["Mancano le informazioni di cui ho bisogno","missingTheInformationINeed","thumb-down"],["Troppo complicato/troppi passaggi","tooComplicatedTooManySteps","thumb-down"],["Obsoleti","outOfDate","thumb-down"],["Problema di traduzione","translationIssue","thumb-down"],["Problema relativo a esempi/codice","samplesCodeIssue","thumb-down"],["Altra","otherDown","thumb-down"]],["Ultimo aggiornamento 2025-07-27 UTC."],[],[],null,["# Flash with Android Flash Tool\n\n[Android Flash Tool](https://flash.android.com/)\nis a web-based tool that lets you flash a pre built Android build to your\ndevice for development and testing.\n| **Note:** If you need to flash and test your own AOSP changes, refer to [Flash your device with Fastboot](/docs/setup/test/running).\n\nAndroid Flash Tool supports these devices:\n\n- Pixel 2 and newer\n- [DragonBoard RB3 (also known as db845c)](https://wiki.linaro.org/AOSP/db845c)\n- [HiKey 960](https://www.96boards.org/product/hikey960/)\n- [HiKey](https://www.96boards.org/product/hikey/)\n\nMeet requirements\n-----------------\n\nTo run the Android Flash Tool, you must meet these requirements:\n\n- [Hardware requirements](/docs/setup/start/requirements#hardware-requirements)\n- A browser supporting [WebUSB](https://caniuse.com/#search=Webusb), such as [Chrome](https://www.google.com/chrome/) or Edge 79+\n\nEnable your USB connection\n--------------------------\n\nBefore running Android on a device, you must enable your USB connection:\n\n1. Enable OEM unlocking and USB debugging in the developer options:\n\n 1. In the Settings app, tap **About phone**.\n 2. Tap **Build number** seven times.\n 3. When you see the message **You are now a developer!** , tap **\\\u003c-**.\n 4. Tap **System** , then tap **Developer options**.\n 5. Enable **OEM unlocking** and **USB debugging** . If OEM unlocking is unavailable, connect to the internet so the device can check in. If that still doesn't work, you can force a check in: In the Dialer app, enter **\\*#\\*#CHECKIN#\\*#\\*** (\\*#\\*#2432546#\\*#\\*) (no SIM required). After entering the number (no need to press call), the text disappears and a success notification appears.\n\n If OEM unlocking remains unavailable, your device might be SIM locked by\n your carrier and the bootloader can't be unlocked.\n2. Connect your device to a USB port on your workstation.\n\nFlash your device\n-----------------\n\n1. If you have\n [Android Debug Bridge (adb)](https://developer.android.com/studio/command-line/adb)\n running on your machine, stop the adb service before proceeding so that\n it doesn't interfere with the flashing process. To stop adb, run:\n\n adb kill-server\n\n2. In a browser on your development workstation, open\n [flash.android.com](https://flash.android.com/). The Welcome page appears.\n\n3. Click **Allow ADB access** to allow the tool to communicate with your test\n device through adb.\n\n4. Click **Add new device**.\n\n5. Select your device from the list and click **Connect**. This list might\n not contain the full device name.\n\n6. On your device's screen, select **Always allow from this computer**\n and click **OK** to accept the USB debugging connection.\n\n7. Select the connected device in your browser.\n\n8. Search for and select your build from the list. You can also select\n options, such as wiping the device or force flashing all partitions.\n\n9. To start flashing, click **Install**. The device reboots and enters fastboot\n mode.\n\n10. After **Flash Complete** appears, disconnect the device from the USB cable.\n\n| **Note:** If this is the first time flashing this device from this development workstation, the workstation loses the connection to the device and asks you to find it again. The next time you flash the same device on this workstation, you won't see the request to find the device. After reconnecting, the flashing resumes by downloading the images and performing all the required steps.\n\n### Flash devices unable to boot\n\nIf your device is unable to boot normally, you might not be able to flash your\ndevice using the previous instructions. Instead, you can try flashing with\nFastboot.\n\nTo do this, you need to first boot your device into Fastboot mode by using a\nkey combination:\n\n1. Determine the key combination for your device. For a table of Fastboot key combinations, see [Fastboot key combinations](/docs/setup/reference/fastboot-keys).\n2. Turn the device off.\n3. Turn the device on and immediately hold down the key combination for your device (determined in step 1).\n\nOnce your device is in Fastboot mode, open\n[flash.android.com](https://flash.android.com/) and follow the earlier\n[flashing instructions](#flashing-your-device), ignoring the steps related to\nADB.\n\n### Resolve USB transfer errors\n\nSometimes Android devices have trouble communicating through certain USB ports\nor hubs due to the high throughput of data. To resolve transfer errors:\n\n- Don't use USB hubs. This includes connections through monitors.\n- Don't use USB extension cables or adapters if possible.\n- Try a different USB port. Rear ports are often more reliable than front ones.\n- If you're using a USB C port, try a USB A port instead.\n\nReturn Pixel to public build\n----------------------------\n\nIf you want to return your Pixel device to a public build, use the\n[Android Flash Tool back-to-public option](https://flash.android.com/back-to-public)."]]