yashsingh1/xdaforums huggingface dataset:
[Miscellaneous Android Development] gmarkall:
I just looked at it with a hex editor and searched for strings that I knew were in each of the partitions. I've since had a look at a disassembly of u-boot.bin and found the function that sets up the partitions, so there's not too much point in carrying on doing this.

u-boot.bin is loaded at 0x80e8000. The function that sets up the partitions is at 0x80e91b98. I also found start_armboot() from lib_arm/board.c at 0x80e80e34, and main_loop() is at 0x80e82118.
[Miscellaneous Android Development] gmarkall:
I wrote a little tool to extract the partition table from u-boot.bin, and they are as follows:

Partition inand-mbr, Start 0, length 200, flags 0
Partition inand-raw-header, Start 20000, length 200, flags 0
Partition inand-xloader, Start 20200, length 1fe00, flags 0
Partition inand-env, Start 40000, length 40000, flags 0
Partition inand-uboot, Start 80000, length 180000, flags 0
Partition inand-kernel, Start 300000, length 800000, flags 0
Partition inand-id, Start b00000, length 100000, flags 0
Partition inand-recovery, Start c00000, length 800000, flags 0
Partition inand-logo, Start 1400000, length 400000, flags 0
Partition inand-ramdisk, Start 1800000, length 300000, flags 0
Partition inand-batteryid, Start 2dffe00, length 200, flags 0
Partition inand-version, Start 2e00000, length 200, flags 0
Partition inand-flags, Start 2e00200, length 200, flags 0

I missed a couple of them when just looking at a dump as they were full of junk or zeroes (inand-env, inand-id). It appears that u-boot.bin tries to load the environment from mmc, and will use a default environment if the CRC of the loaded environment is failing.

One current line of thinking is that I might write a u-boot environment to inand-env, in order to get it to provide a serial console over USB (I believe I read somewhere that that was an environment setting).
[Miscellaneous Android Development] gmarkall:
I had a little go with this as well - I think the x-loader might be causing the white screen issue. I've tried the following combinations on the SD card:

Compiled x-loader, compiled u-boot: white screen

Compiled x-loader, stock u-boot copied to SD card: white screen

Stock x-loader, compiled u-boot: flashes up lenovo on power up, then screen goes black after about 10 seconds, and it's difficult to turn it on or off for a while (not 100% sure about this result, it seems a little unexpected)

stock x-loader, stock u-boot: seems to boot up normally.
[Miscellaneous Android Development] gmarkall:
Just a quick update:

I located where u-boot.bin gets its bootcmd from, at 0x8e08217c:

LDR R0, =aBootCmd ; "bootcmd"
BL getenv

I tried patching over this so it loads ="fastboot" into R0 and NOP'd out the getenv. I hoped this would boot cause it to boot up in fastboot mode, as it should be the equivalent of providing the bootcmd fastboot. However, this didn't work - it booted from the SD card and just looped over with the "Lenovo" screen. As it's getting a bit late, I'll probably leave it until tomorrow to investigate why it went wrong.
[Miscellaneous Android Development] darxkies:
Really cool!

I will try to get an SD Card soon too.

Is it possible to elaborate a bit on the tools you used? I mean for example the disassembler.
[Miscellaneous Android Development] gmarkall:
I managed to patch u-boot in a much less complicated place and get it to drop into fastboot. I've just uploaded the modified u-boot.bin to the hosting page for this evening, as it's too late to look into what can be done with it.

It can be used by following the instructions that spiegeleixxl outlined for creating a bootable SD card. You must use the stock MLO from an OTA image, and save u-boot-fastboot.bin as u-boot.bin on the SD card. Once you boot up with it, it shows up as a USB device, 18d1:deed "Google Inc.".

Running fastboot commands may be dangerous - as fastboot doesn't seem to be available to end users, we don't really know whether it's been tested or can be expected to work.
[Miscellaneous Android Development] TDO:
Sounds interesting.

I will try it with a Nook Color boot sdcard and look what happens.

On the nook you must have 4 partitions. (I think boot, system, cache, data)

Here is a good resource for the OMAP platform: http://www.omappedia.org/wiki/Main_Page
[Miscellaneous Android Development] kryszan:
There's a video showing ClockworkMod Recovery for LePad A1 (which is IdeaPad's equivalent for chinese market, I think).

To prevent spam I can't post outside links (less than 10 posts) so if You want to check it out just look for Huongdan UpROM Root A1 minh65566 tinhte on YouTube :)
[Miscellaneous Android Development] xbdesign:
tools

please ignore this post... my mistake....
[Miscellaneous Android Development] gmarkall:
Apologies for this post, please ignore it.
[Miscellaneous Android Development] xbdesign:
So i made an update and i have ClockModRecovery working

But it want make a backup :-( and its not really installed but it just replace the original backup in memory with ClockMod one.

Right! Same here.

But log File (cache Filder) is very interesting...
[Miscellaneous Android Development] kryszan:
Now, could You test it somehow? For example by trying to backup and restore? I think our Lenovos will get some developing from now! :D
[Miscellaneous Android Development] xbdesign:
So it want make a backup.

So I am searching for a Reason in log Files.

If you would like i could send you a update.zip (Clockwork backup) so you can try it yourself.
[Miscellaneous Android Development] kryszan:
I will get my IP on Monday, so for a while I'm just researching. I don't have an opportunity to test it for myself.
[Miscellaneous Android Development] gmarkall:
Update: I got the CWM recovery that I built flashed onto the pad and booting up. Some testing will need to be done next. Screenshot:
[Miscellaneous Android Development] xbdesign:
Nice Job!

Did you Flash it with fastboot?

Does backup functionality works?
[Miscellaneous Android Development] gmarkall:
I didn't - I spent some time investigating using fastboot, but decided not to do it, for a couple of reasons:

1. Because I patched the u-boot to jump into do_fastboot from start_armboot at the location where it would normally jump into main_loop, I was a tiny bit concerned that there might be some setup that got missed out (although I don't have reason to believe I missed anything important, and the board_mmc_init function that sets up the partition table for fastboot runs first). I was probably just being paranoid.

2. I noticed that u-boot supports a fastboot upload command, that reads from a partition and sends it to the fastboot client over USB. I had thought that I could use this upload command to read the recovery partition, and if I got back the same data that I know is in the recovery partition, I would have thought that using fastboot flash would almost certainly flash the right data to the right location. However, in the u-boot that comes on the device, this upload functionality has been removed, so I couldn't use it :(

I've looked reasonably in-depth at the fastboot code and believe it should work for flashing. However, I'm keeping it as a backup or emergency option to try if something has gone wrong (e.g. bricked the pad), rather than taking the risk when I don't need to.

I used the fuse utility from the OTA, which I believe is also safer since it verifies the CRC of the image and checks that you're flashing the right type of image.

Not sure yet - just had a break from working on this, and I'll get back with an update in a while.
[Miscellaneous Android Development] xbdesign:
That’s god news you have. (Plan A and Plan B);)

I’m stuck with this Chinese Version that is killing standard Backup and starting CWM that does all but no backup. :mad:

I'm still afraid of flashing something..
[Miscellaneous Android Development] gmarkall:
I believe it's only running off the SD card. If you delete update.zip from the SD card then it shouldn't be there to kill the standard recovery.
[Miscellaneous Android Development] xbdesign:
Yes I noticed this before.

I meant that I'm Stuck because it does not work like it should :D
[Miscellaneous Android Development] gmarkall:
So it seems that backing up, erasing and restoring each of /system, /data and /cache is working. (I don't plan to support backup up the kernel, ramdisk or bootloader for now). Installing zip files from the SD card also seems to work (I tried it with the lepad_a1_rooter.zip that someone mentioned earlier).

Are there other features of clockworkmod recovery that people are interested in that I've not mentioned above? I'd like to make sure that things have had a bit more testing, and make sure I'm aware of the things that people are likely to use it for.
[Miscellaneous Android Development] xbdesign:
Well that’s just GREAT!

Congratulations.

I think it would be fine for the beginning.
[Miscellaneous Android Development] killerkom:
Nice job !!!!
[Miscellaneous Android Development] ppetermann:
Why leave the kernel out?
[Miscellaneous Android Development] xbdesign:
My Version ist backing up too..

Backing up CACHE, DATA and SYSTEM

Have just to test a little bit more.
[Miscellaneous Android Development] gmarkall:
There's only one kernel for both the recovery and the normal android system. Flashing a bad kernel could render the device unbootable.

It would be better if the device used a u-boot multi-image file for the recovery, and another one for the kernel and initrd for the normal system (similar in function to a normal android boot.img), then we could safely backup and restore this without worrying about hosing the kernel for the recovery. However, if this is possible, it would almost certainly require us to recompile u-boot, which we won't be able to do until Lenovo releases the sources for it - it is definitely a modified version of u-boot that is used.
[Miscellaneous Android Development] ppetermann:
We could ofcourse kindly ask lenovo, i mean in the end this adds value to the device
[Miscellaneous Android Development] imritechere:
Excellent work

Thanks for everyone's effort to make this happen! It seems to have been a long time comming and it's getting close.
[Miscellaneous Android Development] sinanju:
We have kindly asked Lenovo. The request is now in the hands of a Lenovo Customer Advocate.
[Miscellaneous Android Development] M1m3R:
i'm apparently bad at searching today...any chance you can point in the right direction of said .zip

EDIT: found it... http://xdaforums.com/showpost.php?p=18516133&postcount=15 ...have not yet tested the bits in LePad_A1_root.rar (googled since the droid-style download link is broken)
[Miscellaneous Android Development] gmarkall:
First release

I've just made available the first flashable update.zip of Clockworkmod v5.0.2.7 for the Ideapad A1 - see the (now edited) first post for details.

Please post your experiences with it in this thread - I look forward to your feedback!
[Miscellaneous Android Development] xbdesign:
I'm happy that you make it.

Do you flash it permanently or doing just Fake Flash?

I posted on German Forum v3.0.0.5 this morning and it seems to do the work.

Made several test myself. It is a Fake Flash.

Anyway you don’t have to put a update.zip in /sdcard you can also put it in /sdcard/removable_sdcard it works too.

Now cyanogenmod would be nice to port :)
[Miscellaneous Android Development] gmarkall:
This flashes over the recovery partition, replacing the stock recovery.

Yes - I'll be starting work on this in the next few days. First I want to focus on making sure the recovery is working well.
[Miscellaneous Android Development] imritechere:
Excellent work!

Downloaded the recovery update and I have to say it works very well/ ran a back up did a factory reset and restored the backup. Every thing seems perfect after restore. Did experience the reboot issue. I do have a question about the touch screen calibration not that it's needed now, but can it be made available?

Again excellent job !!!
[Miscellaneous Android Development] gmarkall:
Great! Many thanks for your feedback! :)

