Skip to content

Pocketnet phone setup instructions #9

@lostystyg

Description

@lostystyg

Pocketnet phone setup (Oneplus 9)

Note

This instructions are based on lineageos original instructions, so for detailed explanation you can visit their site

Prerequisites

  • A PC with installed adb and fastboot (version 31.0.2 of newer) tools
  • Downloaded official Android 13 latest ROM for Oneplus 9 (Will be used to update phone's firmware still Oneplus 9 is distributed with Android 11).
    • Option 1: use OxygenUpdater app to download ROM and copy it to PC (only once)
    • Option 2: download rom directly from Oneplus site, however it is recommended (by LineageOS authors) to use option 1.
  • Installed payload-dumper (e.x. this one. It will be used to extract firmware from official ROM.

Unlock bootloader

  • Boot up the phone
  • Proceed the setup untill one can access settings
  • Enable developer mode in settings
    • Navigate to About Phone and touch 7 times on Build number
  • Connect the phone to a PC
  • Allow usb debugging on the phone (a pop up should appear)
  • Open adb console on PC and write adb reboot bootloader
  • Open fastboot console on PC and write fastboot oem unlock
  • Follow instructions on the phone (use volume keys to navigate and power button to click)

Installing recovery partitions

  • Hold Volume Up + Volume Down + Power buttons to access bootloader
  • Download vendor_boot.img and dtbo.img from [here[(https://download.lineageos.org/devices/lemonade/builds)
  • Exec in fastboot concole:
fastboot flash dtbo <dtbo>.img
fastboot flash vendor_boot <vendor_boot>.img

TODO: the boot partition can be either a patched boot with magisk, that is distributed by pocketnet, or a general lineageos-microg boot image. If patching boot image allow to fully install magisk on the phone (without further full installation in Magisk app) then the first option should be used.

  • Exec fastboot flash boot <boot_filename>.img in fastboot console.
  • Exec fastboot reboot recovery in fastboot console.

TODO: seems like OnePlus 9 out of stock has Android 11 firmware and it is not supported by lineage 0.20 recovery. Possible workaround: performing firmware update steps using lineage 19 recovery and only after that install the latest recovery.

Updating firmware

LineageOS requries the latest Android 13 firmware installed. This can be achieved by sequential installation of OTA updates from stock rom but this will require a lot of time. So direct downloading of latest stock ROM full package and extracting necessary partitions from it is peferred.
Considered the full stock ROM had been already downloaded from OxygenUpdater or from official Oneplus website and payload-dumper-go installed.

  • Unzip the ROM file. There should be a payload.bin file.
  • Exec <path_to>payload_dumper-go -o <output_dir> payload.bin. This will extract all necessary files to output_dir.
  • Go to output_dir.
  • Sequentically execute all commands below:
fastboot flash --slot=all abl abl.img
fastboot flash --slot=all aop aop.img
fastboot flash --slot=all bluetooth bluetooth.img
fastboot flash --slot=all cpucp cpucp.img
fastboot flash --slot=all devcfg devcfg.img
fastboot flash --slot=all dsp dsp.img
fastboot flash --slot=all engineering_cdt engineering_cdt.img
fastboot flash --slot=all featenabler featenabler.img
fastboot flash --slot=all hyp hyp.img
fastboot flash --slot=all imagefv imagefv.img
fastboot flash --slot=all keymaster keymaster.img
fastboot flash --slot=all modem modem.img
fastboot flash --slot=all multiimgoem multiimgoem.img
fastboot flash --slot=all oplus_sec oplus_sec.img
fastboot flash --slot=all oplusstanvbk oplusstanvbk.img
fastboot flash --slot=all qupfw qupfw.img
fastboot flash --slot=all qweslicstore qweslicstore.img
fastboot flash --slot=all shrm shrm.img
fastboot flash --slot=all splash splash.img
fastboot flash --slot=all tz tz.img
fastboot flash --slot=all uefisecapp uefisecapp.img
fastboot flash --slot=all vm-bootsys vm-bootsys.img
fastboot flash --slot=all xbl_config xbl_config.img
fastboot flash --slot=all xbl xbl.img

Installing LineageOS MicroG

  • Download the latest ROM from official microg site. Use version 20.*.
  • Connect the phone to a PC
  • Reboot the phone to recovery (enter bootloader and exec fastboot reboot recovery)
  • Perform a Factory Reset
  • Go back and select Apply update, then Apply from ADB.
  • On PC exec adb sideload <path_to_downloaded_microg_rom>.zip
  • Go back and select Advanced -> Reboot to recovery
  • Select Apply update -> Apply from ADB.
  • On PC exec adb sideload <path_to_magisk>.zip to install Magist (root).
  • Click continue if Signature verification error occurred. It is ok still LineageOS recovery do not contain Magisk signature keys.

Post installation

  • Boot the phone (if you are in the recovery select Reboot system now).
  • Wait for the startup screen to appear but do not proceed the initial setup.
  • Connect the phone to PC and allow the USB debugging via ADB on the phone.
  • Install all pocketnet-distribution apps by executing adb install <app_name>.apk
  • List of apps to be installed

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions