Rockbox Technical Forums

Rockbox General => Rockbox General Discussion => Topic started by: almog1006 on October 01, 2017, 05:03:35 PM

Title: How can I open a file with FW extension for translating it
Post by: almog1006 on October 01, 2017, 05:03:35 PM
I bought a Ruizu / AGPTEK player that has many languages
But the language I need is not properly translated and the player has menus that are not translated at all to the language I need and they are written in another language
Can someone help me open the file? I've translated the menus, only I do not know how to edit the firmware (fw ext.)

Thank you!
Title: Re: How can I open a file with FW extension for translating it
Post by: pamaury on October 07, 2017, 05:52:10 AM
Hi,
the extension by itself is meaningless, it may use any number of formats, including proprietary ones.
If you want some help I suggest you at least point to the said firmware and provide for example the hexadecimal dump of the beginning of the file so that people can tell you if it's a known format.
Title: Re: How can I open a file with FW extension for translating it
Post by: almog1006 on October 07, 2017, 11:56:33 AM
At The beginning of the file is written "3DUfw"

LINK FOR DOWNLOADING THE FILE:
https://pan.baidu.com/s/1o89NZQU
Title: Re: How can I open a file with FW extension for translating it
Post by: pamaury on October 07, 2017, 12:16:09 PM
I had a look at the file and it's partly supported our tools. You need to download at least this directory:
https://git.rockbox.org/?p=rockbox.git;a=tree;f=utils/atj2137/atjboottool;h=1ff5b11fb4e2b240bcd81552673b96dbe5b38750;hb=HEAD (https://git.rockbox.org/?p=rockbox.git;a=tree;f=utils/atj2137/atjboottool;h=1ff5b11fb4e2b240bcd81552673b96dbe5b38750;hb=HEAD)
then compile the tool with make, most probably you need a linux environment (run it in a virtual machine for example). Then run:
Quote
./atjboottool -o X26.sql X26.fw
The obtained file X26.sql is an sqllite database. It's a somewhat weird way of storing file I admit but it's quite common for ATJ based firmware.
I have some code to prints some information about there:
https://github.com/pamaury/pa-tools/tree/master/qsql (https://github.com/pamaury/pa-tools/tree/master/qsql)
(it requires Qt and SQLLite library). It does not implement firmware extraction but just prints the list of files. It should fairly easy to add support for unpacking.  Then you can run:
Quote
./qsql X26.sql
For information I attach the list of files listed by my tool. I guess some file in there contains the translation but I don't know which one and which format it uses.
Note that none of the tools about allows to repack the firmware at the moment, that would need to be added (I will actually implement it for atjboottool because we need it for Rockbox).
Title: Re: How can I open a file with FW extension for translating it
Post by: almog1006 on October 08, 2017, 07:46:25 AM
Thanks! finally found the type of this file!
When can you add an option to repack the SQL file back to FW? ?

And also when can you add to your tool unpack/repack (the sql files) option