[Sony Xperia XZ2 ROMs, Kernels, Recoveries, & Other] MartinX3:
The Sony Open Devices Project is always happy about volunteers (coding, testing, etc) :)

Also mainlining your favorite snapdragon powered xperia device into the mainline kernel is possible and we will be glad to help you!

Official site

Unofficial site

#include <std_disclaimer.h>
/*
*
* We are not responsible for bricked devices, dead SD cards,
* thermonuclear war, or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this ROM
* before flashing it! YOU are choosing to make these modifications, and if
* you point the finger at us for messing up your device, we will laugh at you.
*
*/

This is the AOSP ROM for the Sony Xperia XZ2 (akari), XZ2C (apollo) and XZ3 (akatsuki)

This ROM build will always mainly based on Sony AOSP Code and maybe include cherry-picks.

I plan to make monthly builds, after a new security patch level and the OEM binary got fully implemented, if there is no need for a critical hotfix.

Preview Picures:

https://xdaforums.com/showpost.php?p=77635765&postcount=2

https://xdaforums.com/showpost.php?p=78870686&postcount=436

https://xdaforums.com/showpost.php?p=79450390&postcount=619

https://xdaforums.com/showpost.php?p=79460850&postcount=624

FAQ:

Switch the A/B slot for every monthly release to make sure you execute the same amount of write cycles on the entire flash storage. (Extends hardware lifetime) Bootloader issue needs to get fixed to make custom roms bootable on slot B.

fastboot & adb

https://developer.sony.com/develop/open-devices/get-started/flash-tool/useful-key-combinations/

https://wiki.lineageos.org/adb_fastboot_guide.html

https://developer.android.com/studio/releases/platform-tools

Stuck at SONY logo? Maybe you need to flash the OEM binary to oem_a and oem_b, while just oem is not enough.

For a complete security patch you have to install the newest stock firmware and boot it once.

https://github.com/sonyxperiadev/bug_tracker/issues/258#issuecomment-445816826

TL;DR Flash the latest stockfirmware, boot it once, to update your baseband/mobile network drivers and then flash this ROM.

(I prefer and support only newflasher from XDA and xperifirm to download the firmware.)

Maybe this helps windows users:

https://developer.sony.com/posts/flash-tool-updated-with-new-feature/

Known Bugs:

Camera is under development.

[TAMA] [AKATSUKI] [CRITICAL??] Speakers clipping and distortion

Bugreport:

A bugreport needs logcat, dmesg and a way to reproduce the issue.

A crash of the system requires the content of the /sys/fs/pstore folder as bug report

Be aware that a second reboot erases this folder

A crash to the recovery partition requires additionally the content of the /dev/block/by-name/misc partition

You get the content via `cat /dev/block/by-name/misc partition > /path/to/output/file.txt`

To rescue a not responding phone:

VOLUP+POWER for 3 Seconds -> RESTART with one Vibration.

VOLUP+POWER for 20 Seconds -> SHUTDOWN with 3 Vibrations.

VOLUP+POWER+CAMERA for 30 Seconds -> HARDWARE SHUTDOWN by discharging a capacitor.

Thank you very much for your help, code contribution & testing! (Random order):

@jerpelea, the sony employees and their volunteers (people like you and me) coding this wonderful piece of software

@nasko_spasko

@laoli0913

@twistedddx

@dhacke thank your for providing a download server

And many thanks to the few donators! :)

A telegram group for technical SODP stuff:

Sony Open Devices Project Chat for devs

https://developer.sony.com/develop/open-devices	OEM binaries:	@SMDW_downloads	Bug Tracker:	https://github.com/sonyxperiadev/bug_tracker	This group is only for dev stuff.	For support: https://t.me/xdadevelopershub

t.me

XDA:DevDB Information

AOSP, ROM for the Xperia XZ2

Contributors

MartinX3, Sony

Source Code: https://github.com/SonyAosp

ROM OS Version: 9.x Pie

ROM Kernel: Linux 4.x

ROM Firmware Required: Latest Stock Firmware

Based On: AOSP

Version Information

Status: No Longer Updated

Current Stable Version: 9

Stable Release Date: 2019-08-08

Created 2018-09-16

Last Updated 2020-10-23