yashsingh1/xdaforums huggingface dataset:
[Nexus 5 Android Development] Sultanxda:
Camera init doesn't rely on the media HAL or vidc drivers unless HTC did something to make it that way. The media HAL and vidc drivers are only responsible for video encoding/decoding; I've never seen them play a part in loading the camera preview or taking a picture.

In other words, broken video encoding/decoding shouldn't prevent the camera from opening and loading the preview.

That means that HTC's audio HAL doesn't support our audio codec :( There's no way that HTC's audio HAL will ever work for us.
[Nexus 5 Android Development] FuMMoD:
I wonder if we could email HTC to lend a helping hand? Their devs are top notch.
[Nexus 5 Android Development] xXminiWHOOPERxX:
I smell a law suite from LG then.! :p

Sent from my HTC Droid DNA running Insertcoin 2.3.0
[Nexus 5 Android Development] FuMMoD:
Haha how so? Toss some sources our way and we handle the rest.
[Nexus 5 Android Development] Smith7018:
I wouldn't be so sure....

To get past that error, make edits to the /system/etc/media_paths.xml file. Once I tweaked it to be more inline with the Nexus 5, that error went away, but a new one arose (obviously).

Basically, from what I can surmise, the media_paths.xml tells the OS which ports to take for the speakers, mic, headphone port, etc. and the file looked different than the AOSP one so I suspect it was the M8's. So I imagine the OS was looking at the wrong address for the speakers the whole time.

Note: the HtcAudPMB is just a renamed AudioPolicyManagerBase, I think. Thus, this errors goes back to libhardware/legacy?
[Nexus 5 Android Development] xXminiWHOOPERxX:
Cause it's like asking Microsoft to help have their software on the PlayStation. That would be a lawsuit toward Microsoft from Sony because of them modifying the PlayStation ( look at the geohot situation when he cracked the ps3 software and made cfw firmware ) ... But yes HTC does support underground development but they can only do so by using there own files for their own devices. Not others like LG. The reason we can do it unofficially is because once we own a device we are allowed to do w.e we want with it longs its not from another OEM corporation helping out to get there software on another device not made by them....

Sent from my HTC Droid DNA running Insertcoin 2.3.0
[Nexus 5 Android Development] toocool4all:
Isn't the boom speakers causing the interference ? software is searching for the hardware and couldn't find it .

Sent from SOKP ROM with chaos kernel .
[Nexus 5 Android Development] Sultanxda:
It'll be a cold day in hell when HTC releases any ROM source.

Says device not found... Isn't that the same error? I grepped my /system partition on CM11 for our audio codec name (WCD9320) and the only hit I got was in /system/vendor/lib/libacdbloader.so, so it seems like audio codec support isn't in the audio HAL anymore (on legacy devices, such as the HTC Sensation, it is; I've only done stuff for legacy devices so there's a bit of a learning curve for me and MSM8974 :p). libacdbloader.so is a proprietary lib, so you can pull it from any N5 ROM. Try replacing that lib and see what happens.
[Nexus 5 Android Development] xXminiWHOOPERxX:
Yes try using libhardware.so and libhardwarelegacy.so from aosp Rom
[Nexus 5 Android Development] GalaxyUser:
This cannot work, i already tried :/
[Nexus 5 Android Development] xXminiWHOOPERxX:
What about files relating to audio in "/system/etc/permission" or even audioflinger?
[Nexus 5 Android Development] raynan:
I've tried just replacing any and all so files from AOSP and CM. The only thing I haven't looked at is files from the few nonCAF CM ROMs.
[Nexus 5 Android Development] GalaxyUser:
Amazing that's working for me too.

I will fix that in Sense port and sensors will work too !
[Nexus 5 Android Development] Vekhez:
Download MultiROM manager from the Play Store, install it and it allows for you to have more than one ROM on your phone, and when you boot you get a menu too chose what one.
[Nexus 5 Android Development] Galaxysm:
Did u do that bro?
[Nexus 5 Android Development] Vekhez:
Actually booting up into Sense with it as we speak.
[Nexus 5 Android Development] Thedonk13:
i love that Sense is getting ported out now. With the GPE devices i can only see this becoming a bit easier (hopefully) since a dump from a GPE device should give all the necessary libs to get a device to work (with some proper knowledge which i don't have)....

look forward to watching this grow...gonna wait a bit until the EFS issue gets worked out....don't really wanna RMA my phone by being to hasty..
[Nexus 5 Android Development] jabza:
They aren't EFS issues; EFS is just the partition that stores your IMEI and other device-indentifying information. It's a sensor issue, and a fix has been found. You just have to delete the files from /persist/sensors (I believe that's the folder) and reboot.

Sent from my Nexus 5

Edit: to clarify, this is what you delete:

/data/system/sensors

/data/misc/sensors

/persist/sensors/sns.reg

And then reboot.
[Nexus 5 Android Development] Vekhez:
Yeah, follow this - http://xdaforums.com/google-nexus-5/general/sensors-fix-nexus-5-t2704915
[Nexus 5 Android Development] hiback:
Tried it , Feels amazing nice work dev.

Some Screenshots for you guys.
[Nexus 5 Android Development] DubelBoom:
I know we are a very long way from there, but what are you going to do with the camera? I guess it will do some problems with the duo camera and all that..

Probably the M7's app will be better (also there won't be a need to disable buttons as they wont be there (the refocus button) ;)), but we need to wait for it if there is no leak yet for Sense 6.0 for M7.
[Nexus 5 Android Development] usaff22:
Why does your IMEI say unknown? Did your IMEI get wiped by the ROM or something lol.

It would be hell if we had another sensor nightmare, this time for no IMEI
[Nexus 5 Android Development] -DarkKnight-:
I think if you are in airplane mode or have no signal, your imei says unknown
[Nexus 5 Android Development] nomaj:
I'm from first series of troubles -=) lost sensors... I tried this (no offense to dev) but this is skinned stock android that we already have =)

In my point sense is what it is - skin + - some additional apss ;)

And after headache of yesterday with sensors - i don't like it even more =) My nexus is 10days old so you can understand me =)

But still i support dev. keep it coming on the end maybe this will be nice thing.
[Nexus 5 Android Development] jabza:
Yes. When you reboot, your phone should automatically generate those files again and your sensors should then work.

Sent from my Nexus 5
[Nexus 5 Android Development] DoesntPostAThing:
Do you only need to apply this fix if you want sensors to work in this ROM, or do you need to apply this fix because even if you're using multirom sensors will be messed up on other ROMs?
[Nexus 5 Android Development] wolfu11:
Well this is a preview for devs. From your statement about skins I don't think you really comprehend what a Port is. We try this at our own risk knowing that we can wreck our phone. It's not the devs fault nor should he be blamed. From the fiasco yesterday I'm glad to see he is continuing with this. I'm willing to wreck this phone if it helps bring this port to life. Thank you for making it this is one of the bolder attempts I've seen on here. I'm looking forward to something different the themed stock ROMs are getting boring lol.
[Nexus 5 Android Development] DubelBoom:
It will NOT fix sensors on this rom, only on others.

BTW, does this happens every time booting in to this rom, or only when flashing it for the first time.
[Nexus 5 Android Development] hiback:
No i. Other roms i have my imei its just that the sense port is not able to read the imei

---------- Post added at 09:38 PM ---------- Previous post was at 09:37 PM ----------

Ya every time you boot into sense rom it will break all the sensors..
[Nexus 5 Android Development] wedgess:
Until the OP has uploaded a fixed version of the ROM this thread will remain closed. The thread is also going to be cleaned so when the ROM is released it won't have pages and pages of clutter. All links will be removed as the OP does not want the ROM to be mirrored. Links to the sensor fix from yesterday will be left up for those who need it.

Thread closed for now...

Edit - Thread reopened at the OPs request ;)
[Nexus 5 Android Development] jamal2367:
Yeah reopen :) the work can begining again :)
[Nexus 5 Android Development] TheLastSidekick:
Glad to see this being picked up so quickly and being worked on again.
[Nexus 5 Android Development] -DarkKnight-:
More like a cease and desist to us :/
[Nexus 5 Android Development] Sparx639:
Does the camera need HW acceleration? I know touchwiz needs it, but for the encoding/decoding, that might be related more to sound. I'm not sure about those, does HTC use hw acceleration for the camera?
[Nexus 5 Android Development] FAdrums:
I know this is a Dev thread but I've lurking in the shadows following this development eagerly waiting for a fully functional rom as I really like Sense and I have to say that you guys are awesome and doing an amazing work. Thank you so much!

*Now back to the shadows and just observe*

Enviado do meu Nexus 5 através de Tapatalk
[Nexus 5 Android Development] OptimusRs:
Something Better :D He is fixing the bugs now he fix alot of bugs , camera ,ril , sensor , sound etc.... He will tell you guys wen rom is ready ;)
[Nexus 5 Android Development] GalaxyUser:
It's not HTC M8 or G2 Rom. Just wait and will see. No report with Sense.

Now keep the thread clean please, wait for news ;)
[Nexus 5 Android Development] Saqib Nazm:
Thread cleaned up again, had to delete 3 pages of off-topic, meaningless posts really. Guys this is the 2nd time, Please stay on topic.

I would like to ask the OP of this thread to write something about not going off-topic where everyone could see it, say near download link.
[Nexus 5 Android Development] _Infamous_:
I see galaxyuser has made progress on another project hope not touchwiz lol. I been trying to get sound to work forever but a no go, just boot loops and error logs, just going to move on not much else I can do. :)
[Nexus 5 Android Development] sykomaniac:
Hate to say it but I agree I can't get sound working and I'm getting bored of trying. Really thought Mr galaxy had it working.
[Nexus 5 Android Development] sellers86:
Honestly, I kinda hope its touchwiz. Just something new at least. AOSP is getting kind of boring. Thanks for all the work GalaxyUser, let me know if you need any help
[Nexus 5 Android Development] -DarkKnight-:
At least I hope its the new touch wiz , but I doubt its touchwiz at all because no touch wiz phones have soft keys

