[LP][30-11-2014] Android 5.0 LolliPop for Xperia Z (KMA)

Search This thread

Grege50

Member
Aug 17, 2012
36
6
Melbourne, Australia
Headphones (not headsets) and AUX connections

With the stock ROM when you plug in headphones (not headsets) or an AUX connection and play music and then when the phone rings the music will pause and when you answer you can speak via the phone microphone and receive the incoming audio through the headphone jack.

With CM11 the phone microphone does not work in this scenario., but the inbound sound still comes through the headphones (or car radio).

With PABX Lollipop when the phone rings it is all muted and the only way to answer the phone is to pull out the headphones. CM11 is much the same in that you can only answer the phone by pulling out the headphones or AUX cable.

I use a Belkin headset adaptor to work around this. This is an adaptor cable that adds a microphone to headphones turning it into a headset. Headsets work fine, this is a very specific issue.

I realise this is of low importance and as Cyanogenmod have never been able to solve it I assume it is not an easy thing to change. People who play music through AUX connectors would appreciate the behaviour of the stock ROM. At the moment it would be impossible to answer the phone while playing music while driving in a car.

ps the Belkin adaptors are about ten bucks on eBay and even though they are advertised for iPhones they work fine and you can turn an AUX connection into a functional handsfree. There are many others available just search on "headphone adapter with microphone"
 
Last edited:

danny19901

Senior Member
Nov 4, 2010
2,614
858
Stockton-On-Tees
Well with the testing of L so far with PABX 5.0.1 it seems I have slight audio issue like explained previously and lag on games this is weird to explain but Bloons TD 5 pure bad lag on round 5 but opening recents and opening app from there fixed it but this isn't the only thing I have had bad lag with also I'm not sure if performance is as good as KitKat also the odd keyboard issue is annoying as hell but oddly it only seems to do it in Facebook app and FB messenger but so far the ROM
 

kingvortex

Senior Member
Mar 25, 2010
5,042
3,967
Well with the testing of L so far with PABX 5.0.1 it seems I have slight audio issue like explained previously and lag on games this is weird to explain but Bloons TD 5 pure bad lag on round 5 but opening recents and opening app from there fixed it but this isn't the only thing I have had bad lag with also I'm not sure if performance is as good as KitKat also the odd keyboard issue is annoying as hell but oddly it only seems to do it in Facebook app and FB messenger but so far the ROM
Please use the q&a thread.
See this post by a moderator (one of many).

I regularly report this thread so posts get moved to the correct location where questions are likely to be answered, but some people still insist on posting non development related stuff in here, despite already having a lot of their posts moved to the q&a thread. I don't think it's fair that the already busy moderation team have to repeatedly spend time moving posts because people won't use the correct thread.

Thomas even asks that basic stuff be posted in the q&a thread if you read the OP.

Thanks. :)

Sent from my C6603
 
Last edited:
  • Like
Reactions: golfgtiedition30

natibongo

Senior Member
Apr 19, 2013
292
90
Ajumako
How to change your device model number in "about phone"

DISCLAIMER: I'M NOT RESPONSIBLE FOR ........................... DO IT AT YOUR OWN RISK

First of all, credits go to @thomas1991_12 and @pabx for bringing lollipop to our old but powerful XZ. ;)
When we go to About Phone in the settings menu what we see under model number is "Full Android on C6603''. This is true in both @Thomas and @pabx build. To change the name to what we normally see on our devices, simply follow this guide carefully:

