FORUMS
Remove All Ads from XDA
OnePlus 6 Development Program

[GUIDE] How to flash Treble roms on OnePlus 6

915 posts
Thanks Meter: 2,050
 
By ProtoDeVNan0, Senior Member on 31st May 2018, 12:39 PM
Post Reply Email Thread
Hey guys! So, as You know, OP6 has Treble, but when You flash GSI's on it, it will take You to EDL mode instead. Why? Well.. because of A/B and VBMETA partition. So... how do we fix it? It's actually pretty simple! Follow the guide and You will be able to boot GSI roms on Your OP6

Note: Before You can flash any GSI, You have to unlock Your bootloader. To do that, simply type: fastboot oem unlock . Just remember that it will wipe Your data!

Important: Flash 5.1.6 or above before flashing v20. It looks like 5.1.6 fixed Treble problems. Files have been updated to: 5.1.7


Step 1: Download any GSI rom You want, in this guide I'll be using Phh Treble latest build: Phh Treble A/B v20 with GApps and SU
(Make sure to extract it before flashing. You can do that with 7zip)
Step 2: Download this zip. It contains stock VBMETA as well as stock boot image, just in case if Your device is rooted. Link: Treble OP6 Files 5.1.7
Step 3: Extract those files on Your desktop for example and open terminal/cmd in the same folder as Your files. (Before You can do that, You should download latest minimal ADB and Fastboot available here: ADB & Fastboot XDA Thread Link ) Now. Copy and paste those commands:


fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img
This command will let You boot non OOS roms, like Phh Treble or any other Treble GSI.

fastboot flash boot_a boot.img
fastboot flash boot_b boot.img
Those commands will flash stock non rooted boot image to both of Your boot partitions (Treble roms need slightly different root that's why we need to use stock boot image for now)

fastboot flash system_a system-arm64-ab-gapps-su.img
fastboot -w flash system_b system-arm64-ab-gapps-su.img
Okay, these commands will flash Phh GSI to both of Your partitions. The only difference is that second command will wipe Your data partition which is most likely required to have a bug free boot. So backup Your data before!

Aaand that's it! Enjoy Your new GSI rom.



Thanks to Dewang Rocker for making a tutorial video! Make sure to like and subscribe


And one more Thanks to @AxM2 for posting my guide on Github!
OnePlus 6 Treble Github Page



Q/A
Q: Does this method work for all GSI images?
Yes! It should work fine, as long as Your GSI supports A/B partitioning. Most Devs build A/B GSIs so no worries.
Q: Bugs?
Build v20:
Stock camera has problems with focus, but if You install OOS camera it works fine.
Notch is covering screen a little.
Q: I want to see some screenshots!


Credits:
Phhusson for Wonderful GSI!
FunkWizard for latest firmware!
@dylanneve1 for being an awesome friend and helping me with many of my projects.
OnePlus for OP6 and releasing updates that are actually useful!
James Muir for Pixel 2 Guide on Github.
Google for creating Treble for us.

The Following 30 Users Say Thank You to ProtoDeVNan0 For This Useful Post: [ View ] Gift ProtoDeVNan0 Ad-Free
 
 
31st May 2018, 01:17 PM |#2  
Senior Member
Flag Greater Noida
Thanks Meter: 79
 
More
Looks promising! Anyone tried and confirm that the roms boot?

And what does wiping of data partition means? Will that wipe the internal storage too? or just the "data" (The apps and stuff).
31st May 2018, 01:46 PM |#3  
Abaddon's Avatar
Senior Member
House Avernus
Thanks Meter: 912
 
Donate to Me
More
any idea what treble rom/s that has the feature of stretching third party apps to use 18:9/19:9 aspect ratio or whatever instead of it being cropped?
31st May 2018, 01:49 PM |#4  
ProtoDeVNan0's Avatar
OP Senior Member
Thanks Meter: 2,050
 
Donate to Me
More
Quote:
Originally Posted by Joyarup

Looks promising! Anyone tried and confirm that the roms boot?

And what does wiping of data partition means? Will that wipe the internal storage too? or just the "data" (The apps and stuff).

It does boot, tried the guide 3 times already just to make sure that it works. And -w will wipe Your internal storage, not just apps. So make sure to backup everything. Or You can just wipe data in TWRP and then boot GSI. This way Your internal storage won't be deleted. But a full backup is always recommended! Even if You flash new fonts or something .
The Following User Says Thank You to ProtoDeVNan0 For This Useful Post: [ View ] Gift ProtoDeVNan0 Ad-Free
31st May 2018, 01:52 PM |#5  
Senior Member
Flag Greater Noida
Thanks Meter: 79
 
More
Quote:
Originally Posted by ProtoDeVNan0

It does boot, tried the guide 3 times already just to make sure that it works. And -w will wipe Your internal storage, not just apps. So make sure to backup everything. Or You can just wipe data in TWRP and then boot GSI. This way Your internal storage won't be deleted. But a full backup is always recommended! Even if You flash new fonts or something .

Alright thank you for clearing things, I will give it a try and will let you know!
Thank you for your work.
31st May 2018, 02:03 PM |#6  
Member
Thanks Meter: 13
 
More
I get unknown option when running the fastboot --disable-verity command
31st May 2018, 02:04 PM |#7  
Senior Member
Flag Greater Noida
Thanks Meter: 79
 
More
Quote:
Originally Posted by eminem5055

I get unknown option when running the fastboot --disable-verity command

Make sure the drivers and adb and fastboot is installed and your command line is in the exact location as your fastboot.
31st May 2018, 02:07 PM |#8  
Member
Thanks Meter: 13
 
More
Quote:
Originally Posted by Joyarup

Make sure the drivers and adb and fastboot is installed and your command line is in the exact location as your fastboot.

That worked thanks!
31st May 2018, 02:08 PM |#9  
ProtoDeVNan0's Avatar
OP Senior Member
Thanks Meter: 2,050
 
Donate to Me
More
Quote:
Originally Posted by Abaddon

any idea what treble rom/s that has the feature of stretching third party apps to use 18:9/19:9 aspect ratio or whatever instead of it being cropped?

No idea if any rom has settings for 18:9/19:9 displays. But there's also the notch that covers the screen. In OOS we can hide the notch, but in Treble roms the notch will cover some parts of the screen in all apps. YouTube should support 18:9/19:9 though. Maybe there is some app that can help with the notch? Or some Magisk module? I think that GravityBox should allow us to resize status bar so that apps won't be covered, but games hide the status bar so it will be useless in games. We might have to wait for Android P to take care of all the notch problems in GSIs.
The Following User Says Thank You to ProtoDeVNan0 For This Useful Post: [ View ] Gift ProtoDeVNan0 Ad-Free
31st May 2018, 02:13 PM |#10  
Nick502's Avatar
Senior Member
Thanks Meter: 445
 
More
Thank you for this!!
How is the camera on treble roms?
31st May 2018, 02:34 PM |#11  
Hitman478™'s Avatar
Senior Member
Flag Mother Base
Thanks Meter: 272
 
Donate to Me
More
I think we need to wait P for notch support, or maybe some modders can do something
Post Reply Subscribe to Thread

Tags
oneplus, op6, phh, treble

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread