yashsingh1/xdaforums huggingface dataset:
[HD2 Android NAND Development] gilbert32:
Bluetooth

More work on bluetooth...

brcm_patchram_plus fails every time and tries writing (01,03,0c,00) all the time.

Here at posts 529 and 530 are similar problem: http://xdaforums.com/showthread.php?p=11281412

I'm still trying to get it working. Tried with mainly tytung's and marc1706's kernels, to no result
[HD2 Android NAND Development] Robbie P:
Might be worth trying dorimanx kernels. IIRC 6.6d hwa has specific sense system folder and worked on seaman2k JB rom, and 7.3 doesn't boot with haret.

6.9 was a favourite of mine.
[HD2 Android NAND Development] gilbert32:
I'm using fastboot with black clk to try kernels.

I tried once before a dorimanx kernel, booted but gave me like 0.1 fps (litterarely) so i couldn't test it. I could try other versions but can you provide me with links? thanks
[HD2 Android NAND Development] Robbie P:
http://dorimanx.com/

Not sure how easy that is for you to test these.

I have to go out, but will try on sd build this evening.

edit; sd build kernels here http://xdaforums.com/showthread.php?t=1492488 bottom of post 1
[HD2 Android NAND Development] gilbert32:
6.9 HWA ICS kernel: same fate. still waiting to unlock the phone. Too many egl problems:

17:43:40.384 Error Adreno200-EGLSUB 159 GetBackBuffer() genlock_wait failed
17:43:40.384 Error Adreno200-ES20 159 <gl2_surface_swap:41>: GL_OUT_OF_MEMORY
17:43:40.384 Error Adreno200-EGL 159 <qeglDrvAPI_eglSwapBuffers:3339>: EGL_BAD_ALLOC
17:43:40.384 Error Adreno200-ES11 159 <qglDrvAPI_glTexImage2D:1913>: GL_OUT_OF_MEMORY
17:43:40.499 Error Adreno200-ES11 159 <qglDrvAPI_glTexSubImage2D:2055>: GL_OUT_OF_MEMORY

I'm done with testing today. maybe will try something in few hours
[HD2 Android NAND Development] aazzam16661:
HTC 25Gb dropbox offer works!!

I use dataonext version, and on initial setup, i login my dropbox account and receive my 25gb for 2 years!!

Dont no its going to last, if dropbox finds out, they take it back from u.
[HD2 Android NAND Development] Marek989:
Not frickin' booting

Oh crap... I tried this ROM. Flashed DataOnEXT version (system partition is 350MB), it booted up, and first thing i saw, was graphical tears and all process stopped.. so i put out the battery, put it back in, and it is stuck on Desire HD bootscreen! LOL.... Even tried factory reset in recovery, nothing... huh?
[HD2 Android NAND Development] aazzam16661:
Try a bigger system partition, i use 427mb (EU HD2) in clk i enable ext rom

But as of right now i'm using the same system partition as you and no problems at all.

Did you wipe data/factory reset, didn't it reformats the sd-ext and i thing that why you stuck at DHD screen
[HD2 Android NAND Development] Marek989:
Yes, it formats SD EXT. But, can be the problem that i use only 0.5 GB SD EXT? How can i increase it WITHOUT losing data on SD?
[HD2 Android NAND Development] aazzam16661:
To Gilbert

Here's the files u ask me
[HD2 Android NAND Development] aazzam16661:
Try using Minitool partiton.

Delete the ext4 partition>Click the fat32 tab>Click the move/resize tabs on the upper left corner>resize to your desire> click apply

Data on SD card will not be lost, just tested before reply
[HD2 Android NAND Development] Marek989:
Thank you :)
[HD2 Android NAND Development] gilbert32:
Thanks. Out of thanks for today :D
[HD2 Android NAND Development] Marek989:
Ok, so it totally messed up my phone. CWM can't mount SD card, says "E:Can't mount /sdcard/ :(
[HD2 Android NAND Development] gilbert32:
You still have your fat32 partition right? there should be 2 partitions on your sdcard: 1 fat32 partition at the left and 1 ext4 partition to the right. both must be set to primary i think.
[HD2 Android NAND Development] Marek989:
I had both as primary. Now, I repartitioned SD trough CWM (backed up SD of course :)) and now, I'm copying all files back. Phew....