Otherwise I just want sound working :(

I've tried so many things, edited stuff , nothing works :(
[Nexus 5 Android Development] Daiskei:
Yeah, I've spent days trying as well... Nothing but countless boot loops... Throwing in the towel. Hope galaxy has something good for us!
[Nexus 5 Android Development] raymond4:
If it's touchwiz and any other type of port we should be grateful it's not like your the one doing the porting and plus if you don't like it then that's you other people would enjoy it. Let's continue and stay on topic here cause we don't needs mods coming in and cleaning up yet again
[Nexus 5 Android Development] wolfu11:
@GalaxyUser

Hey GalaxyUser I might be getting close on the Sound issue If I figure more out I'll PM you, it's quite obvious this thread has gotten out of hand.
[Nexus 5 Android Development] _Infamous_:
Just share what you are doing and maybe I or some one else can help. I'm just stuck and haven't made any more progress
[Nexus 5 Android Development] -DarkKnight-:
Can you tell me what are you doing or trying to do? I'm out of ideas....
[Nexus 5 Android Development] El Daddy:
Come on guys... We shouldn't have to come in here every few hours and clean up after you. This thread is DEV ONLY, it says so right in the title.

If you have nothing to contribute to the project, and would just like to comment on the build go here: NexSense ROM General Discussion

This is your final warning.

-El Daddy
[Nexus 5 Android Development] JunDavis:
As for the camera issue... What sort of errors are in place? Also, how is the camera currently "supposed" to be implemented. Perhaps I can look into something once those are answered...
[Nexus 5 Android Development] wolfu11:
I have a second phone I use this ROM on. I'm trying a hardware mod to verify a couple things and will not recommend anyone else try it.

This ROM could take months to figure out, even then there will be hardware conflicts. This will never work perfect on our phones but is a really cool project. This will be my last comment on this thread that doesn't have a solution, pretty soon this thread will get closed because people can't listen or read.
[Nexus 5 Android Development] GalaxyUser:
Hi,

For sound is anyone know chip audio chip M8 use ?

It seems to be WCD9320 because of files in /etc/firmware/wcd9320

But i'm not sure. When i replace any one of those files in AOSP from M8 the sound stop to work:

lib/hw/audio.primary.msm8974.so
lib/hw/audio_policy.default.so

lib/libaudioroute.so --> Boot but there is no sound
lib/libtinyalsa.so --> Boot but there is no sound

lib/libaudioflinger.so --> Boot but there is no sound

lib/libaudioutils.so --> can't boot
E/HAL ( 745): dlopen failed: could not load library "libmedia.so" needed by
"hwcomposer.msm8974.so"; caused by could not load library "libaudioutils.so" ne
eded by "libmedia.so"; caused by cannot locate symbol "__htclog_init_mask" refer
enced by "libaudioutils.so"...

lib/libsoundpool.so (?) --> can't boot
E/dalvikvm( 8330): dlopen("/system/lib/libsoundpool.so") failed: dlopen failed:
cannot locate symbol "__htclog_init_mask" referenced by "libsoundpool.so"...
W/dalvikvm( 8330): Exception Ljava/lang/UnsatisfiedLinkError; thrown while initi
alizing Landroid/media/SoundPool$SoundPoolImpl;

I think one (or more) of those files is the reason why we have not sound working on Sense port.

Any idea why that ?
[Nexus 5 Android Development] sorceforge:
How about poring over iFixit's movie or their article? I think they already examined it.

나의 Nexus 5 의 Tapatalk에서 보냄
[Nexus 5 Android Development] DumF0rGaming:
Check, what's preventing libaudioutils.so and libsoundpool.so from locating symbol "__htclog_init_mask" :p
[Nexus 5 Android Development] GalaxyUser:
iFixit did not say which audio chip it use :/

This is normal, because i used M8 libs in AOSP rom to see which are causing problem. So it cannot found this symbol but it's not important.

We need to found which lib create this error --> Could not find input for stream 2
[Nexus 5 Android Development] DumF0rGaming:
I'm not a dev, but I see those libs can't initialize itself and messing around each other because of this init mask. Are you sure this is not important? Please, provise us another part of changelog then
[Nexus 5 Android Development] GalaxyUser:
yeah i'm sure it cannot locate "__htclog_init_mask" because it's M8 libs on AOSP rom.

It was just to see which files we need to change to get audio working
[Nexus 5 Android Development] sykomaniac:
Maybe look at system/framework/framework.jar on aosp and sense rom in particular the media directory. If you are good at smali editing you might fix the linker issue?
[Nexus 5 Android Development] GalaxyUser:
I don't think it's smali issue.......

But we can try
[Nexus 5 Android Development] yooouuri:
pls dont yell at me for this question

Just an idea, look into the Google Play edition of the M8, compare soms libs with our AOSP rom? And replace them into the Sense rom?
[Nexus 5 Android Development] Oweida:
Hi All

Sound was always frustrating in HTC sense ports however I found it exciting !

Galaxyuser has been faithful in the matter. His effort is really appreciated.

Unless we have another developers to work all toghther to perfectionate the port otherwise one hand can't applaud !

I really wanna try fixing it as I did in Galaxy S3 & 4 but nexus devices was never my inspirational devices.

Probably I'll try with LG G2 when I get free time.

I really wish you luck and I believe you will do it !

Tip , try using librarys from soundfix folder from your AOSP Rom plus in etc folder replace audio files ( I think audiopolicy and audioprofile if I'm not mistaken ) .

Another tip , try different HTC rom files , probably it will produce different logcats hinting to your problems.

Hmmm I forgot to mention that I was able to get camera working in S4 by using if I still remember libcamera.so and libcamera_client.so from CM or AOSP roms and adding needed libs produced by logcat.
[Nexus 5 Android Development] drsn0w:
Hmm seems like a good idea, I'll investigate this after lunch.

---------- Post added at 01:50 PM ---------- Previous post was at 01:12 PM ----------

Hmm just something interesting....

Here we have /init.htc.audio.sh

#!/system/bin/sh
echo 1 > /sys/kernel/boot_adsp/boot 1
insmod /system/lib/modules/adsprpc.ko

I haven't seen adsprpc.ko mentioned at all yet, could this be something to be looked at?

---------- Post added at 02:22 PM ---------- Previous post was at 01:50 PM ----------

One more thing...what audio chip does the N5 use again?
[Nexus 5 Android Development] FrankyDoodle:
The Qualcomm WCD9320
[Nexus 5 Android Development] drsn0w:
Okay, and the M8 uses the msm8974 then?
[Nexus 5 Android Development] Pawelss:
GalaxyUser mentioned it also uses WCD9320.
[Nexus 5 Android Development] drsn0w:
Hmm okay, I'm finding stuff that references msm8974 and msm8610
[Nexus 5 Android Development] FrankyDoodle:
MSM8610 references to the S200 SoC while MSM8974 references to the S800 SoC, I would say that those two are unrelated.
[Nexus 5 Android Development] drsn0w:
They're in the qcom audio init file
[Nexus 5 Android Development] FrankyDoodle:
I'd guess that those are references to the SoC's and don't really have any influence in the audio.

Can you quickly upload the specific init?
[Nexus 5 Android Development] drsn0w:
Here you go: https://mega.co.nz/#!pE02EayZ!LpwmeEEfGHaX9LjcHhugsw4rH9gqMBi8mTuOIjbYv_c
[Nexus 5 Android Development] FrankyDoodle:
Looks like this script is for Bluetooth devices and not really related to the current problem.

And the MSMxxxx reference, as I thought, to the Qcomm SoCs.
[Nexus 5 Android Development] drsn0w:
Oh hahah derp I didn't read the comments in the script >.<

I'm following a different lead anyways now
[Nexus 5 Android Development] DumF0rGaming:
Hello, guys, checkout the FAQ thread I made. Don't hestigate to suggest your own QA!

http://xdaforums.com/google-nexus-5/general/nexsense-rom-faq-thread-t2729537
[Nexus 5 Android Development] bariz143:
What happened to the big surprise you guys were talking about. That sound and camera was working? :)
[Nexus 5 Android Development] _Infamous_:
Different project
[Nexus 5 Android Development] sykomaniac:
[MENTION=2623456]GalaxyUser[/MENTION] can you please put the kernel source somewhere so I can take a look at it. Thanks
[Nexus 5 Android Development] GalaxyUser:
Kernel of ? For the port i'm using the AOSP one with ramdisk changes for Sense
[Nexus 5 Android Development] sykomaniac:
Ok no problems I'll have a look tomorrow. Just going to have a poke around as so far I'm out of luck with fixing the audio issue. Have you managed to make any progress?
[Nexus 5 Android Development] GalaxyUser:
I was working on another project. I really don't know how to fix that thing .....
[Nexus 5 Android Development] Vekhez:
One for the n5? Now your just teasing :P
[Nexus 5 Android Development] -DarkKnight-:
[Edit: removed ]
[Nexus 5 Android Development] davide136:
No no no no, don't say those things, pm galaxy_user and try to help him but do not discourage him :) by now he and the others devs made a really good work and the Rom is faster than stock one...it can be done

Inviato dal mio Nexus 5 utilizzando Tapatalk
[Nexus 5 Android Development] Sparx639:
What's this other project? Can I get a pm? And I've been working with the sound and sound logs, the IT director at my school is helping me out with it cause he devs for the gs4, so hopefully I make progress
[Nexus 5 Android Development] androidfilesharing:
I have never worked with an IT Director that new the difference between UDP and TCP. Consider yourself lucky my friend. I end up teaching most of my directors and wonder why I am not the one behind the big fancy desk.
[Nexus 5 Android Development] sykomaniac:
To anyone who knows anything about kernels does this indicates something:

<6>[ 1.351562] msm8974-asoc-taiko sound.29: msm8974_asoc_machine_probe(): hdmi audio support present
<6>[ 1.351658] msm8974-asoc-taiko sound.29: property qcom,us-euro-gpios not detected in node /soc/sound
<6>[ 1.351906] msm8974-asoc-taiko sound.29: msm8974_asoc_machine_probe() MBHC disabled = 1

Just looking at the kernel dmesg to see if there's any audio related issues. If anyone wants to know what command this is from its:

adb shell su -c dmesg > dmesg.log

Also see this in the log:

<3>[ 3.872133] init: could not import file '/init.qcom.rc' from '/init.rc'
<3>[ 3.872219] init: could not import file '/init.qcom.audio.rc' from '/init.rc'
<3>[ 3.872274] init: could not import file '/init.htc.audio.rc' from '/init.rc'
[Nexus 5 Android Development] pandasa123:
Where's the latest boot.img? I want to check something out for you guys regarding that dmesg
[Nexus 5 Android Development] sykomaniac:
Get it from the patch file in OP :) or: http://fs1.androidfilesharing.com/NexSense/NexSense_Path-GalaxyUser.zip
[Nexus 5 Android Development] pandasa123:
ok these files don't even exist in the m8 kernel i'm looking at, which can mean that the init.rc has to be changed

