It is now possible to read from a motomagx phone using linux
Jonathan Wilson
jfwfreo at tpgi.com.au
Thu Mar 20 12:23:16 CET 2008
I have posted some code http://users.tpg.com.au/jfwfreo/flash-tools.tar.gz
This code is a functional flash-read program for z6 (at least) on linux.
This code should run on any system that the original flash-tools code runs
on and requires libusb to work.
Code is based on http://flash-tools.jerryweb.org/ and is licensed under the
GPLv2 as per flash-tools license. (I haven't updated the documentation in
the .tar.gz file yet so this is the only documentation available right now)
The following changes have been made:
1.New -m option. Pass this to make it look for motomagx USB device instead
of p2k usb device
2.New -r option. Pass -r z6 to read from the z6.prof file and read the
requested contents from the phone
3.-s now reads .sbf files and will split them up into a catalog. (at least
it works for all the sbf files I have handy)
Everything else continues to work as per the flash-tools documentation (-f
works for z6, I tested it myself)
the new -r option will read from a passed in profile and output a catalog
(same as what -f accepts) named after the profile. So -r z6 reads from the
z6.prof file and outputs to z6_catalog.
The first line of the profile file contains the name of the ramdownloader
file followed by the address it is to be loaded at. Then comes a line cg n
where n is the number of codegroups to be read. Next comes one line per
codegroup starting with the codegroup number then the start address and end
address of the codegroup. Look in the z6.prof file for an example. (z6.prof
is currently geared to read only CG43 and CG52 which are the 2 codegroups
you can actually edit).
For reference, the codegroups on the z6 are
CG31=C0024000-C0043FFF
CG34=C0030000-C004FFFF
CG35=C0110000-C028FFFF
CG36=C0670000-C236BFFF
CG37=D2C43600-D337B5FF
CG41=C0034000-C0053FFF
CG42=C0090000-C00CFFFF
CG43=C0070000-C008FFFF
CG44=C00D0000-C00EFFFF
CG45=C0290000-C066FFFF
CG46=C236C000-C2AEBFFF
CG49=C002C000-C004BFFF
CG52=C31EC000-C406BFFF
Once you have read the CG43 and CG52 off the phone, you can then follow
these instructions
http://www.rasputin007.co.uk/storage/webpages/v8_cg/
to unpack the squashfs compressed filesystems, edit the files and pack them
back into new squashfs filesystems that can replace the files read from
your phone. I advise backing up all files read from your phone so you can
go back to 100% stock firmware if you want/need to.
Note that I have only tested this on z6 with bootloader A3.C4 (included
ramdownloader is for A3.C4). It may or may not work on other phones (i.e.
z6 with different bootloader, v8, u9). You may need a different
ramdownloader for different z6 bootloaders.
Feedback, patches, updates, bug reports, info on which phones it works
on/doesn't work on etc will be appreciated.
More information about the openezx-devel
mailing list