EDIT: before copying all the files, i tested if the CWM mounts the SD. AND IT MOUNTS!!!!! YEAAAA.... And now, at least i have 256 MB SWAP and 2GB EXT HEHEHEHEHE YEEESSS.....
[HD2 Android NAND Development] aazzam16661:
To gilbert32 also

File u ask gilbert32
[HD2 Android NAND Development] Marek989:
Ok, so the ROM booted, i pulled the ring, waited after the white HTC screen.... but then, there should be an setup. But it is blank and system says "Setup us not responding". My /system is 420 MB. Can anybody help me?
[HD2 Android NAND Development] gilbert32:
If you installed dataonext version (commonsense4), remove battery and turn phone on again.
[HD2 Android NAND Development] aazzam16661:
Did you wait about 15minutes after the rom booted before you pull the ring, let is rest before pulling the ring
[HD2 Android NAND Development] Marek989:
Tried, doesn't work

Tried too, but i just heard the sound as it booted again and i wated, but it doesn't work. I got rid of it, downloading Pixeldroid JB now. Anyway, thx for your time, i'll try Sense 4 after more bug fixes etc :)
[HD2 Android NAND Development] gilbert32:
OK. BAD NEWS.

today while doing something, i got my first nand bad block! :(

Clk gave me a bad block 4040 marked in extrom which i was using, so i disabled it.

Bad news for me, hd2 started aging:( i couldn't boot anymore, even after increasing boot and sboot sizes. after reflashing them they didn't work, so i disabled extrom, formatted nand and reflashed sboot only which works good for nativesd roms.

It will be a while before coming back to this rom..... I'll be back for the moment to Windows Mobile (my all time favourite) or windows phone. And Ubuntu :D

Edit: here are my thoughts for what should be done with this rom:

for camcorder: try fixing the app? maybe it's like weather and clock, partially not working like in the initial release

mic: replace libs?

Bluetooth: get new kernel

Glitches: i accidently fixed it somehow, but don't remember. try other egl/graphics libs

hwcomposer.qsd8k.so in system/lib/hw not working. error related to libqdutils.so not found. i only found it in jb roms i have

some error related to htc or hci_acoustic i dont remember

lights: set better permissions? adb logcat always gives light errors

Thanks for everyone for their help
[HD2 Android NAND Development] Marek989:
How can you find bad blocks?
[HD2 Android NAND Development] gilbert32:
in black clk i go to settings, and set enable fill bbt@startup. i reboot, go to info and print bad block table
[HD2 Android NAND Development] Robbie P:
Sorry to hear that, try the sd build I ported and posted, it works pretty good. You can also check the portadroid thread and try trib's 4.1 too, bit laggier with more glitches, but also ok, with more features (task manager and lockscreen widgets working)

[MENTION=223412]marek[/MENTION], if magldr settings/services/dmesg to sd, then look for dmesg.txt on sd and search it for bad blocks
[HD2 Android NAND Development] gilbert32:
Okay. i will definitely try the sd builds after i visit my friends and make them download them for me :D

Edit: this is my desktop screenshot, after working with the rom for 2 weeks:

Edit: info 8 gave 1 bad block. tried task 29. info 8 gave no more bad blocks :) phewwww
[HD2 Android NAND Development] Marek989:
LOL, i have 5 bad block as i see :D

Maybe THEY are why this ROM doesn't show me setup?
[HD2 Android NAND Development] gilbert32:
Maybe. there's a high chance they a the reason.

I fixed mine with mtty task 29 (my first ever task 29, after a year and about 300 flashes) :D
[HD2 Android NAND Development] thelonewolf_pav:
sorry to hear about that man...

however, I must tell you that I have several bad blocks for a while now, and everything works fine. I just have to allocate mode space for system.

anyway, can I ask you for a favor? if you say that you don't have glitches now, could you pull your /system folder and upload it here? that would be of great help!

thanks!
[HD2 Android NAND Development] gilbert32:
after finding the bad block, nothing would boot or flash to boot so i left android nand, task 29, install wm6.1, flash wp7.8, install wm6.1

so there's nothing left from system to pull :D

and btw, it happened accidently in a test, which i reflashed too many times
[HD2 Android NAND Development] thelonewolf_pav:
well, that's too bad... hope your device becomes usable again with wm6.1 :)
[HD2 Android NAND Development] zexmunze:
On my port i'm faceing several problems,settings wont persist,autorotation,gps,all working but in settings can't enable disable some times work,settings are messed up
[HD2 Android NAND Development] aazzam16661:
Is your port, sense 4 or 4.1 ?
[HD2 Android NAND Development] thelonewolf_pav:
try to add:

to one of your init.d scripts :)