hell, i thought i might've missed it, but i looked in the init.rc for the m8 kernel and those files aren't mentioned there either
[Nexus 5 Android Development] sykomaniac:
I don't think they exist I think this is a typo as the are .sh files in the M8 kernel. I took a look and couldn't see anywhere that invoked them though :/
[Nexus 5 Android Development] pandasa123:
you're right. they are all shell scripts. now...do they belong in init.rc? there are no .sh files called from it

wait...init.target.rc refers to init.htc.audio.sh in the m8 kernel

and its in 2 files in the Nexus kernel: init.hammerhead.rc and init.target.rc
[Nexus 5 Android Development] awidawad:
Yes sense depends on modified ramdisk, so the ramdisk in the port would need to be reworked a little. I'll look at it when I get home if nobody beats me to the punch
[Nexus 5 Android Development] sykomaniac:
Thanks - I know nothing about kernels at all!

Here's the full DMSG if it helps: http://pastebin.com/pTTHRYUX
[Nexus 5 Android Development] a2441918:
thats great
[Nexus 5 Android Development] blttalas:
If you can fix sound and camera n5 users will use this rom as daily driver ;)
[Nexus 5 Android Development] pandasa123:
Well that's the thing...sound is a WIP that's being irritating and we can't really move onto camera issues until after sound
[Nexus 5 Android Development] PowkyE:
The rom is very very good bro! I really really like it!

PD: the people who don't want to flash it because is not stable with a lot of thinks not working, the rom works with multirom so you can install it and delete it without any problems.
[Nexus 5 Android Development] PowkyE:
How i can root The rom?
[Nexus 5 Android Development] DumF0rGaming:
Dude, it's pre-rooted

If you guys have a question, go to

NexSense ROM FAQ Thread

And if you come up with something much more stupid then this ask it here

NexSense ROM General Discussion
[Nexus 5 Android Development] FrankyDoodle:
It actually isn't pre-rooted, you need to flash supersu-binary to gain root.
[Nexus 5 Android Development] PowkyE:
Where I can find the correct supersu-binary for this rom?
[Nexus 5 Android Development] ext109:
Flash this

http://download.chainfire.eu/396/SuperSU/UPDATE-SuperSU-v1.94.zip?retrieve_file=1

Google Nexus 5
[Nexus 5 Android Development] wolfu11:
David if you fixed the sound what was the solution?
[Nexus 5 Android Development] grim489:
I don't think he fixed it he meant he was going to fix it
[Nexus 5 Android Development] David_Vaz:
I try to fix* correction.

Impossible for me.