Skip to content

Commit b9ebd60

Browse files
committed
Fix configs with addintion flash step and add vendor_boot to tooling and steps
1 parent a2f3621 commit b9ebd60

File tree

8 files changed

+46
-1
lines changed

8 files changed

+46
-1
lines changed

openandroidinstaller/assets/configs/Mi439.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ steps:
5353
content: >
5454
Install additional partitions selected before by pressing 'Confirm and run'. Once it's done continue.
5555
56-
Note : If you have not selected this partition, it will do nothing.
56+
Note : If you have not selected additional partitions it will do nothing and is save to continue.
5757
command: fastboot_flash_additional_partitions
5858
- type: call_button
5959
content: >

openandroidinstaller/assets/configs/avicii.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,12 @@ steps:
3434
adapting and repairing of the operating system.
3535
Make sure your device is turned on. You need to reboot into the bootloader again by pressing 'Confirm and run' here. Then continue.
3636
command: adb_reboot_bootloader
37+
- type: call_button
38+
content: >
39+
Install additional partitions selected before by pressing 'Confirm and run'. Once it's done continue.
40+
41+
Note : If you have not selected additional partitions it will do nothing and is save to continue.
42+
command: fastboot_flash_additional_partitions
3743
- type: call_button
3844
img: twrp-start.jpeg
3945
content: >

openandroidinstaller/assets/configs/dre.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,12 @@ steps:
4040
content: >
4141
Boot a custom recovery (temporarily) by pressing 'Confirm and run'. Once it's done continue.
4242
command: fastboot_boot_recovery
43+
- type: call_button
44+
content: >
45+
Install additional partitions selected before by pressing 'Confirm and run'. Once it's done continue.
46+
47+
Note : If you have not selected additional partitions it will do nothing and is save to continue.
48+
command: fastboot_flash_additional_partitions
4349
- type: call_button
4450
content: >
4551
In some cases, the inactive slot can be unpopulated or contain much older firmware than the active slot, leading to various issues including a potential hard-brick.

openandroidinstaller/assets/configs/guacamole.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,12 @@ steps:
3434
adapting and repairing of the operating system.
3535
Make sure your device is turned on. You need to reboot into the bootloader again by pressing 'Confirm and run' here. Then continue.
3636
command: adb_reboot_bootloader
37+
- type: call_button
38+
content: >
39+
Install additional partitions selected before by pressing 'Confirm and run'. Once it's done continue.
40+
41+
Note : If you have not selected additional partitions it will do nothing and is save to continue.
42+
command: fastboot_flash_additional_partitions
3743
- type: call_button
3844
img: twrp-start.jpeg
3945
content: >

openandroidinstaller/assets/configs/hotdog.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,12 @@ steps:
3434
adapting and repairing of the operating system.
3535
Make sure your device is turned on. You need to reboot into the bootloader again by pressing 'Confirm and run' here. Then continue.
3636
command: adb_reboot_bootloader
37+
- type: call_button
38+
content: >
39+
Install additional partitions selected before by pressing 'Confirm and run'. Once it's done continue.
40+
41+
Note : If you have not selected additional partitions it will do nothing and is save to continue.
42+
command: fastboot_flash_additional_partitions
3743
- type: call_button
3844
img: twrp-start.jpeg
3945
content: >

openandroidinstaller/assets/configs/hotdogb.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,12 @@ steps:
3434
adapting and repairing of the operating system.
3535
Make sure your device is turned on. You need to reboot into the bootloader again by pressing 'Confirm and run' here. Then continue.
3636
command: adb_reboot_bootloader
37+
- type: call_button
38+
content: >
39+
Install additional partitions selected before by pressing 'Confirm and run'. Once it's done continue.
40+
41+
Note : If you have not selected additional partitions it will do nothing and is save to continue.
42+
command: fastboot_flash_additional_partitions
3743
- type: call_button
3844
img: twrp-start.jpeg
3945
content: >

openandroidinstaller/tooling.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -482,6 +482,7 @@ def fastboot_flash_additional_partitions(
482482
dtbo: Optional[str],
483483
vbmeta: Optional[str],
484484
super_empty: Optional[str],
485+
vendor_boot: Optional[str],
485486
is_ab: bool = True,
486487
) -> TerminalResponse:
487488
"""Flash additional partitions (dtbo, vbmeta, super_empty) with fastboot."""
@@ -527,6 +528,19 @@ def fastboot_flash_additional_partitions(
527528
else:
528529
yield True
529530

531+
if vendor_boot:
532+
logger.info("vendor_boot selected. Flashing vendor_boot partition.")
533+
for line in run_command(
534+
"fastboot flash vendor_boot ", target=f"{vendor_boot}", bin_path=bin_path
535+
):
536+
yield line
537+
if not is_ab:
538+
if (type(line) == bool) and not line:
539+
logger.error("Flashing vendor_boot failed.")
540+
yield False
541+
else:
542+
yield True
543+
530544

531545
def heimdall_wait_for_download_available(bin_path: Path) -> bool:
532546
"""Use heimdall detect to wait for download mode to become available on the device."""

openandroidinstaller/views/step_view.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,7 @@ def call_to_phone(self, e, command: str):
249249
dtbo=self.state.dtbo_path,
250250
vbmeta=self.state.vbmeta_path,
251251
super_empty=self.state.super_empty_path,
252+
vendor_boot=self.state.vendor_boot_path,
252253
is_ab=self.state.config.is_ab,
253254
),
254255
"fastboot_reboot": fastboot_reboot,

0 commit comments

Comments
 (0)