I'm still having glitches. it's just driving me mad...

can you upload yours so we can compare?
[HD2 Android NAND Development] zexmunze:
my port is 4.1 ics 4.0.4

Thanks i will try it,do i need to write new script like this or add in some script?

#!/system/bin/sh

chmod -R 777 /system/etc/init.d

and i will consider about that,1st i need permission,then.....
[HD2 Android NAND Development] thelonewolf_pav:
you can just add this to one of the scripts
[HD2 Android NAND Development] zexmunze:
Nothing hapend,nothing changed.
[HD2 Android NAND Development] thelonewolf_pav:
weird...

well, maybe you should try playing with the OOM settings. I used to have a similar problem with my sense 3.5 ROM -- settings would not persist. it appeared that the OOM mechanism would silently kick out the underlying service provider while I was changing my settings. The service provider died quietly and came back to life when more memory was available, in other words, when I closed the settings window :laugh:

of course, it didn't remember what I changed -- there was nobody listening :) so none of my settings persisted -- or, to be precise, they would persist randomly. I fixed this by giving lower values to minfree, so the service stayed alive while I was changing the settings.

Look at dmesg, you will see it killing your service...
[HD2 Android NAND Development] zexmunze:
You definitely pointed in right direction,i set low memory killer to be more aggressive,will try to lower down and see...

Since i'm using your updater-script and data on ext method can you recheck updater script and compare with one from rom i ported,are there any changes in permissions,i will be thankful if you can do that..
[HD2 Android NAND Development] thelonewolf_pav:
well, there are differences:

mine: set_perm_recursive(1000, 1000, 0771, 0644, "/data/local");

yours: set_perm(2000, 2000, 0771, "/data/local");

also all the lines below are missing from your script:

set_perm_recursive(1000, 1000, 0771, 0644, "/data/swap");

set_perm_recursive(1000, 1000, 0771, 0644, "/data/app_s");

set_perm_recursive(1000, 1000, 0771, 0644, "/data/fonts");

set_perm_recursive(1000, 1000, 0771, 0644, "/data/weather");

and also:

set_perm_recursive(1000, 1000, 0771, 0644, "/system/app");

set_perm_recursive(1000, 1000, 0771, 0644, "/system/framework");

also this (this is important for PPP to work):

set_perm (0, 2000, 04755, "/system/bin/pppd");

and this (don't know if this is of any importance, but it will surely affect bluetooth):

set_perm(1002, 1002, 0440, "/system/etc/bluetooth/input.conf");

set_perm(1002, 1002, 0440, "/system/etc/bluetooth/main.conf");

set_perm(0, 0, 0644, "/system/etc/bluetooth/a2dp_avrcp.conf");

set_perm(0, 0, 0644, "/system/etc/bluetooth/avrcp.conf");

set_perm(1002, 1002, 0440, "/system/etc/bluetooth/audio.conf");

also:

set_perm(0, 0, 0777, "/system/bin/a2sd");

set_perm(0, 0, 0777, "/system/etc/init.d");

set_perm_recursive(0, 0, 0777, 0777, "/system/etc/init.d");

and this:

set_perm(0, 0, 0644, "/data/local/resolv.conf");

set_perm(0, 0, 0755, "/data/xbin/set_resolvconf");

There is more, but the rest seems to be non-important...
[HD2 Android NAND Development] zexmunze:
Thanks mate!!!!Really appreciate your help!!!

And my problems are gone,new base ported LOL
[HD2 Android NAND Development] thelonewolf_pav:
my pleasure :)
[HD2 Android NAND Development] thelonewolf_pav:
hey guys,

just wanted to share some info that I've got from Marc, the kernel dev.

the kernel that we're all using is a non-sense kernel. this means that we will NEVER have bluetooth working (and probably some other features) until someone will compile a sense kernel for us.

currently, there is no ICS or JB sense kernel available for HD2.

so, if one of you guys has a linux machine and wants to get into kernel building business, please PM me and I'll tell you what needs to be changed to get us a sense kernel...
[HD2 Android NAND Development] Robbie P:
So has anyone offered to make sense of this yet?;):)

I would have thought [MENTION=1660048]Daekin[/MENTION] would be perfectly suited for the job :fingers-crossed:
[HD2 Android NAND Development] gilbert32:
i talked with him about it some time ago, he said he wants to finish his updated build of his rom and later he'll turn his attention to sense 4.x . i'm pretty much sure he can make a lot for sense 4 :)
[HD2 Android NAND Development] thelonewolf_pav:
well...

what if I tell you guys that I have a fully working bluetooth now? : )))))))

I actually used my BT headset for a phone call couple of minutes ago )))

so, no kernel changes were required in the end... just the right settings in init.rc and in buid.prop and correct files in system/etc...

I need to dump my system folder now and compare it to the original, so I can be sure that I don't miss anything, and then I will be able to give you guys precise instructions how to fix it
[HD2 Android NAND Development] gilbert32:
I knew someone will do it. i had been trying different firmware files and settings in init.rc, never changed anything in build.prop

It was a matter of time before someone figures it out. Still, a sense kernel is required afaik. there are still many errors in logcat related to that (one of them is about when u plug the phone via usb). and maybe it will have something to do with graphic glitches, even though they can be fixed like bluetooth. Thanks a lot! (sorry out of thanks:D)
[HD2 Android NAND Development] gilbert32:
Remember this? i hope your download haven't finished yet :p cz what you said finally happened
[HD2 Android NAND Development] :
Never? please, Google Nexus One does not have a sense kernel, but they have 4.0 w/ working bluetooth?
[HD2 Android NAND Development] tommypacker:
Bluetooth works on arca92's sense 4 Rom, but I think he uses a sense kernel

Sent from my Infuse 4G with Scott's BEANSTALK ROM
[HD2 Android NAND Development] :
Quite sure he does not. Maybe its the HTC nexus one, but the kernel is made by Google. :)
[HD2 Android NAND Development] tommypacker:
Kernel is Evervolv

Sent from my Infuse 4G with Scott's BEANSTALK ROM
[HD2 Android NAND Development] :
ok
[HD2 Android NAND Development] Robbie P:
Still downloading.....:p

Seriously, excellent job you guys are doing. It has been a pleasure seeing it all unfold. Sorry, not had time to help (if I possibly could:o) and all out of thanks for now;)

Best of luck
[HD2 Android NAND Development] gilbert32:
Hehe Thanks :p

i was very shocked when the phone booted, more shocked when i seen the init logo, and even more shocked when i saw live bootanimation. I'm still not believing my kernel worked and sense 5 launched :p
[HD2 Android NAND Development] i_4_u89:
HTC HD2 Rom Sense 4.0

Thank you for this work

hello bro can u give me a new link cos this link not working

no any rom there u have then give and u fixed all working rom of sense 4.0 ????

i wont to use this rom for ever so plz fix all bugs and make good one

Thank you

sorry for my bad English
[HD2 Android NAND Development] ya5:
working ROM

Anyone interested downloading working version of this magnificent ROM ???

I found files in this thread and put it together, wrote some code here and there.

Can be used as daily driver.

Main issues: Voice Rec, Video Playback, Video Rec, Bluetooth, Wi-fi Theter

CLK, EU Version. 5/250/5

