[ROM][Treble][microG]LineageOS 16.0 for HUAWEI P9

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
hi, I installed this rom but the phone goes into bootloop. reflash emui 8 original and tried again and bootloop: any ideas?
My P9 EVA-L09 rebranded to AL10
No real idea, but just to make sure: With your Stock EMUI 8.0 all fine? You also flashed the regional modem and AOSP keyboard, but no further Google stuff? So your Stock O works as it should? And you did not flash anything else? And, IMPORTANT, before flashing this build, you got rid of TWRP and flashed back the stock recovery?
EDIT: And of course, you wiped the data partition (factory reset) via Stock recovery?
 
Last edited:

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
I'm also using a P9 EVA-L09 rebranded to AL10.
On my phone the bluetooth connection works fine and if a device is connected, the BT icon also appears in the status bar.
But I can confirm, that there is no bluetooth icon in the status bar, when bluetooth is enabled, but no device is connected.
BT: The behavior is the same on my device as with e.g. my OP3T (no treble build! Also Lineage 16.0): When no BT device connected, no BT symbol in status bar, but when you swipe down, you see BT enabled icon.
Only observation, I can confirm is, that the initial device name appeared as "hello"
 
  • Like
Reactions: interprises

interprises

Member
Mar 17, 2009
28
3
0
Vicenza
No real idea, but just to make sure: With your Stock EMUI 8.0 all fine? You also flashed the regional modem and AOSP keyboard, but no further Google stuff? So your Stock O works as it should? And you did not flash anything else? And, IMPORTANT, before flashing this build, you got rid of TWRP and flashed back the stock recovery?
EDIT: And of course, you wiped the data partition (factory reset) via Stock recovery?
all yes but no replace the original recovery: proceed immediately, tks
 

interprises

Member
Mar 17, 2009
28
3
0
Vicenza
No real idea, but just to make sure: With your Stock EMUI 8.0 all fine? You also flashed the regional modem and AOSP keyboard, but no further Google stuff? So your Stock O works as it should? And you did not flash anything else? And, IMPORTANT, before flashing this build, you got rid of TWRP and flashed back the stock recovery?
EDIT: And of course, you wiped the data partition (factory reset) via Stock recovery?
To avoid misunderstanding: DO NOT replace original recovery, in the contrary - during the rebrand journey, as described in the linked thread, you had to temporarily use TWRP, so you need to GET BACK to original recovery
works perfectly, thanks !!!
 
  • Like
Reactions: MSe1969

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
ROM Status info

In my 4th post (title: "Further tips & tricks"), I have created two new sections.
One to indicate other devices than the Huawei P9, for which this build is reported to work as well, and another one to indicate reported and observed issues with this build and any progress on fixing them (if I am able to reproduce on my device).
Thanks so far for all your feedback!
 

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
New build with April 2020 Sec. patches

Hi all,
a new build with April 2020 Sec. patches is available for download here.

If you have already my previous build (with the March Sec. patch) on your phone, simply unzip the .img file, reboot into fastboot mode and flash it via the command
Code:
fastboot flash system treble_arm64_a_lineage16_20200408_system.img
Please note: On some computers, you may need to run fastboot as admin (Windows) or root/sudo (Linux)
Afterwards, simply reboot - no wipe of any kind required.