This is a good point - I think the original recovery launches a binary called mg_cal to calibrate the touchscreen. I'll look into this and see if I can add the touchscreen calibration to CWM over the next couple of days.

Thank you :)
[Miscellaneous Android Development] xbdesign:
I have translated a Installation part of your first Post and Link your Page in German A1 Forum.
[Miscellaneous Android Development] gmarkall:
Xbdesign,

Thanks! Do you have a link to the German forum?
[Miscellaneous Android Development] looxskywalker:
xbdesign,

verräts du mir/uns in welchem Forum du das ganze auf deutsch postest?

Ist das evtl. dieser Fred android-hilfe kann ich nicht ausschreiben punkt de/lenovo-ideapad-a1-forum/186901-anleitung-clockworkmod-recovery-rooten punkt html ??

Gruss pit
[Miscellaneous Android Development] otti17:
This is the link to the german forum and this to the thread with your cwm.
[Miscellaneous Android Development] henge.:
That would be this one:

www.android-hilfe.de/lenovo-ideapad-a1-forum/186901-anleitung-clockworkmod-recovery-rooten.html
[Miscellaneous Android Development] mirkophil:
good work :)

am going to order my A1 in next few days off Amazon UK (£170)

Is a bargain and spent about a week researching budget tablets and this one seems like its the way to go, even more so now its rooted :)

its now amazon uk's #1 seller in electronics i've noticed, so definately going to be alot of people after custom FW... if any developers want to take it up i'll more than happily donate...

keep up the excellent work, thanks
[Miscellaneous Android Development] xbdesign:
@otti17

@henge.

@looxskywalker

Klaro, wir kennen uns doch von Android-Hilfe.de nur da bin ich anddior

@gmarkall

It is the Link that Henge and otti17 posted.
[Miscellaneous Android Development] purloiner:
Fantastic news, received my pad from Amazon uk on Wednesday, rooted it already so now I'll have a crack at CWM, thanks for your work! :D
[Miscellaneous Android Development] otti17:
Damn..., how did u guess? ;) Huhu :)
[Miscellaneous Android Development] sinanju:
As the weekend closes in I wanted to update everyone and let you know that I have not yet heard back from the Lenovo Customer Advocate regarding my last email. It was both a ping and a request to add the u-boot source to the list of things they should be releasing.

I'll try reaching out again Monday... His email signature had a phone number, so perhaps a call is in order. Monday will mark four weeks since he first contacted me for details of what was being requested. I realize the holidays were in the middle of that but as an old boss used to ask: "If you can't give me a date, can you give me a date for when you'll be able to give me a date?"

