Latest product reviews
ARCHOS 50 Diamond
ARCHOS GamePad2
ARCHOS
Smartphones
ARCHOS
TV Connect
ARCHOS 101 XS

A A A
Avatar

Please consider registering
Guest

Search

— Forum Scope —






— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

Register Lost password?

ClockworkMod (CWM) Recovery easy install for RK3066 and RK3188 -- TWRP/CWM Flash-Tool and root for RK3288

 Please donate to support OMA and CrewRKTablets firmware work, thank you !

sp_Feed sp_TopicIcon
A little linux help please (file patching tool needed)
Avatar
finless
Stanton, Ca

Contributor
Forum Posts: 604
Member Since:
2011/12/10
sp_UserOfflineSmall Offline

Thanks Received: 2
1
2012/01/11 - 20:55
sp_Permalink sp_Print sp_EditHistory

OK so I am still a linux n00b here.  I am scripting how to pack and unpack boot.img so people can do their own boot screens or edit things as they see fit.

So here is what I am asking.  Once I gzip up boot.img and add the md5crc with rkcrc, the file has to be editing in a hex editor to change the first 4 bytes from PARM to KRNL or the Arnova will not boot.

 

Can someone give me the linux shell command to write the first for bytes of boot.img with KRNL overwriting the PARM?

 

Thanks,

Bob

Avatar
josbos

Contributor
Forum Posts: 57
Member Since:
2011/12/19
sp_UserOfflineSmall Offline

Thanks Received: 2
Avatar
finless
Stanton, Ca

Contributor
Forum Posts: 604
Member Since:
2011/12/10
sp_UserOfflineSmall Offline

Thanks Received: 2
3
2012/01/11 - 22:44
sp_Permalink sp_Print

What you going to make me work to learn to do it?  😉

 

I read it but not making much sense... What ia AIX?

 

Bob

Avatar
josbos

Contributor
Forum Posts: 57
Member Since:
2011/12/19
sp_UserOfflineSmall Offline

Thanks Received: 2
4
2012/01/11 - 23:05
sp_Permalink sp_Print sp_EditHistory

AIX is an IBM linux flavor (it has no graphical interface, everything is command based), I have some customers who run it, they like it, I'm not.

But the shell commands used in the post does work on all linux distro's, also on Ubuntu.

Sorry that I can't give you a working solution, I'm no linux expert either, but the most fun part in "hacking" is learning by trial and error. Unfortunately I'm back at work, so I don't have the time anymore.

What you can try doing in meantime is run the following command in shell:

man od

This will provide you an explanation of the most important command.

If you can wait a few days, I can write you a c program, over the weekend, to make the adjustment.

I also made a custom version of the rkflashtool to strip a dump if it contains trailing blanks at the end to the correct filesize.


Avatar
finless
Stanton, Ca

Contributor
Forum Posts: 604
Member Since:
2011/12/10
sp_UserOfflineSmall Offline

Thanks Received: 2
5
2012/01/11 - 23:13
sp_Permalink sp_Print

I am working on a package with scripts to help new guys mod the boot.img.  While a C program is fine I was hoping to update rkcrc.c to make the changes to the file and change PARM rto KRNL.  I am sure it is a simple write command but I do not know how to do it at this time.

Can you possibly download rkcrc.c and make the edits for me to test?

You can download the RK tools from here and edit the rkcrc.c to do it?

https://github.com/naobsd/rkutils

 

Bob

Avatar
josbos

Contributor
Forum Posts: 57
Member Since:
2011/12/19
sp_UserOfflineSmall Offline

Thanks Received: 2
6
2012/01/11 - 23:14
sp_Permalink sp_Print

I have the code already compiled on my ubuntu and will modify it.

Do I add an argument for it? Or do I check on the filename, if it's boot.img always change the param?

Avatar
simondo

Contributor
Forum Posts: 78
Member Since:
2012/01/04
sp_UserOfflineSmall Offline
Avatar
finless
Stanton, Ca

Contributor
Forum Posts: 604
Member Since:
2011/12/10
sp_UserOfflineSmall Offline

Thanks Received: 2
8
2012/01/12 - 00:44
sp_Permalink sp_Print

josbos said

I have the code already compiled on my ubuntu and will modify it.

Do I add an argument for it? Or do I check on the filename, if it's boot.img always change the param?

 

Yes please.....  If you want to add a switch like -rk or something to do the PARM to KRNL that would be GREAT!

Thanks!

Bob

Avatar
finless
Stanton, Ca

Contributor
Forum Posts: 604
Member Since:
2011/12/10
sp_UserOfflineSmall Offline

Thanks Received: 2
9
2012/01/12 - 16:23
sp_Permalink sp_Print

simondo said

http://manpages.ubuntu.com/manpages/natty/man1/hexcurse.1.html

This might help

 

Doesnt help.  It says at the bottom:

TODO When we get the time, we would like to implement the ability to insert
and delete data from the file. Please e-mail us with any additional
suggestions.
 Bob

Avatar
admin

admin
Forum Posts: 5872
Member Since:
2010/09/11
sp_UserOfflineSmall Offline

Thanks Received: 3163
10
2012/01/12 - 16:31
sp_Permalink sp_Print

finless said

OK so I am still a linux n00b here.  I am scripting how to pack and unpack boot.img so people can do their own boot screens or edit things as they see fit.

So here is what I am asking.  Once I gzip up boot.img and add the md5crc with rkcrc, the file has to be editing in a hex editor to change the first 4 bytes from PARM to KRNL or the Arnova will not boot.

 

Can someone give me the linux shell command to write the first for bytes of boot.img with KRNL overwriting the PARM?

 

Thanks,

Bob

I'll let you know if I find something. In the worse case, it will be a matter of just a few lines of C code.

If you like our web site, applications and firmwares, feel free to support our site. Donations are used to pay the bills for our server hosting costs, development tools and purchase new tablets to support.

Avatar
ttz642t

Firmware Guru
Forum Posts: 53
Member Since:
2011/11/19
sp_UserOfflineSmall Offline
11
2012/01/12 - 17:46
sp_Permalink sp_Print

admin said

I'll let you know if I find something. In the worse case, it will be a matter of just a few lines of C code.

See my posts in:

 

http://www.arctablet.com/blog/forum/arnova-10-g2-development-forum/arnova-10-g2-custom-rom-development-with-linux/#p2808

 

The rkcrc command can recreate the boot.img perfectly, no C to do.

 

I started the thread to hopefully get various toos contributed for development on Linux, but Ive had little time.

 

Your rom has been a good one to start work on.

 

I've started a wiki, I hate forums, thousands of posting to collect all needed info.

Forum Timezone: Europe/Paris

Most Users Ever Online: 749

Currently Online: buzzly, agimsopa, davelou
185 Guest(s)

Currently Browsing this Page:
1 Guest(s)


Devices in use: Desktop (156), Phone (29), Tablet (3)

Top Posters:

Oma7144: 5789

globula_neagra: 2424

finless: 604

DarthJabba: 551

exelletor: 450

JochenKauz: 450

cracktech: 432

maikal: 394

Newest Members:

davelou

Ashanak

NoonKnight

alex_25_39

astafyan

xdwolverine

Forum Stats:

Groups: 10

Forums: 185

Topics: 5916

Posts: 58872

 

Member Stats:

Guest Posters: 43

Members: 256564

Moderators: 5

Admins: 1

Administrators: admin

Moderators: globula_neagra, exelletor, JochenKauz, Oma7144, cracktech


CrewRKTablets moderators: JochenKauz and Astralix