If you come from a different ROM or even Stock ROM, please carefully follow the instructions in the OP of this thread!
(If you don't, you have been warned.)

This is only the ASB patches, other reported issues have not been addressed, yet.
Happy flashing - regards, M.
 

dr4rzz

New member
Nov 13, 2019
4
2
0
Current Issues (reported and/or observed by myself)
...
4. Headphone issues (1)
(Physical, no BT) headphone put in headphone jack
  • Observed by: myself
  • Issue: Testing sound volumes in Settings app => all fine. But playing audio / video files or streams only plays good sound for less than 0,5 seconds, afterwards it seems that only the high frequency sounds (treble) are audible, whilst medium and bass is hardly audible.
  • Will be grateful for any hint - does that also happen to you?
I could reproduce this headphones issue with the high-frequency sounds when playing music or videos.

Here is a workaround, that fixed it for me:
put headphones in headphone jack -> open AudioFX app -> turn the bass control to 0% or turn AudioFX off completely
 
  • Like
Reactions: MSe1969

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
I could reproduce this headphones issue with the high-frequency sounds when playing music or videos.

Here is a workaround, that fixed it for me:
put headphones in headphone jack -> open AudioFX app -> turn the bass control to 0% or turn AudioFX off completely
Thanks - that does the trick and good enough for a work-around - will update the section accordingly.
 

Wattsensi

Senior Member
May 13, 2018
221
34
0
Talca
Hey, @MSe1969, turns out I misdiagnosed the Bluetooth issue. It is possible to pair, send, receive and use BT audio despite the icon not being present and the chip named hello. Sorry for the confusion!
 
  • Like
Reactions: MSe1969

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
Updated build

Hi all,
just realized, that in my previous build with April 2020 sec. patches (file treble_arm64_a_lineage16_20200408_system.img), two ASB commits were missing in the 'lin-16.0-treble' branch. So I have fixed that and created a new build here - you will not notice any difference in behavior/features, but with the linked build has all the platform security patches. Sorry for any inconvenience.
Regards, M.
 

Mywayorthehuawei

New member
May 5, 2020
2
2
0
:good:

Works well quick and clean, one thing I've noticed on mine is wifi hotspot doesn't work when you click on enable it auto turns the slider button back off and displays error under the menu heading.
Bluetooth and usb tether works fine.

Only other thing i'm missing is option to force lte only so it doesn't hop back and forth to 3g when signal strength differs - not that important just nice to have.
 
  • Like
Reactions: MSe1969

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
:good:

Works well quick and clean, one thing I've noticed on mine is wifi hotspot doesn't work when you click on enable it auto turns the slider button back off and displays error under the menu heading.
Bluetooth and usb tether works fine.

Only other thing i'm missing is option to force lte only so it doesn't hop back and forth to 3g when signal strength differs - not that important just nice to have.
I can confirm the WiFi hotspot issue on my phone as well. Will try to investigate.
Regarding "LTE only", have you tried already the special menu, when you dial *#*#4636#*#* (*#*#INFO#*#*)?
 

mqb61a

Member
Jan 16, 2017
8
1
0
This was asked probably a bunch of times already, but.. is there a possibility to install the stock Huawei Camera on this ROM?

Also, I'm sometimes experiencing a small FPS lag, like when I'm sending a text, or just scrolling through Settings or any other app. This issue occurs only on this ROM.
 

RogerR2

Member
May 4, 2020
11
0
0
Initial thoughts

Huawei P9 EVA-AL00 (2 x SIM model)

Hi, the interface looks great, thanks!

In the phone I have an SD and a SIM. The SD is recognized, but not the SIM, so no calls possible (so I will have to revert to stock pretty quickly :().

Also, the microphone is not working (nor with a headset), and like others the WiFi hotspot isn't working.

Thanks again
 

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
Huawei P9 EVA-AL00 (2 x SIM model)

Hi, the interface looks great, thanks!

In the phone I have an SD and a SIM. The SD is recognized, but not the SIM, so no calls possible (so I will have to revert to stock pretty quickly :().

Also, the microphone is not working (nor with a headset), and like others the WiFi hotspot isn't working.

Thanks again
I'm not sure I got your point properly.
I assume you have rebranded your device following the step sequence in the linked thread to "become" an AL00 (Chinese) as a prerequisite to upgrade to EMUI 8.0. After you did so, the thread explains to also flash a specific patch to re-enable SIM recognition for your region.
Did you do that? The prerequisite to flash this (and also any other treble) build is, that the "rebranded stock" Oreo EMUI 8.0 works properly in all aspects.

Or are you really saying, that your "patched Chinese Stock Oreo EMUI 8.0" works fine and only my build does not recognize your SIM?
 

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
This was asked probably a bunch of times already, but.. is there a possibility to install the stock Huawei Camera on this ROM?

Also, I'm sometimes experiencing a small FPS lag, like when I'm sending a text, or just scrolling through Settings or any other app. This issue occurs only on this ROM.
To your 1st question: What would be the benefit of doing so? In the Openkirin TG support channel, one of the issues is that the Huawei Cam, which is an Oreo system app, tries to access the external SD the "Oreo-way", which does not work any longer in Pie for example.
To your 2nd point: Is there any way to explicitly reproduce the lag or can you produce a log?
 

RogerR2

Member
May 4, 2020
11
0
0
I'm not sure I got your point properly.
I assume you have rebranded your device following the step sequence in the linked thread to "become" an AL00 (Chinese) as a prerequisite to upgrade to EMUI 8.0. After you did so, the thread explains to also flash a specific patch to re-enable SIM recognition for your region.
Did you do that? The prerequisite to flash this (and also any other treble) build is, that the "rebranded stock" Oreo EMUI 8.0 works properly in all aspects.

Or are you really saying, that your "patched Chinese Stock Oreo EMUI 8.0" works fine and only my build does not recognize your SIM?
Hi, it's an original Chinese phone. I flashed the ROM with EMUI 8.0.0, build number EVA-AL00 8.0.0.550, but without the final patch (C00patch02) from Huawei. I have now reverted back to stock (with the final patch). If I get time, I will try again and see what happens.
 

Mywayorthehuawei

New member
May 5, 2020
2
2
0
Been trying to look into the hotspot problem more (I don't have any experience on roms or android other than using stock just started looking at and installing this last week so this may be obvious stuff or completely wrong :silly:)

Logcat:

05-04 13:39:56.774 5163 5163 D WifiTetherSsidPref: Updating SSID in Preference, ANYWIFI
05-04 13:39:56.776 5163 5555 D SharedPreferencesLogger: Tried to log string preference wifi.tether.WifiTetherSettings/wifi_tether_network_name = ANYWIFI
05-04 13:39:56.780 5163 5163 D WifiTetherApBandPref: 5Ghz not supported, updating band index to 0
05-04 13:39:56.782 5163 5163 D WifiTetherSettings: updating display config due to receiving broadcast action android.net.wifi.WIFI_AP_STATE_CHANGED
05-04 13:39:56.784 5163 5163 D WifiTetherSsidPref: Updating SSID in Preference, ANYWIFI
05-04 13:39:56.787 5163 5554 D SharedPreferencesLogger: Tried to log string preference wifi.tether.WifiTetherSettings/wifi_tether_network_name = ANYWIFI
05-04 13:39:56.791 5163 5163 D WifiTetherApBandPref: 5Ghz not supported, updating band index to 0
05-04 13:39:57.303 5163 5184 W libEGL : EGLNativeWindowType 0x70588d9010 disconnect failed
05-04 13:39:57.312 5163 5163 V WifiManager: unregisterSoftApCallback: call[email protected]3382ffa
05-04 13:39:57.423 802 802 I aptouch_daemon: filter_touch_detect, down, in: 1, out: 1
05-04 13:39:57.480 802 802 I aptouch_daemon: filter_touch_detect, all_touch_up
05-04 13:39:57.485 5163 5163 I ConnectivityManager: startTethering caller:com.android.settings
05-04 13:39:57.492 770 770 E WifiHAL : Enter init_wifi_vendor_hal_func_table
05-04 13:39:57.492 770 770 I [email protected]: Wifi HAL started
05-04 13:39:57.510 770 770 I : get_fw_path_from_dt, dt_file=/proc/device-tree/bcm_wifi/wifi_fw_ap_name, fw_path: /vendor/firmware/fw_bcm43455_apsta_hw.bin
05-04 13:39:57.511 770 770 D : hwwifi_change_fw_path, fw_path: write /vendor/firmware/fw_bcm43455_apsta_hw.bin to /sys/module/bcmdhd/parameters/firmware_path
05-04 13:39:58.121 770 770 I WifiHAL : Initializing wifi
05-04 13:39:58.122 770 770 I WifiHAL : Creating socket
05-04 13:39:58.125 770 770 I WifiHAL : Initialized Wifi HAL Successfully; vendor cmd = 103
05-04 13:39:58.130 770 770 E hw-IPCThreadState: binder thread pool (1 threads) starved for 623 ms
05-04 13:39:58.167 1736 1736 E wificond: No usable interface found
05-04 13:39:58.264 770 5635 E WifiHAL : wifi_event_loop: Read after POLL returned 4, error no = 0 (Success)
05-04 13:39:58.264 770 5635 D WifiHAL : Got a signal to exit!!!
05-04 13:39:58.264 770 5635 I WifiHAL : Exit wifi_event_loop
05-04 13:39:58.265 770 770 E WifiHAL : wifi_cleanup: Read after POLL returned 4, error no = 13 (Permission denied)
05-04 13:39:58.265 770 770 E WifiHAL : Event processing terminated
05-04 13:39:58.265 770 770 I WifiHAL : Internal cleanup completed

Looks like its falling over at the wificond: No usable interface found (Wifi manager) I'm not sure if it means the wifi manager (wificond) can't get the info it needs from the wifidriver - but normal wifi connections work fine so unlikely? Or something else I noticed is if you go into access point names(APN) you have your default carrier apn and another called hotspot: the hotspot one is greyed out as if disabled and can't be edited but has dun in the apn type.
From what I can see online dun is a way to emulate a modem and a way to set up tethering that would bypass carrier tethering blocks. Saw something online that google was allowing the carrier to specify what apn types are user configurable and what is disabled such as dun.

"dun

Indicates the current APN configuration may be used for Dial-Up Networking connections. This refers to an outdated method for using your phone to emulate a dial-up modem and is not the way that modern smartphones do tethering anymore. There should be no need to use this value."


You can create a new APN and put all the details in and set apn type as dun and when you save you get the message operator does not allow adding APNs of type dun. Could it be that when you start the hotspot the wifi manager is attempting to use the disabled hotspot dun APN? (Tethering works on stock rom or other devices just to confirm my carrier allows it)

Also the bundled app net monitor tries to load and fails for me everytime - can anyone confirm it is the same for them?


I'm thinking along this kind of idea

/system/etc/apns-conf.xml

Orginal:

<apn carrier="3"
mcc="234"
mnc="20"
apn="three.co.uk"
mmsc="ttp://mms.um.three.co.uk:10021/mmsc"
mmsproxy="mms.three.co.uk"
mmsport="8799"
type="default,supl,mms"
/>

<apn carrier="3 Hotspot"
mcc="234"
mnc="20"
apn="3hotspot"
authtype="0"
type="dun"
/>


Change to:


<apn carrier="3"
mcc="234"
mnc="20"
apn="three.co.uk"
mmsc="ttp://mms.um.three.co.uk:10021/mmsc"
mmsproxy="mms.three.co.uk"
mmsport="8799"
type="default,supl,mms,dun"
/>

and delete the hotspot apn

(H is missing from mmsc - blocked from posting links until 10 posts)


Edit: Updated orginal prefered APN with dun and made no difference :(
 
Last edited:
  • Like
Reactions: MSe1969

MSe1969

Senior Member
Dec 16, 2016
1,411
2,575
133
Frankfurt Rhine-Main metropolitan region
Been trying to look into the hotspot problem more (I don't have any experience on roms or android other than using stock just started looking at and installing this last week so this may be obvious stuff or completely wrong :silly:)

Logcat:
. . .

Also the bundled app net monitor tries to load and fails for me everytime - can anyone confirm it is the same for them?
Thanks for providing the log and starting to looking at it - hope to find a solution soon.
Thanks also for the netmonitor feedback, that one will be fixed in my next build.
 
  • Like
Reactions: Mywayorthehuawei