Related
Hi all,
I realize this is a post about a Motorola phone but please bear with me.
As you might know, the Milestone firmware is firmly locked, unlike its cousin Droid. Among many things, this forbids overclocking because we can't change the kernel and unlock new frequencies.
However I developed a solution that allows overclocking by changing key structures directly in the kernel memory in runtime. All you need is a rooted phone; no flashing involved. For this to work, the module must know two memory addresses that are specific to each kernel. Fortunately, Motorola appears to have reused its kernel on most 2.1 firmwares, and I've yet to come across a firmware where it doesn't work by default. Confirmed working are Central Europe, Telus and Brazilian firmwares. Testers are welcome to give it a try.
Now for the relevant part for XDA: in theory this can be applied to any kernel on any other phone. You may say it's unneeded because you can already overclock; but you must flash a specific kernel to get a particular speed. It would be much better to be able to set any maximum frequency/voltage on the fly without flashing or rebooting. For instance, you could overclock to 1.0 GHz before a browsing or gaming session and then return to a lower frequency like 600 MHz, though still overcloked, for battery savings and safety. It's up to you.
Milestone users can try it out now:
http://code.google.com/p/milestone-overclock/
For the rest of you, what do you think?
sounds fantastic, I'd love to check it out but for the life of me I can't find the page.
If you want to pm it to me, I'll post it.
Nice. Telus Milestone User here. Would love to learn how to do this for mine.
Here is the project link:
http://code.google.com/p/milestone-overclock/
found it. looks like a fantastic idea.
How can we help get the addresses?
awesome .....wht there is no milestone/droid section here is beyond me ....wtf
Because it was decreed months ago by someone and no one seems to like changing their mind once they make a decision in this day and age.....
but it's need to root, could you fix it?
stevecai said:
but it's need to root, could you fix it?
Click to expand...
Click to collapse
what's the problem with rooting the milestone? There's plenty of solutions for that. Just no custom kernel/ramdisk, which this works around by using a kernel module.
hi,
i use the 2.1-reu version on my milestone,
but in order to prevent the 2.1 introduced alarm bug,
i have updated the kernel (only) to the 2.1-telus
(via a sbf).
is possible to use this mod to overlock my phone?
how?
if not, how help you to obtain the addresses?
thank's and continue your great work!
robert
gemini002 said:
awesome .....wht there is no milestone/droid section here is beyond me ....wtf
Click to expand...
Click to collapse
XDA is a HTC developer forum, not an Android forum. Google some moto modding sites, i know modmymoto.com is pretty good, found out how to root the Cliq (garbage) there.
staticshadow said:
XDA is a HTC developer forum, not an Android forum. Google some moto modding sites, i know modmymoto.com is pretty good, found out how to root the Cliq (garbage) there.
Click to expand...
Click to collapse
I have read this explanation several times.
I do not mind, but then because there are subforums dedicated to sonyericsson, hp, etc in xda.
modmymoto is good but the best developers site is, withous any doubt, xda-developers!
Re: milestone-overclock
Xda-developers is for htc and android is for porn.
Welcome to xda btw and great job. Now prepared to be flamed for uttering the M word.
-------------------------------------
sent via xda app from my milestone
ady said:
android is for porn.
Click to expand...
Click to collapse
are you Steve Jobs ?
miragu said:
Hi all,
Now for the relevant part for XDA: in theory this can be applied to any kernel on any other phone.
Click to expand...
Click to collapse
Will the method to find the right address that will be posted at /wiki/Disassembly work with every phone and kernel,too?
Has the app something like a setting where you can just change the address to the one you found with the method above?
Would really love an overclocked 2.1 on the HTC HERO. There is no oc-2.1-kernel for the Hero, yet.
Thanks for the great work, til now!
this is a good via to mod any application.
please, publish the source code of your applicacion ASAP.
thx
Source code for the kernel module released
Hi all,
Thank you for your support. I've just uploaded the source code for the kernel module and also the standalone module itself (it's included in the apk but still). Will write the Disassembly section soon, stay tuned.
miragu said:
Hi all,
Thank you for your support. I've just uploaded the source code for the kernel module and also the standalone module itself (it's included in the apk but still). Will write the Disassembly section soon, stay tuned.
Click to expand...
Click to collapse
hi,
i'm interested on include this in my system applications directory,
in order to prevent your deletion on hardreset, and in order to make it available FOREVER
the instructions are that:
cp OverClock.apk /system/app
cp OverClock.ko /system/lib
????
thx
The overclock.ko is created automatically when you press the "Load module" button in /data/data/pt.com.darksun.milestoneoverclock/files/overclock.ko. You don't need to copy it. I'm providing it separately so that people can load/bundle it without ever running the apk.
bartito said:
hi,
i'm interested on include this in my system applications directory,
in order to prevent your deletion on hardreset, and in order to make it available FOREVER
the instructions are that:
cp OverClock.apk /system/app
cp OverClock.ko /system/lib
????
thx
Click to expand...
Click to collapse
ok,
if i'm interested on have overclocking on my milestone after boot the system, and don't interested on manually execute the apk on each reboot, i need only to copy the OverClock.ko to /data/data/pt.com.darksun.milestoneoverclock/files/overclock.ko on boot time ?
but in your wiki page says to execute "insmod overclock.ko max_rate=800000 max_vsel=62"
please, provide me instructions to set overclock in boot time
The module created by the apk is preserved across reboots. However, if you want to run the module completely standalone I recommend you put it in /data/local/overclock.ko and run insmod /data/local/overclock.ko max_rate=800000 max_vsel=62
Thanx to Viruscrazy!! also no audio stutter any more!!
http://forum.xda-developers.com/showthread.php?t=883966
Read install and enjoy
Spige
Spige said:
Thanx to Viruscrazy!! also no audio stutter any more!!
http://forum.xda-developers.com/showthread.php?t=883966
Read install and enjoy
Spige
Click to expand...
Click to collapse
Note that this is intended for testing purposes. Code is not clean yet and may contain undiscovered bugs. If you use Android for your everyday activity make a backup of all your files before trying. I'm helping with testing on my second SD card but I'll wait for it to get committed into "mainline" kernel before I switch to my "everyday" system.
g3rm0 said:
Note that this is intended for testing purposes. Code is not clean yet and may contain undiscovered bugs. If you use Android for your everyday activity make a backup of all your files before trying. I'm helping with testing on my second SD card but I'll wait for it to get committed into "mainline" kernel before I switch to my "everyday" system.
Click to expand...
Click to collapse
...where's the fun in having stable system with no bugs i mean we all came from wm which was fun to play with because every time it was a new adventure hehe just kidding, you've got the point,now people from xdandroid have to get the code and implement it in frx05 or maybe gb*** since neopeek booted gingerbread on his diamond
wowww amazing...
how to use it??
May be you can give Step by Step on this Thread. For all Blackstone user
There was already a thread about this in this forum, here. The complete instructions are in the main thread though.
Hi
Everything workin just fine exept speakerphone.....camera wifi etc...
Spige said:
Everything workin just fine exept speakerphone.....camera wifi etc...
Click to expand...
Click to collapse
Hi, Spige,
When you mention camera working, does that mean including the 5Mpix?
3MP works fine for me with (almost) latest viruscrazy kernel, but I haven't been able to get 5MP working, did you?
If you're ahead of the others, please keep us informed of exact android build / modules, etc you're using!
Cheers,
Robbert
---
XDANDROID 2.2.1 AOSP FRX04 on blackstone (690 MHz), viruscrazy test kernel for audiostuttering fix and camera (3Mpix) test.
aladin said:
wowww amazing...
how to use it??
May be you can give Step by Step on this Thread. For all Blackstone user
Click to expand...
Click to collapse
Instructions are clear, as Eodun mentioned, if you get stuck somewhere specific, post and we'll help you out, of course!
Maybe one important thing to add:
I noticed you're using an eclair build, I personally never got camera working on the couple eclair builds that I tried. (nor proper headset detection, which was a dealbreaker)
Maybe someone can confirm if camera is even possible at all on eclair, before aladin keeps on trying with his (which specific?) build?
Cheers,
Robbert
---
XDANDROID 2.2.1 AOSP FRX04 on blackstone (690 MHz), viruscrazy test kernel for audiostuttering fix and camera (3Mpix) test.
Hi there,I'm trying to port the SDK dump to my LG P500,which has the same specs like ZTE Blade.
After applying normal methods for making other phones' roms boot and a special patch found here it doesn't even give logcat,so bootloops in recovery.
After doing some research,I discovered that libs are built for armv7,which we don't have. But also Honeycomb SDK libs were built from armv7,but we got it working on both LG P500 and ZTE Blade.
So,any ideas? Just asking
I think honeycomb and below was build from armeabi (To run on the old simulator that was armv6 vfp (but the vfp wasn't used by google).
whereas ics was built for armeabi-v7a
That is certainly implied by the AVD manager anyway.
unrandomsam said:
I think honeycomb and below was build from armeabi (To run on the old simulator that was armv6 vfp (but the vfp wasn't used by google).
whereas ics was built for armeabi-v7a
That is certainly implied by the AVD manager anyway.
Click to expand...
Click to collapse
Thank you for replying
usually only kernel have ARM text and other also init.rc have kernel text if editing them to ARMv6 kernel text then it needs to work in ARMv6 device..
If not, then some files needs editing...
Android 4.0 ICS needs new EGL and hw files which needs to be ARMv6= ZTE Blade/other phone! all phones have own files to work fine!
If someone can edit Android 4.0 libGLES*.so, libEGL.so files and then egl folder files needs editing.. and then hw folder files for Screen, sensors, GPS, Audio, etc.
then them need right files to get work the audio, camera, WiFi...
WiFi files can work if you add older Android OS WiFi files: libhardware-legacy.so or what it is and then right WiFi files to /System/etc/
to get all to work it maybe takes many days and for me more than 9 months because I'm only 14! xD
SDK port is maybe not really good, it's better to port from other device ex: Samsung... then some files works without editing...
manumanfred the sdk was compiled for ARMv7, it's a different cpu, different machine code. It needs recompiling, to be able to do that you need the source code to compile it.
Without source code you're about as likely to get ICS running on your Blade as you are to get your PS3 running Windows 7.
When devices with ICS are available source code will be too, so porting it from another device would be a waste of time.
wbaw said:
manumanfred the sdk was compiled for ARMv7, it's a different cpu, different machine code. It needs recompiling, to be able to do that you need the source code to compile it.
Without source code you're about as likely to get ICS running on your Blade as you are to get your PS3 running Windows 7.
When devices with ICS are available source code will be too, so porting it from another device would be a waste of time.
Click to expand...
Click to collapse
its not hard to get ICS on zte blade as zte blade got a test verision of ICS
SWEATTAIMI said:
its not hard to get ICS on zte blade as zte blade got a test verision of ICS
Click to expand...
Click to collapse
Are you sharing it?
If not, it's still pretty hard.
http://forum.xda-developers.com/showthread.php?t=1312595
anyone please check this out maybe this can work
http://groups.google.com/group/android-building/msg/c0e01b4619a1455a?pli=1
Android ICS sourcecode is released! I belive that now in Cyanogenmod headquaters people hear red alert
uosiumen said:
http://groups.google.com/group/android-building/msg/c0e01b4619a1455a?pli=1
Android ICS sourcecode is released! I belive that now in Cyanogenmod headquaters people hear red alert
Click to expand...
Click to collapse
uosiumen said:
http://groups.google.com/group/android-building/msg/c0e01b4619a1455a?pli=1
Android ICS sourcecode is released! I belive that now in Cyanogenmod headquaters people hear red alert
Click to expand...
Click to collapse
Fail, u cant grab anything
Sent from my Transformer TF101 using xda premium
ICS on the Blade is booting!
But that's all it does
I used this ROM and replaced boot.img with CM N257. In the honeycomb port they fixed the flipped screen with patching libsurfaceflinger.so on offset 1AC90 but that does not work on ICS. Launcher FC's on first boot but does not after reboot.
Could you please upload that booting rom? I tried it and it won't even install. Even if nothing works, I would like to try several things on that to see if I can fix it, so if you upload it I would be very thankful
davidnintendo said:
Could you please upload that booting rom? I tried it and it won't even install. Even if nothing works, I would like to try several things on that to see if I can fix it, so if you upload it I would be very thankful
Click to expand...
Click to collapse
Take a working Rom for zte, and replace everything except build.prop and meta-inf folder
Sent from my LG-P500 using xda premium
FezzFest said:
ICS on the Blade is booting!
But that's all it does
I used this ROM and replaced boot.img with CM N257. In the honeycomb port they fixed the flipped screen with patching libsurfaceflinger.so on offset 1AC90 but that does not work on ICS. Launcher FC's on first boot but does not after reboot.
Click to expand...
Click to collapse
So correct me if im wrong, but you got ics booting on blade by using the g2 rom and boot.img from CM7 Latest nightly?
If so maybe start a new thread to track progress.
furrabbit.nh said:
So correct me if im wrong, but you got ics booting on blade by using the g2 rom and boot.img from CM7 Latest nightly?
If so maybe start a new thread to track progress.
Click to expand...
Click to collapse
LGP500 got bootloop on that, but thats our phone, so thats maybe work yes
SWEATTAIMI said:
LGP500 got bootloop on that, but thats our phone, so thats maybe work yes
Click to expand...
Click to collapse
I just tried it 10mins ago, it installs fine does not boot at all, no logcat output... Wonder if he/made any tweaks elsewhere.
I have a O1 somewhere might dig it out, and have a look
I got it booting! Screen is fliped, touchscreen doesn't seem to work at all and I couldn't test anything else because I can't press OK on the first tutorial screen, but it may be something to start with!
I'm uploading it right now, but I think it will take a while as my connection isn't working very well right now, but I'll post the link as soon as it's finished.
EDIT: OK. You'll have to be patient. Apparently, my 20 MB symmetric shared connection doesn't want to upload faster than 50 KB/s. It's always like this in the afternoon: too many people using it LOL. Hopefully it will be uploaded in 25 minutes or so.
davidnintendo said:
I got it booting! Screen is fliped, touchscreen doesn't seem to work at all and I couldn't test anything else because I can't press OK on the first tutorial screen, but it may be something to start with!
I'm uploading it right now, but I think it will take a while as my connection isn't working very well right now, but I'll post the link as soon as it's finished.
Click to expand...
Click to collapse
Thanks
Sent from my LG-P500 using xda premium
OK, fixed flipped screen & resolution. Thanks to smg22rus for the modified libsurfaceflinger.so.
Flashable ROM (for devs only!) can be found here
If you fix something, just post what you did to get it fixed, do not upload the whole ROM again.
That way, this thread stays clean & we have only one ICS ROM (not 10 different ones).
Hi hackers,
i know about the common method described by chulri, to compile custom kernels and it works well.
Anyway for kernel only experiments this way is little too bloated.
EDIT3:
So here's my standalone toolchain for archos (build with modified buildroot system for 32Bit linux OS):
arm-archos GCC4.4.1 for ARM uClinux (uClibc C library 0.9.30 with Archos specific tweaks and bugfixes)
http://dl.dropbox.com/u/8815400/arm-archos.tar.gz
EDIT5:
The toolchain does not work on a 64Bit OS.
I'll post a link for the 64Bit version soon.
Only for reference:
There are a lot of external solutions to be found in the web.
E.g. there are different flavoured toolchains based on gcc 4.4.1 from Mentor Graphics (formerly known as Codesourcery):
Sourcery G++ Lite 2010q1-188 for ARM EABI (Newlib C library 1.17.0)
Sourcery G++ Lite 2010q1-189 for ARM uClinux (uClibc C library 0.9.30)
Sourcery G++ Lite 2010q1-202 for ARM GNU/Linux (GNU C library 2.11)
So if i restrict my activities on kernel compilation all three should do the job.
I made a custom kernel using the above mentioned GNU C toolchain, all compiles fine, but did not test it yet.
This is next... i need to find an easy way to test my tweaked kernels.
So far i would recommend UrukDroid running and use the recovery menu to exchange the kernel & ramdisk.
Any comments are welcome.
Unfortunately our devices use also some binary only kernel modules which are not supported by this method:
hmditx.ko (though marked as GPL, we got no sources)
hdmicec.ko (same here)
UPDATE: Sources had been published by Archos at gitorious.
nwolc.ko (proprietary module from NXP)
BTW, someone should contact the author Andre Lepine to hand out the GPL'ed source code
If i got it right, all custom kernels had been build using the buildroot system because of these.
AFAIK using another toolchain would result in a completely different system map and prevent the modules to load.
Anyway if we exclude HDMI and tweak some start scripts to prevent the modules to get loaded, we'll be fine.
Would be nice to start some discussion up here or leave a comment.
I'd also like to get some tricks form the cracks
EDIT:
Sure there's also Ti's wireless driver package which has to be integrated to compile tiwlan_drv.ko.
Need to do some research to find the correct package.
Any hints are welcome!
EDIT2:
Anyone tried to compile a gen8 kernel using the new gen9 kernel source?
Everything seems to be there...
EDIT4:
See above! The toolchain works very nice.
It had been specially compiled for external use and in the meantime it was tested on many different hosts.
Instructions how to install and use it could be found here:
http://forum.xda-developers.com/showpost.php?p=19134490&postcount=8
Thanks a lot for your attention!
Regards,
scholbert
One question: What's so much better about that toolchain to throw away the Archos-compatible toolchain and deal with the hassle of excluding features to build compatible binaries? I guess I didn't get the point
chulri said:
One question: What's so much better about that toolchain to throw away the Archos-compatible toolchain and deal with the hassle of excluding features to build compatible binaries? I guess I didn't get the point
Click to expand...
Click to collapse
Like i tried to point out:
Anyway for kernel only experiments this way is little too bloated.
Click to expand...
Click to collapse
A neat little cross toolchain environment would be enough for kernel experiments.
I'm working on different platforms e.g. old Debian 4.0 workstation, Netbook with UNR 11 but limited space, other linux machines i don't like to run entire process.
You need a lot of disk space and time (at least first time to build the whole environment).
The other thing is that everything is built into the buildroot structure, you could barely locate the toolchain itself...
Sure your right, if you say everthing works out of the box, but i don't like all these automated procedures, to build my own kernel.
In fact that's just it and i wonder if there's another way.
Just kernel source + cross-toolchain...
Apart from that, the toolchain Sourcery G++ Lite 2010q1-189 for ARM uClinux (uClibc C library 0.9.30) is very close to the Archos one.
BTW, anyone tried to tweak the Archos build script to built the toolchain for external use?
Cheers,
scholbert
scholbert said:
So if i restrict my activities on kernel compilation all three should do the job.
I made a custom kernel using the above mentioned GNU C toolchain, all compiles fine, but did not test it yet.
Click to expand...
Click to collapse
Hi Scholbert!
I've been doing the same for my kernels, it compiles and runs fine, wifi loads without any particular tweak with the original Archos compiled module, but I didn't check hdmi as I don't have cable for it. I'm using a cm7 toolchain to build it (arm-eabi-4.4.3) though.
scholbert said:
This is next... i need to find an easy way to test my tweaked kernels.
So far i would recommend UrukDroid running and use the recovery menu to exchange the kernel & ramdisk.
Click to expand...
Click to collapse
My setup is a bit different since I patched bootloader: I have my "stable" build on normal boot (/rawfs/init) and my dev build on sde (/rawfs/custom), and I flash my kernel directly from my stable build without going through recovery.
I just do adb push kernel and initrd, then directly on device a "kd_flasher -k kernel -i initrd", and I reboot from normal to sde with a "reboot_into sde". It's really quick this way, I just have a script on my linux box to do all this.
I believe you can do the same without patched bootloader with a temproot on secure archos build.
scholbert said:
EDIT2:
Anyone tried to compile a gen8 kernel using the new gen9 kernel source?
Everything seems to be there...
Click to expand...
Click to collapse
Yes, I'm playing with it. I don't know what device you have, but mine (A70S) was not finished in Archos sources: board-archos-a70s is almost empty, panel wasn't finished... I add stuff slowly (still learning Omap, I know Qualcomm better), my kernel boots, I currently have framebuffer, internal mmc and usb working.
Hi letama!
letama said:
I've been doing the same for my kernels, it compiles and runs fine, wifi loads without any particular tweak with the original Archos compiled module, but I didn't check hdmi as I don't have cable for it. I'm using a cm7 toolchain to build it (arm-eabi-4.4.3) though.
Click to expand...
Click to collapse
Cool that's nice information.
Interesting that the tiwlan_drv.ko loads without problems.
Just to start an experiment, i started to shrink down the buildroot setup from Archos and built the gcc 4.4.1 toolchain only.
But it's not finished yet...
letama said:
My setup is a bit different since I patched bootloader: I have my "stable" build on normal boot (/rawfs/init) and my dev build on sde (/rawfs/custom), and I flash my kernel directly from my stable build without going through recovery.
Click to expand...
Click to collapse
O.k. i see, sounds like a clean environment this way.
In fact there's no need for this sqashfs thing anymore...
I already got the SDE's avboot version installed. This version is little bigger in size and obviously got some add-on's.
The same byte signature could be found here, so i guess the hack would match this avboot version as well.
Maybe i give it a try.
letama said:
I just do adb push kernel and initrd, then directly on device a "kd_flasher -k kernel -i initrd", and I reboot from normal to sde with a "reboot_into sde". It's really quick this way, I just have a script on my linux box to do all this.
Click to expand...
Click to collapse
Cool, sounds like a nice development platform this way.
letama said:
I believe you can do the same without patched bootloader with a temproot on secure archos build.
Click to expand...
Click to collapse
Mmmh i thought about using it from UrukDroid...
Anyway, the way you do it sounds more elegant.
letama said:
Yes, I'm playing with it. I don't know what device you have, but mine (A70S) was not finished in Archos sources: board-archos-a70s is almost empty, panel wasn't finished... I add stuff slowly (still learning Omap, I know Qualcomm better), my kernel boots, I currently have framebuffer, internal mmc and usb working.
Click to expand...
Click to collapse
I got an A101... looks little better here, but i did not compile the kernel yet.
Anyway, would be nice to have a complete kernel (incl. wireless and HDMI base code) in the end which compiles fine with latest gcc and runs out of the box
Thanks a lot for your extensive reply!!!
Regards,
scholbert
scholbert said:
I already good the SDE's avboot version installed. This version is little bigger in size and obviously got some add-on's.
The same byte signature could be found here, so i guess the hack would match this avboot version as well.
Maybe i give it a try.
Click to expand...
Click to collapse
Yes, it's the same signature, I verified it with IDA before installing sde, only location differs. You should be fine as long as you don't have multiple matches. If you want my code to patch it, let me know... You'd have to adapt the offsets but it would be probably safer than doing it manually.
Regarding kernel development, I forgot one big advantage to have patched bootloaders: ram_console! I built my "stable" and "dev" kernels with it, so I just have to make my dev kernel to crash to reboot and get the full dmesg with "cat /proc/last_kmsg" even if framebuffer or usb don't work .
scholbert said:
I got an A101... looks little better here, but i did not compile the kernel yet.
Anyway, would be nice to have a complete kernel (incl. wireless and HDMI base code) in the end which compiles fine with latest gcc and runs out of the box
Click to expand...
Click to collapse
Yes, gen9 sources look better for A101, I took them as base for my A70 and it's almost ok. I took away hdmi as it seems a bit too hackish, I'll see later . I also had some issue with gp timers that wouldn't use 32K clock, I'd be curious to see a dmesg on a gen9 tablet.
Right now I'm fighting with usb that kills video driver looonng way to go before having a fully functional kernel.
letama said:
Yes, it's the same signature, I verified it with IDA before installing sde, only location differs. You should be fine as long as you don't have multiple matches. If you want my code to patch it, let me know... You'd have to adapt the offsets but it would be probably safer than doing it manually.
Click to expand...
Click to collapse
Thanks for offering your tool.
Guess it's the same you once posted in that thread about changing bootlogo.
I had a look at the soruces once.
Anyway i already prepared a patched bootblock. Did not re-write it yet
Time is lacking...
letama said:
Regarding kernel development, I forgot one big advantage to have patched bootloaders: ram_console! I built my "stable" and "dev" kernels with it, so I just have to make my dev kernel to crash to reboot and get the full dmesg with "cat /proc/last_kmsg" even if framebuffer or usb don't work .
Click to expand...
Click to collapse
Yupp that's nice... have you seen my UART hack?
letama said:
Yes, gen9 sources look better for A101, I took them as base for my A70 and it's almost ok. I took away hdmi as it seems a bit too hackish, I'll see later . I also had some issue with gp timers that wouldn't use 32K clock, I'd be curious to see a dmesg on a gen9 tablet.
Right now I'm fighting with usb that kills video driver looonng way to go before having a fully functional kernel.
Click to expand...
Click to collapse
Guess i will try to compile this kernel soon.
No time for that right now.
Made some efforts to built special toolchain.
See the upcoming post...
Big thanks for participating!!!
Regards,
scholbert
Ready to use Archos specific toolchain
Hi again,
three simple steps to build UrukDroid custom kernel/modules:
1. Grab my customized toolchain and install it (see first post).
The toolchain is configured to work on mostly any 32Bit linux host (min. libc 2.3.6, should work down to Debian 4.0, Ubuntu 8.04 and similar).
The toolchain must be extracted and placed at /opt on your host machine (x86).
To run it as a user you might change the properties for /opt directory to match the user's rights.
You also could extract the archive as root and run:
chown -R 1000:1000 /opt/arm-archos
To make it more comfortable:
Modify user's .bashrc file to include the path to the toolchain:
export PATH=$PATH:/opt/arm-archos/usr/bin
2. Grab UrukDroid kernel sources and compile.
UrukDroid kernel sources could be found here:
http://sauron.pourix.com/UrukDroid/UrukDroid-1.5/UrukDroid-1.5.1-kernelsrc.tar.bz2
You might extract the sources anywhere you like.
After this has been done, step into the kernel source root directory.
Modify Makefile to use the Archos toolchain (line 199):
Code:
...
# Alternatively CROSS_COMPILE can be set in the environment.
# Default value for CROSS_COMPILE is not to prefix executables
# Note: Some architectures assign CROSS_COMPILE in their arch/*/Makefile
export KBUILD_BUILDHOST := $(SUBARCH)
ARCH ?= $(SUBARCH)
CROSS_COMPILE ?= arm-linux-uclibcgnueabi-
...
cp linux.config .config
make oldconfig
make zImage
make modules
make modules_install INSTALL_MOD_PATH=/my_kernel/modules/
3. Transfer the binaries to your Archos device.
Right now there's no need to exchange the kernel, because we use $auron's base setup for the kernel.
Place your custom modules at /lib/modules
TBC
scholbert
scholbert said:
Thanks for offering your tool.
Guess it's the same you once posted in that thread about changing bootlogo.
I had a look at the soruces once.
Anyway i already prepared a patched bootblock. Did not re-write it yet
Time is lacking...
Click to expand...
Click to collapse
Yes, it's roughly the same code. You did patch both location ?
scholbert said:
Yupp that's nice... have you seen my UART hack?
Click to expand...
Click to collapse
Yes, saw it, it would be very nice to have console on serial, but I don't want to open my A70 yet as it's still has warranty running. I may try that if I can find parts and if I get a gen9 as "main".
scholbert said:
Guess i will try to compile this kernel soon.
No time for that right now.
Click to expand...
Click to collapse
Great! Let me know if you have something, I'd be very interested in a dmesg.
I somehow "fixed" my video driver problem (well, not really fixed, adding traces made it go away ), now I'm trying to get SurfaceFlinger works. Sgx driver doesn't seem to play nice with .29 userspace binaries, I'm not sure I'd be able to go much further without new binaries.
scholbert said:
Made some efforts to built special toolchain.
See the upcoming post...
Click to expand...
Click to collapse
Nice! I'll try to take a look at it when I find some time.
Hey letama,
sorry for the delay...
letama said:
Yes, it's roughly the same code. You did patch both location ?
Click to expand...
Click to collapse
Yepp, both locations are patched.
As we already pointed out, there the rawfs header contains some checksums and avboot is the first file in there.
What do you think, if i manually change some bytes in avboot and leave the checksum untouched, will there be any problems?
letama said:
Yes, saw it, it would be very nice to have console on serial, but I don't want to open my A70 yet as it's still has warranty running. I may try that if I can find parts and if I get a gen9 as "main".
Click to expand...
Click to collapse
O.k. if there's warranty on your device, i totally agree.
letama said:
Great! Let me know if you have something, I'd be very interested in a dmesg.
Click to expand...
Click to collapse
Need more time
letama said:
I somehow "fixed" my video driver problem (well, not really fixed, adding traces made it go away ), now I'm trying to get SurfaceFlinger works. Sgx driver doesn't seem to play nice with .29 userspace binaries, I'm not sure I'd be able to go much further without new binaries.
Click to expand...
Click to collapse
Yeah guess there are some changes in the drivers API.
letama said:
Nice! I'll try to take a look at it when I find some time.
Click to expand...
Click to collapse
So far i tested it, the toolchain works out very nice.
Concerning kernel compilation:
It seems the binaries are quite well optimized in size. No problems so far.
I found out that in stock ROM they used some strip command to make the modules even smaller.
Anyway won't speed things up significantly i guess...
Concerning userland apps:
Though my genereated uClibc is little bigger in size, i noticed no problems so far. A binary comparison between the libaries (stock vs mine), shows little differences though.
Anyway, would be nice if people use it and report...
Have a nice day!
scholbert
Hi Scholbert!
scholbert said:
sorry for the delay...
Click to expand...
Click to collapse
No problem, I'm also busy as hell...
scholbert said:
Yepp, both locations are patched.
As we already pointed out, there the rawfs header contains some checksums and avboot is the first file in there.
What do you think, if i manually change some bytes in avboot and leave the checksum untouched, will there be any problems?
Click to expand...
Click to collapse
Well, I didn't touch checksums either, and it seems they're not checked anywhere else, so you should be good. As long as you patched both location before reboot, you should be ok.
scholbert said:
Yeah guess there are some changes in the drivers API.
Click to expand...
Click to collapse
I made some progress there, I took LG P970 3D binaries with driver source code from their cm7 kernel (they also have a 2.6.35) and I was able to boot up to launcher. I had to fiddle a bit with audio runtime as phone audio won't work, but low level audio driver is working too. Next step is touchscreen... And probably doing a proper cm7 build, I'm running a frankenstein mix of cm7 for nook tablet
scholbert said:
So far i tested it, the toolchain works out very nice.
Click to expand...
Click to collapse
I tried it briefly yesterday as I borked my kernel config at some point and it was crashing my usual toolchain, it doesn't run on my comp: "error while loading shared libraries: libmpfr.so.1: wrong ELF class: ELFCLASS64". Ubuntu 11.10 64 bits...
Best,
LeTama
letama said:
Well, I didn't touch checksums either, and it seems they're not checked anywhere else, so you should be good. As long as you patched both location before reboot, you should be ok.
Click to expand...
Click to collapse
Yeah guessed so... the russian guy who first tried this hack also never mentioned anything like this. So it'll be safe then.
letama said:
I made some progress there, I took LG P970 3D binaries with driver source code from their cm7 kernel (they also have a 2.6.35) and I was able to boot up to launcher. I had to fiddle a bit with audio runtime as phone audio won't work, but low level audio driver is working too. Next step is touchscreen... And probably doing a proper cm7 build, I'm running a frankenstein mix of cm7 for nook tablet
Click to expand...
Click to collapse
Wow sounds pretty like a "frankengenius" software design.
Good work!
Have you seen that Archos released part of the hdmi code as external driver code. So the kernel is even more open now (speaking of 2.6.29).
Sometimes their cooperation is very nice.
About two weeks ago i contact the author at NXP, then last week i wrote to Archos and on thursday they released it. Not bad...
Anyway they ought to release the source, even without mentioning it.
It's just GPL code.
letama said:
I tried it briefly yesterday as I borked my kernel config at some point and it was crashing my usual toolchain, it doesn't run on my comp: "error while loading shared libraries: libmpfr.so.1: wrong ELF class: ELFCLASS64". Ubuntu 11.10 64 bits...
Click to expand...
Click to collapse
Sure the toolchain is compiled for 32Bit systems, forgot to mention this.
So it will never work on a 64Bit system.... sorry
Cheers,
scholbert
scholbert said:
Have you seen that Archos released part of the hdmi code as external driver code. So the kernel is even more open now (speaking of 2.6.29).
Click to expand...
Click to collapse
Didn't see it, very nice! HDMI is a low on my priority list, but it's good to have source code, it will help porting it. Even though my efforts on this kernel will slow a bit as I purchased today a gen9 and ICS source code is out .
At first glance, boot process and layout looks very similar to our gen8, same rawfs, a custom file that would indicate that we should get SDE, so far so good. Need to spend some quality time with hex editor and IDA now .
Damn work, I need 72 hours days!
scholbert said:
Sure the toolchain is compiled for 32Bit systems, forgot to mention this.
So it will never work on a 64Bit system.... sorry
Click to expand...
Click to collapse
No problem, just wanted to give a bit of feedback.
@letama:
Wouldn't it be alot more productive for you and us if you would somehow join your affort with the guys from openaos?
cm7 and then cm9 would be here faster the more experienced devs are helping.
fzelle said:
@letama:
Wouldn't it be alot more productive for you and us if you would somehow join your affort with the guys from openaos?
cm7 and then cm9 would be here faster the more experienced devs are helping.
Click to expand...
Click to collapse
Hi fzelle,
Well, I'm only learning slowly, they're far more experienced than me on Archos. My main goal is to understand omap platform, that's why I'm toying with the 2.6.35 kernel. Cm7 is only a convenient for way me to make sure the kernel behaves well. I don't seek a perfect cm7/archos experience for all devices as they do, but if at some point I learned enough, I may try to help if I can.
LeTama
CM7 for Archos atm is based on the 2.6.29 kernel delivered from Archos, so your kernel is far more advanced.
And if you got 2.6.35 to work properly, the guys over at openaos would probably be happy to use that.
fzelle said:
CM7 for Archos atm is based on the 2.6.29 kernel delivered from Archos, so your kernel is far more advanced.
And if you got 2.6.35 to work properly, the guys over at openaos would probably be happy to use that.
Click to expand...
Click to collapse
Yes, 2.6.35 should match better gingerbread code. If I can go somewhere, I'll share it. Currently, I'm far from that, still having troubles with usb and a big piece will be power management. We'll see, but I'm a bit out of free time.
Hey letama,
i guess fzelle is right.
AFAIK, the openaos developers concentrate on the Android part for gen8. As stated they still use 2.6.29 and this no problem so far.
But a kernel project might run in parallel.
Would be nice to get the new kernel working at least for A70 and A101.
I started a build for A101 (...and still compiling), maybe we could share our .config file
EDIT: Aaaaaargh, still fighting with the kernel config/compile errors.
Wifi/BT framework issue.... RFKILL_STATE_UNBLOCKED etc. seems not to be implemented anymore...
letama said:
I made some progress there, I took LG P970 3D binaries with driver source code from their cm7 kernel (they also have a 2.6.35) and I was able to boot up to launcher. I had to fiddle a bit with audio runtime as phone audio won't work, but low level audio driver is working too. Next step is touchscreen... And probably doing a proper cm7 build, I'm running a frankenstein mix of cm7 for nook tablet
Click to expand...
Click to collapse
The SGX part is an open issue i guess, but there's some support form Ti as well. E.g.: https://gforge.ti.com/gf/project/openmax/frs/
Remember the Beagleboard-XM is very similar to what we got on our devices.
Also Zoom3 platform, so maybe their repository is a good starting point for these addon's as well.
In fact using the OMAP might be a benefit in general, because there are so many opensource projects covering this architecture
Happy hacking!
scholbert
Hi Scholbert,
scholbert said:
i guess fzelle is right.
AFAIK, the openaos developers concentrate on the Android part for gen8. As stated they still use 2.6.29 and this no problem so far.
But a kernel project might run in parallel.
Would be nice to get the new kernel working at least for A70 and A101.
Click to expand...
Click to collapse
Agreed! It would be nice if we could develop both A70 and A101 in parallel, sharing will speed things up.
scholbert said:
I started a build for A101 (...and still compiling), maybe we could share our .config file
Click to expand...
Click to collapse
I attached my current one, I added one config option that you don't have, CONFIG_MUSB_ERRATA_445, you can remove the line. I'm not sure I have the config right, but it boots and has quite a lot of stuff working. You need to re-add A10IT board though.
scholbert said:
The SGX part is an open issue i guess, but there's some support form Ti as well. E.g.: https://gforge.ti.com/gf/project/openmax/frs/
Click to expand...
Click to collapse
Well, for me it's no longer an issue, I think what I did is the best we can do until we can get a hand on Archos binaries for 3630. The issue is that you have to have proprietary binaries, they must match driver version, and the binaries I have from P920 works fine even though maybe not as recent as Archos ones. There is no open source implementation afaik. OpenMax is only for video codec, not 3D.
scholbert said:
Happy hacking!
Click to expand...
Click to collapse
Thanks, you too! You have a mission now! Let's get this kernel running on A101
Hi letama!
letama said:
Agreed! It would be nice if we could develop both A70 and A101 in parallel, sharing will speed things up.
Click to expand...
Click to collapse
To be honest i meant developing openaos and kernel in parallel. Who ever does it
Anyway, as i wrote it... i started to play around with the new kernel.
It's hard for me these days to find some time for hacking and i'm not a genius in modifying kernel drivers and stuff.
So in fact i don't know how far i will get things rollin'
letama said:
I attached my current one, I added one config option that you don't have, CONFIG_MUSB_ERRATA_445, you can remove the line. I'm not sure I have the config right, but it boots and has quite a lot of stuff working. You need to re-add A10IT board though.
Click to expand...
Click to collapse
Thanks a lot. I will compare your config with my setup.
Already found some missing parts in the board file...
letama said:
Well, for me it's no longer an issue, I think what I did is the best we can do until we can get a hand on Archos binaries for 3630. The issue is that you have to have proprietary binaries, they must match driver version, and the binaries I have from P920 works fine even though maybe not as recent as Archos ones. There is no open source implementation afaik. OpenMax is only for video codec, not 3D.
Click to expand...
Click to collapse
Ah i see, so i'll take a look at the binaries.
I guess you meant P970, as stated earlier.
letama said:
Thanks, you too! You have a mission now! Let's get this kernel running on A101
Click to expand...
Click to collapse
Haha, as stated above... nice mission anyway
BTW, did you see there are some nice projects at gitorious.
A 2.6.37 kernel port for A43 and A101 had also been started already.
I had a short look at some parts... don't know about the exact state of the code.
Let's stay in touch!
Best regards,
scholbert
I need a dev to help get monitor mode working on the Nexus 7
It has been done before on the SGS II which also uses the 4330.
I tried doing this myself, checking the install.sh and all that, but I came out with the error:
Code:
insmod: init_module 'dhd.ko' failed (Exec format error)
I was in superuser, files with correct permissions set, etc..
also to the devs: the iwconfig binary that they provide doesn't work, but the one I attached does.
please devs, this would be awsome
I don't have any experience developing but I can test what ever needs done to make this happen asap
Did you actually compile this dhd.ko or was it provided pre-built? If the latter, then you'll need to achieve the former using the correct architecture.
Sent from my Nexus 7 using Tapatalk 2
ok i installed sdk on ubuntu 12.04 i know kind of how to use adb. i can run scripts ie. config,make,makeinstall ect so can some one just tell me the cmds to recompile this dhd.ko module into our kernel so we can get this it would be abreakthrough in the nexus 7 community let alone the android community,especially if we got package injection working. please tell me how to do this.
First all, this thread is referencing an illegal activity, namely cracking password/wifi. XDA does not condone this (of course), but I will help you provided that this is used for educational purposes ONLY. Okay, my bad legal speech is over, let's get on with it.
Have you checked permissions on the module? It may be just as easy as switching permissions on it. If that doesn't fix it, try pulling it from another source, or as someone said, compile it for the architecture (arm).
You have the wrong kernel version, it doesn't match the running version.
You might be able to binary edit the value, but you might have the wrong platform.
compile it from sources.
The module needs to be compiled from the provided kernel. I'm guessing you're using CyanogenMod since that's what you linked. The website wiki dot cyanogenmod dot com slash wiki slash Building_Kernel_from_source covers this topic. (sorry links aren't allowed)
hanthesolo said:
this thread is referencing an illegal activity
Click to expand...
Click to collapse
While cracking someone's WEP without their permission may be illegal in certain locales - there is no reason to believe this is the situation for the OP. Wireless monitor is a legitimate means of enforcing wireless IDS/IDP and penetration testing.
Just something I had bookmarked.
http://bcmon.blogspot.com/
Edit: I just opened the OP link, same website I just put the main blog instead of the article.
iopuaauahi said:
The module needs to be compiled from the provided kernel. I'm guessing you're using CyanogenMod since that's what you linked. The website wiki dot cyanogenmod dot com slash wiki slash Building_Kernel_from_source covers this topic. (sorry links aren't allowed)
While cracking someone's WEP without their permission may be illegal in certain locales - there is no reason to believe this is the situation for the OP. Wireless monitor is a legitimate means of enforcing wireless IDS/IDP and penetration testing.
Click to expand...
Click to collapse
Good point, looking back on my post I really overreacted, sorry . WiFi monitoring on a mobile device, now that's something that would be a nice addition to any IT's toolbox!
hanthesolo said:
First all, this thread is referencing an illegal activity, namely cracking password/wifi. XDA does not condone this (of course), but I will help you provided that this is used for educational purposes ONLY. Okay, my bad legal speech is over, let's get on with it.
Click to expand...
Click to collapse
No-one here has said anything about any kind of illegal activity; wifi monitoring and packet injecting is used for white-hat pen testing or security auditing purposes only.
ok weve all been down the aircrack-ng ethical debate but it is a good tool for security purpose so lets avoid the endless discussion if its ileagal or legal, or moral, imoral and go with the facts IT IS A POWERFULL SECURITY TOOL THAT WOULD BE A MOST BENIFITUARY ASSET TO ANDROID DEVELOPEMENT AND SECURITY. that being said lets get this dhd.ko module compiled
does anyone no how to use the toolchain gcc to recompile the module for cm10 on the nexus? http://forum.xda-developers.com/showthread.php?t=1686310&page=1. could this be of use
I've not go through this thread yet but they said got it working for bcm4330 here: http://forum.xda-developers.com/showthread.php?t=1892535
Edit: silly me, of course you guys already knew that.
Sent from my LG-P970
yea
it does work for the bcm4330 chipset we have but the module has to be compiled and repacked into our kernel thats were im having trouble
man ive tried and tried to compile the module it just isnt working
has anyone got this working by any chance
Bump
Sent from my Nexus 7 using XDA Premium HD app
Another bump. Maybe someone will see this.
Sent from my Nexus 4 using xda app-developers app
Any changes with enabling monitor mode on N7?
After your hard work I send a little Donate (maybe 20€ ?)
Alright I've kinda picked this up as my own project but I need a little help. I'm successfully managed to compile dhd.ko against my running kernel (3.1.10-g22b4fcd-dirty), but I can not manage to load it. I get an exec format error, and dmesg reveals: "dhd: exports duplicate symbol bcmsdh_probe (owned by kernel)" which leads me to believe that I need to load a custom kernel, since the current driver is loaded and can not be unloaded. Actually lsmod produces no output...which initially lead me to believe that it was broken but now I wonder if all the modules aren't just loaded directly into the kernel (eliminating the need for .ko files). Can anyone confirm that any of this is on the right track? It would also be helpful if one could personally recommend a kernel compilation and packaging tutorial, I can find it on my own if need be.
BCM4330 Compile from Source
Trcx said:
I'm successfully managed to compile dhd.ko against my running kernel (3.1.10-g22b4fcd-dirty)...
Click to expand...
Click to collapse
What OS did you compile it on?
I'm receiving undefined variable warnings, a known issue ( code.google. com/p/bcmon/issues/detail?id=8), when I attempt to compile (make) in Xubuntu 12.10.
The variables appear to be defined in Kconfig, but alas I am a young fish at debugging compile errors.
The steps I've taken:
-Download source code
-Received invalid directory error -> Update Makefile to include the correct directory
-Receiving undefined variable warnings leading to later errors -> stuck understanding the relationship between Makefile and Kconfig