sonyxperiadev / bug_tracker

Empty repository that is used as a bugtracker for Open Devices project
52 stars 13 forks source link

[Tama] [XZ2] Problem with charging on custom roms #703

Closed DesantBucie closed 3 years ago

DesantBucie commented 3 years ago

Platform: Tama Device: Xperia XZ2 H8266 Kernel version: 4.9, 4.14 Android version: 10, 11 Software binaries version: stock and newer

Previously working on Charging works perfectly fine on stock android and worked on IodeOS until build 20210306(according to my xda comment, i will try to flash version before it soon and check it).

Description Phone charges flawlessly on stock firmware, but will have charging problems on some custom roms.

Symptoms Phone stops charging on custom ROMs (Lineage 18.1, 17.1, AOSP11)

Additional context I'm using apple macbook charger, but i tried this on samsung one and didn't work either. I don't have sony stock charger. I'm reporting it now as i went back to stock like 3 times, and stock has no problems with charging, and i thought that maybe it was my usb socket problem.

General rule is the longer the custom rom is installed the poorer it will charge, newly flashed can be easy to charge, few weeks later it's almost impossible. The phone will randomly stop charging.

MartinX3 commented 3 years ago

@DesantBucie which of them are SODP based custom roms? (The ones where you need to flash a OEM.img)

DesantBucie commented 3 years ago

-Pixel Experience -Your AOSP11(didn't try AOSP10)

Do lineage use SODP code? Because it happens on it as well.

MartinX3 commented 3 years ago

Official LOS18 and 17 are stock based. If you use explicitly the sodp based LOS in my XDA thread, it's SODP based.

Does it happen on vanilla stock 10, too? Because I currently run AOSP 11 on my XZ2 and charging works. USB charging and charger charging.

I hope you don't have a hardware damage.

Or maybe dirt/rust in the usb port?

Did you try to change your cable/charger/usb port?

DesantBucie commented 3 years ago

I used three cables, samsung's, apple's and silver monkey's. I'm on vanilla rom right now, and i'm at 87% from 15% in 40 min or less. I can throw phone on the bed and it still charges, if i did it on custom rom it would 100% stop charging.

I used vanilla for 3-4 or more weeks with no charging problems but then became annoyed at google calendar that cannot be used without logging, and flashed your AOSP, charging problems occured, flashed official 18.1 lineage, charging problem occured, and went back to stock today.

I'll check the port in a minute, but how do i clean rust? WD40 doesn't seem like a good idea.

Btw phone was in guarantee service half year ago to change volume button, but they didn't change usb-c port. Maybe they damaged something inside, but vanilla is doing all right.

Having started writing at 13:47 i have now 91%.

MartinX3 commented 3 years ago

About cleaning I found https://www.businessinsider.com/how-to-clean-usb-c-port https://www.reddit.com/r/essential/comments/diuwkb/corrosion_on_the_charging_port/

The fact that it works on stock is weird. Then we need a adb logcat -b all > charging.log from your PC started shortly before you connect your phone to the charger (you can use adb wifi). Then if the charging problem appears, stop the logging and give us the log :)

DesantBucie commented 3 years ago

All right, I'll do it in few hours. Thanks for help.

DesantBucie commented 3 years ago

Sorry for not doing anything for 3 days, but while cleaning with toothbrush microphone I damaged it, so I didn't touch anything yet.

MartinX3 commented 3 years ago

Sad to hear, I hope you can fix it.

DesantBucie commented 3 years ago

I can use second mic in loudspeaker mode, or one from headphones. I'll try to test AOSP today.

DesantBucie commented 3 years ago
  1. Vanila charging_vanila.log In 30 seconds i got 2%, no problems at all.
  2. LOS18 charging_los18_2.log charging_los18.log Logs end after i move phone a little bit, if i waited long enough it would stop charging itself I will try AOSP in a second
DesantBucie commented 3 years ago
  1. AOSP 11 charging_aosp11_2.log charging_aosp11.log
DesantBucie commented 3 years ago
  1. AOSP 10 charging_aosp10_1.log charging_aosp10_2.log
DesantBucie commented 3 years ago

Btw, i checked one more thing. I flashed oem_a and oem_b with SW_binaries...v12a on vanilla. It charges well.

MartinX3 commented 3 years ago

Does it only happen with quickcharge (your default charger) or as well if you charge the phone at your computer usb port?

DesantBucie commented 3 years ago

It does disconnect randomly, but connects almost immidiately. Oh no, now it just disconnected. I didn't move phone or anything.

DesantBucie commented 3 years ago

I'm gonna close this for now, i'm going to send phone to replace microphone and ask them to look at USB port.

DesantBucie commented 3 years ago

It was most probably a hardware problem. After replacing charging works on LOS18. The only think is weird that it worked on stock.