iodéOS for Fairphone 4?

@RiverOak
OK, just a last thought, idea, and maybe good, not sure. But it cannot damage anything…

  • Install the version 220405 but do NOT relock the bootloader.
  • After you have flashed the image via sideload, reboot into the system (after step 15) )
  • Do initial setup
  • Do the update to the newest version via the updater. (Maybe you first have to install new updater: UpdaterBetaIode2Vx.apk )
  • In that case you can be sure that both slots are flashed with the iodé system.
  • enable developer settings
  • check then again in developer settings if “allow OEM unlocking” is enabled.
  • Only then boot into bootloader mode and check point 17) if the get_unlock_ability is 1
  • Only then relock your bootloader! Step 17) + 18)

You should have then a working inodé system 2.4

If you want you can then upgrade to iodé 3.0
By means, you have only to sideload the 3.0 image in recovery mode (dirty, without a reset of data). Reboot, That’s all.
To get Updates in iodé 3.0 you have to install the beta 3.0 updater from here: UpdaterBetaIode3V1

actual guide:

  1. remove SIM card and check that akku has at least 50%
  2. eneable USB Debugging and “Allow unlock OEM” in Developer Options
  3. check if adb is working and device is recognized correctly =>adb devices => ACK USB debugging on phone-screen. check box: always trust
  4. adb reboot bootloader
  5. check if fastboot is working and device is recognized correctly =>fastboot devices
  6. fastboot flashing unlock => Acknowledge unlocking on phone (VOLUME UP + POWER) Device is doing a factory reset and reboots to system
  7. start again in bootloader => switch phone off. pull out USB cable. press Volume (-) and put in USB cable in. Keep Volume (-) pressed. Phone should start in bootloader. (¹)
  8. check if fastboot is working and device is recognized correctly =>fastboot devices
  9. fastboot flash recovery_a iode-2.4-20220405-FP4-recovery.img
  10. fastboot flash recovery_b iode-2.4-20220405-FP4-recovery.img
  11. fastboot erase avb_custom_key
  12. fastboot flash avb_custom_key avb_custom_key-FP4.bin
  13. press VOLUME UP until see message reboot in recovery. Then POWER
  14. From recovery => Factory reset => Format Data/factory reset
  15. From recovery => Apply update => Apply from ADB =>adb sideload iode-2.4-20220405-FP4.zip
  16. back to bootloader mode. From recovery => Advanced => reboot to bootloader
  17. check if bootloader unlock ability is possible =>fastboot flashing get_unlock_ability → (bootloader) get_unlock_ability: 1 ==> if you get 1 then follow with step 18) otherwise do not lock bootloader (can brick your phone) and follow with step 19)
  18. fastboot flashing lock
  19. reboot system. First should see a Lineage screen doing a wipe. After a second (automatic) boot you should see the yellow boot screen and then the iode bootscreen.
  20. start setup wizard

(¹) From FP Support Page:
Alternatively, you can disconnect the USB cable, turn off your Fairphone, then connect the cable and hold the volume down button. After a few seconds, you’ll see the fastboot mode

2 Likes

I was able to get everything working properly on my second try. No idea what I did wrong the first time though. Thanks again for all the documentation.

1 Like

Hi everyone,

I had iodeOS 2.4 20220407 go into a bootloop when doing fastboot flashing lock as per the official instructions on the iodeOS website and GitHub. Switching from slot b to slot a has allowed me to boot back into a working iodeOS install.

I now want to sort everything out and lock down the bootloader. I have a couple of questions right off the bat:

Can I achieve the same outcome as @FairphoneHulk’s procedure above (i.e. being sure that both slots are flashed with the iodé system) simply by waiting patiently for an OTA update to arrive via the stock updater?

I flashed the custom key as part of the official installation instructions (and didn’t receiver any errors), but now I have no idea where that key went (to which slot) and if it’s still there.

Is it safe to do fastboot erase avb_custom_key and fastboot flash avb_custom_key avb_custom_key-FP4.bin now? Should I do it on both slots, or just the current, working one? Should I do it at all? (Can I check if the key is in place?)

The official instructions had me do fastboot flashing unlock_criticalbut then there’s no mention of doing fastboot flashing lock_critical afterwards. Is this command safe to run under the same conditions as fastboot flashing lock (i.e. (bootloader) get_unlock_ability: 1)?

I’m hesitant to set everything up on my phone until I know that I won’t have to wipe data in the near future. From what little I’ve seen, iodeOS is awesome and I can’t wait to settle in!

No need to wait for an ota to flash both slots : you can simply change the active slot with fastboot after flashing the first one, or simply by rebooting the rom (the active slot should change after a successful boot) and reflash the same rom.
The key is not an a/b partition, must be flashed once, and forgotten. No need, I think, to erase the partition and flash it again. And no simple way to ensure it has been correctly flashed. If everything looked good when flashing it, you can suppose it has succeeded.
Yes, if you unlocked critical partitions, you must lock them again, and the same condition applies ( get_unlock_ability: 1).
As long as get_unlock_ability is 1, you’ll be able to unlock the bootloader if something goes wrong.

