Skip to content

Commit d69e47f

Browse files
committed
build: expand section about development images
This documents the fastboot flashall command Aswell as the safe method to flash the bootloader
1 parent 53c604e commit d69e47f

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

static/build.html

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -516,6 +516,41 @@ <h3><a href="#faster-builds-for-development-use-only">Faster builds for developm
516516
signing the build with release keys would be testing that functionality and it makes a
517517
lot more sense to test it with proper signing keys rather than the default public test
518518
keys.</p>
519+
520+
<p><i>NOTE: The fastboot commands used here expect that you are running them in a shell where <i>source build/envsetup.sh</i> has been executed in.</i></p>
521+
522+
<p><i>You may also set the ANDROID_PRODUCT_OUT environment variable manually.</i></p>
523+
524+
<p>To flash those images:</p>
525+
526+
<pre>fastboot flashall</pre>
527+
528+
<p>If you want to flash -userdebug or -user images, please note that these have the ability to change the active slot on boot failure, and it is recommended
529+
to update and switch to the other slot, so the rollback mechanism does not break anything.</p>
530+
531+
<pre>fastboot flashall --slot=other --set-active=other</pre>
532+
533+
<p>When the firmware for your device gets updated, it may be necesarry to update both the radio (modem firmware) and bootloader partitions.</p>
534+
535+
<p>To do so safely, use the below script <i>(NOTE: the commands are repeated on purpose):</i></p>
536+
537+
<p>This uses the same logic as the install image to ensure not bricking your device.</p>
538+
539+
<pre>
540+
fastboot flash --slot=other bootloader
541+
fastboot --set-active=other
542+
fastboot reboot-bootloader
543+
544+
fastboot flash --slot=other bootloader
545+
fastboot --set-active=other
546+
fastboot reboot-bootloader
547+
548+
fastboot snapshot-update cancel
549+
550+
fastboot flash radio --slot=other
551+
fastboot flash radio
552+
fastboot reboot-bootloader
553+
</pre>
519554
</section>
520555

521556
<section id="generating-release-signing-keys">

0 commit comments

Comments
 (0)