1. Open any file manager with root permission and navigate to system. (I recommend root explorer)
2. Locate a file named build.prop and make a backup to your external sdcard (in case anything goes wrong)
3. Touch and hold the original build.prop file located under system and select "Open in Text Editor"
4. Go to this line "ro.build.model=Full Android on C6603"
5. Delete "Full Android on C6603" in that line and replace it with any name you want (eg. Sony Xperia Z, Your son or daughter's name etc)
6. Tap on the three dotted menu at the top right corner and select "save and exit"
7. Grant all necessary permissions when prompted and reboot
8. Now go to Settings-About Phone/Model number and see the changes for yourself.
9. You know what to do next HIT THE THANKS BUTTON BELOW. It helps to do more

See the screenshot below.
 

Attachments

  • Screenshot_2014-12-10-12-57-51.png
    Screenshot_2014-12-10-12-57-51.png
    132.4 KB · Views: 1,723
Last edited:

mkryvz

Senior Member
Mar 25, 2014
86
5
Excuse me for this noob question;
But i wonder that, is there a way to get sony apps with this rom?
if there is a way, how can i get it?

Thank you.
 

jackq

Senior Member
Mar 1, 2012
808
713
B-B
Hi guys, i see that you managed camera to work on android 5. So i have req, maybe someone can help to fix camera in cm12 android 5.01 on Z2. I think there will be a lot of thanks and maybe donations if finally cam start to work on our Z2 phones.
Best regards. Cheers.
 

natibongo

Senior Member
Apr 19, 2013
292
90
Ajumako
Hi guys, i see that you managed camera to work on android 5. So i have req, maybe someone can help to fix camera in cm12 android 5.01 on Z2. I think there will be a lot of thanks and maybe donations if finally cam start to work on our Z2 phones.
Best regards. Cheers.

Sorry this thread is for the xperia z only. Check for Z2 thread in the developers forum
 

shoey63

Recognized Contributor
Sorry this thread is for the xperia z only. Check for Z2 thread in the developers forum

Err... I think that is why he is here. None of the lollipop roms in the z2 forums have a working camera.

Edit: we are indeed fortunate to have pabx working on our device. First non nexus phone to have a pretty much bug free android 5.0. It is understandable that users and developers of other devices would come here looking for assistance. I suggest perusing pabx and Thomas's github for possible clues to get camera going on other xperia devices :thumbup:
 
Last edited:

pabx

Senior Member
Apr 5, 2011
598
1,801
Zurich
Hi guys, i see that you managed camera to work on android 5. So i have req, maybe someone can help to fix camera in cm12 android 5.01 on Z2. I think there will be a lot of thanks and maybe donations if finally cam start to work on our Z2 phones.
Best regards. Cheers.

Does the camera module even load? The Xperia Z doesn't need any HAL hacks but only some function dummies to make the loader happy.
 

tonev

Senior Member
Nov 10, 2008
229
40
My xperia z still does not want to install it it reboots after showing home screen even with the new build : (
 

TheMrcool212

Senior Member
Nov 26, 2012
1,624
2,086
Kuala Lumpur
Does the camera module even load? The Xperia Z doesn't need any HAL hacks but only some function dummies to make the loader happy.

Yes, but it's returning an error:

Code:
I/CameraService( 2779): CameraService started (pid=2779)
I/CameraService( 2779): Loaded "Xperia Camera Wrapper" camera module
W/linker  ( 2779): libmmjpeg.so has text relocations. This is wasting memory and prevents security hardening. Please fix.
E/HAL     ( 2779): load: module=/system/lib/hw/camera.vendor.qcom.so
E/HAL     ( 2779): dlopen failed: could not load library "libcald_util.so" needed by "camera.vendor.qcom.so"; caused by could not load library "libcald_pal.so" needed by "libcald_util.so"; caused by could not load library "libcacao_jpeg.so" needed by "libcald_pal.so"; caused by could not load library "libcammw.so" needed by "libcacao_jpeg.so"; caused by cannot locate symbol "list_add_tail" referenced by "libcammw.so"...
E/CameraWrapper( 2779): failed to open vendor camera module

I checked those lib files and each one of them are there.
 

pabx

Senior Member
Apr 5, 2011
598
1,801
Zurich
Yes, but it's returning an error:

Code:
I/CameraService( 2779): CameraService started (pid=2779)
I/CameraService( 2779): Loaded "Xperia Camera Wrapper" camera module
W/linker  ( 2779): libmmjpeg.so has text relocations. This is wasting memory and prevents security hardening. Please fix.
E/HAL     ( 2779): load: module=/system/lib/hw/camera.vendor.qcom.so
E/HAL     ( 2779): dlopen failed: could not load library "libcald_util.so" needed by "camera.vendor.qcom.so"; caused by could not load library "libcald_pal.so" needed by "libcald_util.so"; caused by could not load library "libcacao_jpeg.so" needed by "libcald_pal.so"; caused by could not load library "libcammw.so" needed by "libcacao_jpeg.so"; caused by cannot locate symbol "list_add_tail" referenced by "libcammw.so"...
E/CameraWrapper( 2779): failed to open vendor camera module

I checked those lib files and each one of them are there.

Uhm no: that's exactly what i was talking about: the library is *not* loaded as libcammw.so references to list_add_tail and the function does not exist (at least not in any loaded library)
Are you using the latest blobs from sony? It seems that the function existed (at least) in 4.1.2 and was part of libcutils:
http://osxr.org/android/source/system/core/libcutils/list.c#0025

So either google moved it to some other lib or it got removed (or had its signature changed).
In this case, you can simply backport the required functions to 5.0's libcutils
 

TheMrcool212

Senior Member
Nov 26, 2012
1,624
2,086
Kuala Lumpur
Uhm no: that's exactly what i was talking about: the library is *not* loaded as libcammw.so references to list_add_tail and the function does not exist (at least not in any loaded library)
Are you using the latest blobs from sony? It seems that the function existed (at least) in 4.1.2 and was part of libcutils:
http://osxr.org/android/source/system/core/libcutils/list.c#0025

So either google moved it to some other lib or it got removed (or had its signature changed).
In this case, you can simply backport the required functions to 5.0's libcutils

It seems google moved the function outside libcutils in lollipop and made it as a static function shown here: https://github.com/CyanogenMod/android_system_core/commit/a6aad4cdb3ec75668838f3eced59bbb2c7b70c59

I can simply revert that commit to get it back. So updating the blobs wont do anything with it (since it's still 4.4.4).

I'll build libcutils with the revert and report back, thanks for the help.

---------- Post added at 05:54 PM ---------- Previous post was at 05:10 PM ----------

I had replaced libcutils file with the new one, the libcammw.so error is gone but it's still didn't work. What i noticed there's a slight delay for 2-3 seconds before it crashes. I can't identify what's the exact error, here's what i can found:

http://pastebin.com/nAwHbjSx

EDIT: camera2 app seems to show more info: http://pastebin.com/T0DrdNFT
 
Last edited:

TheMrcool212

Senior Member
Nov 26, 2012
1,624
2,086
Kuala Lumpur
Oh, you are using CMs camera wrapper?

Actually i would get rid of it - i'm not using it in my port and i do not see any reason to do so - at least i would recommend to temporarily remove it to ease debugging.

Yes, I'll use the vendors one then.

Btw, should i add a dummy function on missing symbol errors like you did on system_core commit?
 

pabx

Senior Member
Apr 5, 2011
598
1,801
Zurich
That depends on whether the sony blobs require this function (you'll get a similar dlopen error if the function is missing)
 
  • Like
Reactions: thedr4g0n

TheMrcool212

Senior Member
Nov 26, 2012
1,624
2,086
Kuala Lumpur
I had got rid of the dlopen errors now, but the camera still didn't work. I checked the logcat, there's no missing symbol / lib file. What i found is that the camera HAL nodule can't be loaded. Any suggestion?

EDIT: Is this could be relating to SELinux? Just curious.

EDIT2: I found that there's a missing library file, so i copied camera.msm8974.so from sony 4.4.4 into /system/lib/hw. That seem to fix the problem.

EDIT3: Here's the log with the file included: http://imgur.com/YmmWyof
 
Last edited:

tOrNadO™

Inactive Recognized Contributor
Oct 27, 2012
2,240
1,182
Bangalore

Top Liked Posts

  • There are no posts matching your filters.
  • 214
    Lollipop
    I have build AOSP lollipop for our Xperia Z.

    Changelog

    18-11-2014
    - GPS from mako (credits to pabx)
    - Synced
    - TWRP Recovery

    18-11-2014
    - Open source GPS (Fully working?)
    - Kernel updates
    - Device tree updates
    - Synced (5.0.0_r7) & pabx

    18-11-2014
    - Working root & latest CWM recovery
    - Kernel updates
    - Device tree updates
    - Synced (5.0.0_r6)


    Feature list:
    Working:
    - Screen / touch
    - Audio
    - Wifi
    - Vibrator
    - Camera
    - RIL
    - NFC
    - Bluetooth
    - Sensors
    - GPS

    Not working:
    - You tell me

    Download
    https://drive.google.com/file/d/0B7XCSgymRoP0RFpnZmszeDlWQU0/view?usp=sharing

    Gapps (CM-12): CM Gapps or PA: PA Gapps or pabx's gapps
    SuperSu (latest): http://www.chainfire.eu/

    Install
    Fastboot:
    fastboot flash boot boot.img
    fastboot flash system system.img
    fastboot flash userdata userdata.img (THIS WILL WIPE YOUR DATA/SDCARD)

    First boot might take a while, black screen for a couple of minutes so don't worry it will boot.

    Source
    https://github.com/yugalollipop/

    Notice
    Please use this thread for bug reports only. (provide logs)
    Use the Q&A thread for questions. Let's keep this thread clean.

    Please press thanks or donate

    Credits:
    Pabx
    25
    New build is up. See OP.
    24
    It seems like your build has SE-Linux disabled.

    If you need some .te files, feel free to grab them from my git-repo: https://github.com/adrian-bl-yuga/device-sony-lagan/commit/ecc7cff36202671520f1f8e5cbd77c439a2e12da

    I prepared them some months ago after the l-preview source was released. They will hopefully still work on the final l-release :) (can't confirm yet as my own build is still compiling)

    But great work: Seems to run quite well so far!
    23
    New build is up. Should fix most of the problems (gps, encryption, apps crashing, rebooting)

    Build should be rootable, recovery won't work out of the box.
    21
    Okay, so I have unpacked the ramdisk again and done the following as suggested by Chainfire:
    Chainfire said:
    To fix root, all that really had to be done was ensure the daemon's startup script is run at boot as the root user with the init context.

    And it works :)

    root.png


    Download: root-fix_lollipop-yuga.zip

    NOTE: This time, I have decided to upload a flashable ZIP since some of you may already have a recovery. In case you don't, just unpack the ZIP file and flash the boot.img using fastboot as usual. The kernel per se is untouched, I have only made changes to the ramdisk.