To God be the glory, a working AOSP ROM for those on both the 50.1 and the 50.2 firmware, Pie flavored! There may still be a few bugs here and there, please read this entire post before using!
**** This is an UNOFFICIAL ROM. Install at your own risk! ****
WARNING: This build SHOULD work on both the H3213 and H3223, but I could only test on a H3223.
Disclaimer: I am not responsible for any damages to your device.
A huge thanks to the Android Open Source Project and Sony Open Devices Project!
The Sony Open Devices Project (SODP) is an initiative to build Android for phones while being as vendor binary large object (blob) free as possible. There are still a few vendor blobs used in this project, but the goal is to one day be vendor blob free. I don't know if that will ever fully happen, but it is nice to move in that direction. That said, all of my work is completely available for any who wish to use or modify it. I didn't make AOSP, the device trees, or vendor blobs. I simply used and edited existing material. A huge thanks should go to those who actually created this stuff.
This Unofficial AOSP ROM was built for the H3223 (discovery), but may work on some of the other variants, please try at your own risk. However, if you do try it on another variant, please be sure to let me know in the comments how well it worked.
Note: This is designed to work with any firmware version of the XA2 Ultra, because you flash a custom OEM partition. I've tested this on 50.1 and 50.2 firmware phones.
IF there is an ENG build, it is marked "ENG" for testing purposes only. It's your phone, you can install anything you want, but I do not recommend installing the ENG build. Use the "USER" or "USERDEBUG" builds.
There are two versions of the project, a vanilla AOSP without Google Apps, and a vanilla AOSP with Google Apps. I have tested both on my phone. If you want Google Apps, you cannot use the gappless version and then flash gapps, it doesn't work, you must use the gapps version if you want Google's apps.
Installation instructions: (DIFFERENT THAN NORMAL! DONE THROUGH FASTBOOT!)
- Download the zip file for AOSP 9.
- Unzip the zip file, and you will find 5 images.
- If using Windows, put these in your folder you use for fastboot, if using Linux, you can do this from any folder.
- Reboot the phone into bootloader/fastboot mode.
- Flash them to your phone, like so (example for Linux)
$ fastboot flash boot ./boot.img $ fastboot flash oem ./oem.img $ fastboot flash system ./system.img $ fastboot flash userdata ./userdata.img $ fastboot flash vendor ./vendor.img $ fastboot reboot
If you plan to install magisk, then let the rom boot once, then go back to TWRP and flash magisk. I recommend making a backup of at least the boot partition first. Magisk is optional, of course. And you do so at your own risk!
So far these things that I have tried work, such as - Display/touch - Camera (front and back) for pictures and video! - Phone calls - Data 3g/LTE - Bluetooth - WiFi - Sound in system, in calls, over bluetooth devices - MicroSD card (external SD card). - GPS - Fingerprint sensor - Camera Button launches camera and takes photos - MTP file transfer etc....
Gappless version: - FM Radio does not work - The built in Gallery app cannot play back recorded videos from camera. VLC or other apps work fine though. - Nothing else that I know of, but let me know if you find something! Gapps version: - FM Radio does not work - The built in Gallery cannot play back recorded videos from camera. VLC or other apps work fine though. --But the Google Photos app can. -The built in Google Camera app does not work, however, Open Camera, or other camera apps do. - Nothing else that I know of, but let me know if you find something!
Device, kernel, and vendor trees: https://github.com/sonyxperiadev
My GitLab: https://gitlab.com/alaskalinuxuser/
ROM OS Version: 9.0 Pie
ROM Kernel: Linux 4.9.194
Based On: Android Open Source Project
Last Updated 2019-10-24