Thank you, @vince31fr, that’s really helpful.

I’m currently running off slot a with a bootlooping/unbootable slot b. Does that mean I can just switch to slot b and ADB sideload the iodeOS *.zip again? Given the build is the same, it then won’t matter which slot is current until an OTA update comes through (and gets applied to the non-current slot)?

And when it comes to relocking the bootloader. The instructions had me first unlock and then unlock_critical - should I now lock_critical first and then lock? Does the order matter? I’ll check unlock_ability at each step, of course.

Please forgive the naive questions, I’ve never worked with a/b partitions or a lockable bootloader before.

No : sideload in the working slot a, next reboot will be made on the newly flashed slot b. And yes no matter the booted slot then. About the relocking order, I have no idea if order matters. I did not observe a difference, but never had such bootloop problems on my device.

Flashing slot b went smoothly, the system booted into it on restart. Locking the criticals also went well.

But when I tried to lock the bootloader, I got the “your device is corrupted and will not boot” message and got stuck in fastboot mode. Following @FairphoneHulk’s instructions from a related thread, I unlocked the bootloader and tried reinstalling from scratch. I flashed the recovery.img to both slots and flashed the custom key, but I’m still stuck in the bootloader.

Volume up + power, fastboot reboot recovery and selecting recovery from the bootloader menu all bring me back to the bootloader menu.

Please, if anyone knows a way out of this, I’ll be very grateful.

EDIT 1: It’s OK, changing the current slot got me back into iodeOS. I’ll try sideloading the iodeOS *.zip from this slot.

EDIT 2: Sideload ends with the following error in the terminal (no errors in recovery screen):

serving: ‘iode-2.4-20220407-FP4.zip’ (~94%) adb: failed to read command: Success

The phone booted off the previously corrupt slot. I did a dirty flash, so all settings were retained.

So I definitely have one of these un-relockable phones, whether it’s a HW or FW thing, something is different in these newer batches. I bought my phone only a week or so ago. It’s a shame I can’t lock this phone down.

Thank you, @vince31fr, for your help.

Thank you for this well written instruction, but i will be daring to ask, maybe someone would be willing to film a step-by-step video of rebooting and installing iode 3.0? I am afraid to brick my phone, as i have very litlle programming experience.

Thank you @FairphoneHulk for these very clear instructions that allowed me to flash Iode3.0 beta. ( I haven’t lock the bootloader for the moment, I’ll see if it’s less risky in a few months, during my next reinstallation :sweat_smile:)

1 Like

@Pierre_l
Have you ever unlocked the critical partitions, as described in the fairphone unlock guide?

Unlock with fastboot flashing unlock_critical ?
I don’t think so, I switched directly from FairphoneOS to IodéOS2 at the beginning of february, then to IodéOS3 yesterday.
I saw that this command is used in the installation instructions of /e/OS, but if I remember correctly it was never necessary for IodéOS.

Yes, that’s right.
In that case and as long as get_unlock_ability is 1 you should be able to relock your bootloader

1 Like

Is it save to installiert iodé 3 OTA for a

  • iode 2.4 (04-07-2022)
  • with locked bootloader
  • (the avb key was flashed along 2.4)

The changelog on the github release is a little frightning

No problem. I did it that way. Just sideload the zip in recovery without wiping the data.
No problems at all. Everything’s running fine.

Just two things if you update to 3.0 that way:

First
You have to clear cache and data in bluetooth app after first start in 3.0. Otherwise if will crash permanently.
Settings/apps/ - show system apps - bluetooth apps

Second
Enable developer settings
Enable “deactivate bluetooth a2dp hardware offload”
Reboot
Otherwise bluetooth audio is not clear

2 Likes

And using the updater is not recommendet?

Why are such informations not documented in the changelog?

You can also use the updater

Maybe you still have to do the two steps. Happen only on updating from 2.4 to 3.0.
Not if installing from scratch

Using the updater worked flawless. But i also needet to clear the cache oft the Bluetooth service

1 Like

Hi,

At the weekend I updated my FP4 from iodeOS V2.5 to V3 Over the Air (OTA) with no issues. All my data was intact, only the bluetooth cache needed to be cleared to enable bluetooth. The only extra work was ensuring I backed up my SD Card as Android 12 insists on reformatting my SD Card before I can use it. (I have reposted this on the Fairphone forum too)

Nice work iode team, thank you

1 Like

A quick update on the iodéOS updater:

Updated Over the Air (OTA) from V3.0 to V3.1. No data loss, no issues seen so far, smooth update. Used WiFi to download. Biggest imeadiate improvement, which may be a placebo, was the perceived improvement of the quality of the pictures using the Open Camera app.