Originally posted by Jeff Lopez
I think this will mostly happen..if the K01 and the K50 share the same PRIME processor, then I dont see any problem, the would have the same registers. a mirror is not related to the exposure commands, like a shutter and aperture does. Probably it will hang if you select Bulb or mirror up for cleaning and I really doubt it, it most probably will return an Error as there is no way to provide feedback to the Prime..
Abel, could you provide a K30 firmware to mod a K01? it has less functions and probably will fit to the K01 DRAM
I surely can make that firmware.
The problem is K-01 firmware is 0x40000 bytes less than for K-30. And existing K-01 cameras simply don't know and don't expect there's something more to flash into their memory. Which means the K-30/50 firmware will most likely be installed incompletely.
If this additional block doesn't contain any logic necessary for routine camera functioning, the camera would work (most of the time).
And we can possibly install the whole K-30/50 firmware by firstly installing, say, version 1.05, and then the latest one - in this case 1.05 from K-30 will already know about full size of its update, and will install the next version completely. But it would be hardly possible to revert the camera to the original firmware.
And in case the additional block contains some initialization code, or some functions used during normal camera operation, that K-01 will simply hang right after starting.
To summarize:
It can be possible to install K-30/50 into K-01, but already broken camera should be necessarily be used for the experiments.
If someone has such camera, or can obtain one for a bargain price, I can provide the necessary firmware(s) for the testing.
---------- Post added 04-10-17 at 10:04 AM ----------
Originally posted by tr13
One strange thing I see is 12MB xor decryption key.
Yes. Bearing in mind the decryption algorithm is rather simple, and even the XOR-key "seeds" are stored in the firmware file itself.
Originally posted by tr13
As I understand it is obtained by xoring dumped firmware with encrypted one.
It was obtained by decompiling the decryption routine with Hex-Rays decompiler, then compiled and run.
Originally posted by tr13
As far as I remember Pentax did not change algorithm for ages. So it can be good idea to add K30/K50 to my tool (as K-01 is present)
You are partially correct, the algorithm itself hasn't changed.
But there are two radical differences:
1. In older models the firmware file started with a non-encrypted header. And decryption started from the offset 0x100.
But in K-01/30/50/500, there's also a first block 0x000-0xF00, which should be decrypted using the same algorithm, then comes the same 0x100-bytes of plain header, which is started with the same XOR "seed" (HOKKTKIYHTNTMU) as in previous models.
2. In K-30/50/500, there is also a second block, with its own XOR key. The block starts at 0xC00000, and its header (well, it should be called a trailer) resides at 0xC3FF80 - it also starts with key "seed" (different one - SWaaTKouHI).
frmcrypt.exe version 3.00 you've posted on P-V.com correctly processes the main part of the K-01/30/50/500 firmwares, but leaves the starting portion intact, and it also incorrectly decrypts the second block of K-30/50/500 firmwares.
As far as I understand, it's a matter of slight changes to make your tool compatible with these firmwares.
And it would be just great if you can modify it and release an updated version, because all the community has right now is a firmware decoder/encoder which requires .Net 4.0+ for running, whereas your tool is made in Delphi(?) and runs even on my ancient Win XP