Fast

Great RAM

Battery friendly / left for 5 days with data on, and still got some jucie.

Just let me know if u want it. I'll upload and give the link here.
[HD2 Android NAND Development] Robbie P:
Yes Please, sounds great.:cool:
[HD2 Android NAND Development] ya5:
The link : https://drive.google.com
[B][U]Link temporary removed. will be back soon.[/U][/B]
[HD2 Android NAND Development] ya5:
HD2 Sense4 - New Link, daily use ROM

Hello,

I Give you a almost fully Working ROM It can be used as DAILY.

If anyone wishes to help fix few cons that left it will become a fully working.

ChangeLog

fixed initrd / Thanks to Tytung

fixed install script / ya5

fixed low sound bug / ya5

native sd-ext mount / ph03n!x

Changed Weather.apk / i dont know from where i got it but it works

Changed WorldClock.apk / i dont know from where i got it but it works

Sreenshots

Look @ post #1

Working List

Data: yes

WiFi: yes

Sound: yes

Calling: yes

message: yes

Weather: yes

Clock: yes

Compass: yes

Rotation: yes

USB Mount: yes

USB Tether: yes

Multilingual: yes

Bluetooth: no

FM Radio: no

Sound Rec: no

Video Rec: no

Video playback no

Installation

Make sure you have set partition as below. Just Flash it.

Boot 5 MB / System - 300 MB / Cache - 5 MB

SD-EXT - 2GB

Links

https://drive.google.com/open?id=0B6nId7MX8fC7NmNWeERlMHotSHc

Credits

Big Thanks for you Guys. For all contribution put into hd2 development and making it possible.

WKY , Kane159, Tytung, Pixelfreak, Glibert32, Robbie P, ph03n!x
[HD2 Android NAND Development] philipped346:
someone has succes to instal this rom , i have stuck at "formating system" in updater-script .

download again and same result , don't understand !
[HD2 Android NAND Development] degman:
Try to download it again. My downloaded file was corupted four or five times....
[HD2 Android NAND Development] ya5:
Never had problems like that.

To be sure the file isnt corupted, i did downloaded it. Made a clean install. And viola, working like a charm.

Feel free to give some feedback or some tips to make it more complete. Now im working on bluetooth and improving speed of the rom
[HD2 Android NAND Development] philipped346:
ok , i have do a task on my hd2 . now instal is ok with 5/300/5 and ext4 2go . i have magldr and no kernel to boot on nand(kernel open failed). ok no panic , i have extracted initrd and zimage from kernel and booted from sd and now all is ok for me :D

the rom is very smooth , good work and go on :good:
[HD2 Android NAND Development] thinhx2:
please update sense7
[HD2 Android NAND Development] ya5:
Update,

Bluetooth Fixed

FM Radio Fixed - using spirit FM.

To do:

OMX

Stock Radio apk.

Improve speed of the rom.
[HD2 Android NAND Development] ya5:
Hello guys, some Christmas presents is coming. I will upload when the first star arise :P

Update:

GPS - ok

Beats - ok

Rom speed - ok / flying like hell :)

To do:

Still OMX

Native FM
[HD2 Android NAND Development] IAMLEGENDZ:
This is interesting , thank you my friend , can you make NativeSD version and support haret ?
[HD2 Android NAND Development] ya5:
Hi,

First I wish to make it all work what's possible and I'm able to. After that i might think about NSD or so.

Meanwhile - catch a nice screenshot. I won't upload nothing more right now, it is just not working out of the box and as i wish to.

[IMG="listening to radio right now :)"]http://imgup.pl/di/NLEN/screenshot.png[/IMG]
[HD2 Android NAND Development] werty100:
Where is lastest rom download?¿
[HD2 Android NAND Development] ya5:
Update

Got some progress with audio recording.

Sound recording is starting but no file is created in sdcard
[HD2 Android NAND Development] ya5:
Hi again,

Its have been some time since last update but:

I changed the Rom base, not wky rom form the OP.

using pixelfreak 3.0.101 kernel. for ICS Sense 4.0a