If there's no progress, perhaps an email to the FSF? I'm loathe to distribute his contact info... it's not his fault Lenovo legal failed to recognize and prepare for the implications of distributing an Android device.
[Miscellaneous Android Development] gmarkall:
I've made a zip file that can be flashed from clockworkmod in order to get back to the stock recovery, for example if you need to use the touch calibration. It's hosted on the download page, as stock-a1-recovery.zip.

I'm still working on adding touch calibration to CWM 5.0.2.7 as well, but I'm just taking my time in making sure I'm really clear about how it works in the stock recovery before attempting to duplicate its functionality.

I have a fix for the reboot bug, but as it's a trivial problem, i'll build it into the next version that has the touch calibration, rather than wasting time building a version that reboots properly but doesn't have touch calibration.
[Miscellaneous Android Development] kryszan:
I've made a thread about your CWM port at polish Android biggest forum ;) You can read this there. I hope we can get some impriovement in your work (bugcatching etc.) :)
[Miscellaneous Android Development] gmarkall:
Update:

I've fixed the reboot issue and added touchscreen calibration. The updated version is on the hosting page and is called cwm-5.0.2.7-rev1-ideapad-a1.zip.

If you try it, please let me know how it works for you by replying to this thread - thanks in advance :)
[Miscellaneous Android Development] otti17:
workin fine

I've just tested the latest version and everything seems to work. I did a backup, restore, and the touchscreen calibration. The backup, which I used was created with the fake flash method and works fine.
[Miscellaneous Android Development] imritechere:
Nice job!

I flashed the latest and it works very nice!

Backup, Restore, Calibration, Reboot !

I originally renamed the the file and flashed as an update this seemed to wipe the recovery all I could get is the triangle and box. I put the 1st recovery in it flashed with the box recovery this installed the 1st version again. Redownloaded and flashed with CWM -install zip- no more issues.

Nice job Gmarkall you are an inspiration to us all!
[Miscellaneous Android Development] gmarkall:
otti17 and imritechere,

Thanks for testing the recovery!

Do you have the 2GB or 16GB version of the Ideapad?

Many thanks!
[Miscellaneous Android Development] otti17:
The 16Gb ideapad.

Gesendet von meinem A1_07 mit Tapatalk
[Miscellaneous Android Development] imritechere:
CWM

I've got the 16 GB as well
[Miscellaneous Android Development] mikerizzo97:
Installed recovery

Just wanted to let you know I installed the file and so far it works great. I've had my A1 since early November and have been waiting for upgrades.

I'd love to be able to do something with the removable SD card too, other than storing my backup there.

Mike
[Miscellaneous Android Development] mikecn:
I am waiting, too.

I hope I can use CM7 on my A1

---------- Post added at 04:10 AM ---------- Previous post was at 04:02 AM ----------

Many thanks for your working!

Still I can a new hand, I wander how I can do for android development.
[Miscellaneous Android Development] otti17:
Feedback

In the german forum there are other ppl, who reported that your cwm rev1 is working very well. As far as i know, they all have a 16Gb device.
[Miscellaneous Android Development] sinanju:
I just left a voicemail for the Lenovo guy. He's in my timezone -- I'm in New England and he's in North Carolina -- so there should be no time-related issues to getting a response. I was polite, but did mention that at some point, if Lenovo failed to comply with it's license, the developer community would reach out to the FSF -- whatever that's worth.
[Miscellaneous Android Development] imritechere:
Re: Lenovo Open Source

Lots of calls for Lenovo to release the source on their Forum. The more the better...
[Miscellaneous Android Development] imritechere:
RE: Clockwork Mod

How to Install Latest Clock Work Mod Recovery 5.0.2.7 in Dell Streak 7

Found this on android advices // the download link doesn't seem to work
[Miscellaneous Android Development] sinanju:
Got a call back this evening. They claim to still be working on it. He's going to buttonhole the program manager tomorrow for an update. We should get news soon.
[Miscellaneous Android Development] imritechere:
Thanks for your work on this // I'd be happy to to reach out to the guy as well if you think it might help!
[Miscellaneous Android Development] cheny95:
Please Look Me！

楼主，其实我看不懂你在写的什么，我也懒的去找翻译器了，不过我知道你发表的这个是和CMW有关，我希望你们这些国外高手尽快搞定，我好用上带CM的Lepad~

CM很强大的，你懂的。

心有神马，不为浮云！

