Skip to content

Commit

Permalink
Update the unlocking instructions for FP3/4 and add fastboot_unlock_c…
Browse files Browse the repository at this point in the history
…ritical command
  • Loading branch information
tsterbak committed Jul 26, 2023
1 parent 35d0d2d commit 1113cb8
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 9 deletions.
16 changes: 12 additions & 4 deletions openandroidinstaller/assets/configs/FP3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,25 @@ steps:
content: >
Press 'Confirm and run' to reboot into the bootloader.
command: adb_reboot_bootloader
- type: confirm_button
content: >
Select 'Restart bootloader' on your smartphone screen by pressing the volume button and the confirm by pushing the power button.
Then press 'Confirm and continue' here.
- type: call_button
content: >
In this step you actually unlock the bootloader. Just press 'Confirm and run' here. Once it's done, press continue here.
command: fastboot_unlock
- type: confirm_button
content: >
Follow the instructions on the Fairphone screen. This command will wipe all the personal data on your phone.
- type: call_button
content: >
After the phone reboots, boot into the fastboot mode once again by pressing 'Confirm and run' here. Then continue.
command: adb_reboot_bootloader
- type: call_button
content: >
When you are in fastboot mode again, you need to run another unlock step here.
Just press 'Confirm and run' here. Once it's done, press continue here.
command: fastboot_unlock_critical
- type: confirm_button
content: >
Follow the instructions on the Fairphone screen. This command will wipe all the personal data on your phone.
- type: call_button
content: >
To finish the unlocking, the phone needs to reboot. Just press 'Confirm and run' here to reboot. Then continue.
Expand Down
18 changes: 13 additions & 5 deletions openandroidinstaller/assets/configs/FP4.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,30 @@ steps:
how to start and run an operating system (like Android). Your device should be turned on.
Click on the button to open the instructions on the Fairphone Support official unlocking website to generate an unlock code for your device.
Once you've done that, continue.
link: https://support.fairphone.com/hc/en-us/articles/4405858258961-FP4-Manage-the-bootloader
link: https://www.fairphone.com/en/bootloader-unlocking-code-for-fairphone-3/
- type: call_button
content: >
Press 'Confirm and run' to reboot into the bootloader.
command: adb_reboot_bootloader
- type: confirm_button
content: >
Select 'Restart bootloader' on your smartphone screen by pressing the volume button and the confirm by pushing the power button.
Then press 'Confirm and continue' here.
- type: call_button
content: >
In this step you actually unlock the bootloader. Just press 'Confirm and run' here. Once it's done, press continue here.
command: fastboot_unlock
- type: confirm_button
content: >
Follow the instructions on the Fairphone screen. This command will wipe all the personal data on your phone.
- type: call_button
content: >
After the phone reboots, boot into the fastboot mode once again by pressing 'Confirm and run' here. Then continue.
command: adb_reboot_bootloader
- type: call_button
content: >
When you are in fastboot mode again, you need to run another unlock step here.
Just press 'Confirm and run' here. Once it's done, press continue here.
command: fastboot_unlock_critical
- type: confirm_button
content: >
Follow the instructions on the Fairphone screen. This command will wipe all the personal data on your phone.
- type: call_button
content: >
To finish the unlocking, the phone needs to reboot. Just press 'Confirm and run' here to reboot. Then continue.
Expand Down
5 changes: 5 additions & 0 deletions openandroidinstaller/tooling.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,11 @@ def fastboot_unlock(bin_path: Path) -> TerminalResponse:
for line in run_command("fastboot flashing unlock", bin_path):
yield line

@add_logging("Critically unlocking the device with fastboot without code.")
def fastboot_unlock_critical(bin_path: Path) -> TerminalResponse:
"""Unlock critical the device with fastboot and without code."""
for line in run_command("fastboot flashing unlock_critical", bin_path):
yield line

@add_logging("OEM unlocking the device with fastboot.")
def fastboot_oem_unlock(bin_path: Path) -> TerminalResponse:
Expand Down

0 comments on commit 1113cb8

Please sign in to comment.