more or less working voice recording

USB/UMS working native - no 3rd app needed

omx should work.

Have some more work to do - but ill let u know in this thread about progress and possible upload new build to test.
[HD2 Android NAND Development] dalfshiro:
Thanks for info gilbert.really want to see this rom running on my hd2.but i dont know what to do with adb shell.hope someone can make it run via nativeSD :o
[HD2 Android NAND Development] gilbert32:
i hope too. i guess i was lucky when it worked a few times with me. still trying to figure out how it worked.

I really hope some dev work on this rom, it needs some work. especially the installer. maybe use dataonext instead of ad2sd, a better installer and have it copy all framework files to nand not sd-ext as there will still be some (a lot of) space left.

---------- Post added at 06:01 PM ---------- Previous post was at 05:29 PM ----------

i'm posting again to clearly mention how to boot this rom (as it works for me):

after DHD bootanimation shows up, wait ~ 10 seconds and connect phone to pc.

use adb shell and type:

cd /system/etc/init.d

mkdir /sd-ext

sh 40a2sd

you're done

This is for EU hd2, i dunno about the tmo version if it boot correctly (installing as TMO on eu doesn't work for me)
[HD2 Android NAND Development] kane159:
just see the edit, ok, i'm trying,sp dont need to move framework anymore?

why dont u try install Tmobile's selection? then all stuff will in nand then try data2ext :o
[HD2 Android NAND Development] gilbert32:
tried installing tmo, it needed a big data partition (>60mb im sure) and i was too lazy to go for it twice. Tmobile installation has the same problem i think

not sure about moving the framework, should work without it. you'd know with logcat after starting a2sd as the output will change
[HD2 Android NAND Development] kane159:
ok...so i maybe understand why mine eu version dont boot....couse my recovery set 8MB sboot 5MB EXTROM DISABLE....so my data partation is only 23M....
[HD2 Android NAND Development] gilbert32:
yeah. with a2sd, it would use 10-20M from data. Enable extrom, and shrink system partition.Titanum backup shows 106mb free with partition size of 387 (i set it for 370). try system partition 300M
[HD2 Android NAND Development] dalfshiro:
What about reboot phone?still need using that step again?
[HD2 Android NAND Development] gilbert32:
yes, you still have to do it again.

Unfortunately i don't know how to auto-mount the sd-ext or how to autostart a2sd script, or if it's supposed to and not working, how to fix it.

Until now, i'm amazed by it's speed, and possibly using it as a daily driver. a few problems? who needs sound or wifi anyway?:P
[HD2 Android NAND Development] Stensfie:
Can you make a video to show this rom....??? Thanks man
[HD2 Android NAND Development] gilbert32:
i'm sorry but i can't. my internet connection is HORRIBLY slow, and traffic is too limited. besides, it's 11 pm here. if someone else booted it, maybe he can make a video if he wants
[HD2 Android NAND Development] GODISMYCOPILOT:
ive managed to get it to boot in nand ok but i removed a lot of bloatware from it but ive not a lot of space left
[HD2 Android NAND Development] dalfshiro:
Maybe you can give us tutorial using pic please.at least begin from adb shell.thanks
[HD2 Android NAND Development] aazzam16661:
Now that's a really good idea. right now having troble in adb how to pull framework from sd ext and then push back to system.
[HD2 Android NAND Development] kane159:
finally finally!!! boot on eu version

here is the simple GUIDS

1.

2.flash the rom , choose eu version

after flash, dont reboot, connect your phone to pc then type this

adb shell
mount /system
mkdir framework
exit

then type adb push ←here have a space

see the pic

after drop, keep typing /system/framework

like the pic

push enter

ok, now reboot

after boot animation stop

type these

adb shell
cd /system/etc/init.d
mkdir /sd-ext
sh 40a2sd

ok, not it'll boot

every time u reboot u need to do this again

after boot animation stop

type these

adb shell
cd /system/etc/init.d
mkdir /sd-ext
sh 40a2sd

annoning hun, jajajaja
[HD2 Android NAND Development] aazzam16661:
What is your system partition?

and thanks