Your Chinaese friend,

Cheny
[Miscellaneous Android Development] spiegeleixxl:
Sorry I was off for such a long time.

Also got the german 16G verison.

@gmarkall: it's "SpiegelEiXXL", not SpeigelEi :p

What version of u-boot did you try to compile? The latest?

Did you try checking out the version they had used in the stock A1?

Will try to flash the clockworkrecovery of yours soon and try to get rolling on porting CM7 or ICS onto it, as soon as I get some kind of way to go back recovering stuff :)
[Miscellaneous Android Development] imritechere:
Re: Unofficial Clockworkmod recovery

Gmarkall, Sorry to hear about the issues with u boot compilation. I'm not scared to test anything, but test is about all I can do.

Thanks for your efforts
[Miscellaneous Android Development] gmarkall:
Argh, sorry about that! I believe I've corrected it now - if you see it mis-spelled again, please shout at me :)

I just checkout out from the u-boot git repository. The Stock A1 version is 1.1.4, and the version I built calls itself "1.1.4-gdc6f9add-dirty". I think the Stock A1 version has the partitions and environment string hardcoded, so the version that I compiled doesn't know where to look. I thought about playing with this more, but I concluded that it's best to spend time on other things since Lenovo ought to be releasing their U-Boot source anyway.

Sounds great! I made a start on porting CM7 yesterday, so I'll push what I've done up to Github in a few minutes.
[Miscellaneous Android Development] gmarkall:
No worries - I think I'll look at this again when Lenovo releases their u-boot source.

Sorry, I don't quite understand ... ?
[Miscellaneous Android Development] gmarkall:
As promised I've pushed what I got done so far on porting CM7 onto github (which is not very far yet). I also started a thread for discussion of CM7 porting: CM7 dev thread is here.
[Miscellaneous Android Development] rkaede:
wow this is fast. kudos to you.

hope the build will be smoothh:d
[Miscellaneous Android Development] twinpapa:
Thank you very much for your efforts. I am using a 16GB A1-07, german version. CWM is working fine. Hope you will succeed in porting CM7.

Best regards,

twinpapa
[Miscellaneous Android Development] BuzzyB:
I just instelled CWM on my german ideapad A1 an everything seems to work great! Good Job!

It would be great to get ICS working.
[Miscellaneous Android Development] piccobit:
BTW, is the 'fix permissions' option working?

Got some strange problems with, maybe, wrong permissions for the Wifi configuration file.
[Miscellaneous Android Development] gmarkall:
I believe it should be. I have tried running it on my Ideapad to test it, and I didn't spot anything abnormal in fix_permissions.log.

If you run fix permissions and it doesn't fix your problem, you might want to do a backup then run "wipe data/factory reset" to see if the problem still exists after a factory reset. You could then restore your backup after testing it.

If you try it, please let me know how you get on!
[Miscellaneous Android Development] spiegeleixxl:
Installing CWM worked fine here too on my A1 16G! Just quick question, can you put the instructions how to navigate in the first post? I know vol up/down for up-down, but i dont know how to "press" a option, I'll look it up in the source but it may be a good idea to post it on the first post.

EDIT: nvm, power button now works, seems like i happened to meet some weird bug, the bottom kept saying "back-button disabled" or something. Now it works fine.

EDIT2: don't worry, it's when you press both vol up/down buttons, then it goes "Back menu button disabled" or "enabled", when pressed again. The buttons react weird while disabling the back menu button.

EDIT3: During "- advanced"->"Key Test" pressing the "Back" button leads to weird reactions on the menu part and seems to cancel the key test and keeps it running in the background...
[Miscellaneous Android Development] piccobit:
Thanks for the hint, I'll try that and let you know ...
[Miscellaneous Android Development] piccobit:
My WiFi problem is a hardware problem!

The A1 reboots even after the factory reset if I enable WiFi! :mad:

BTW, 'fix permissions' seems to work like expected. :thumbup:
[Miscellaneous Android Development] gmarkall:
Could you send me the contents of /proc/last_kmsg after one of these reboots please? I've been trying to understand random restarts from other people, and I'm curious to see if your /proc/last_kmsg contains similar things.

Great! Thanks for letting me know!
[Miscellaneous Android Development] tinybeetle:
Were you plugged into the charger when it did the reboot?

That seems to be the only consistent factor in my "random" reboots. They almost never happen when the charging cable is not plugged in. When I charge at night I turn WiFi off and the reboots don't happen. If I leave WiFi on, the reboots do happen, often locking the A1 completely.