From: Bernard L. <le...@bo...> - 2003-11-11 21:03:54
|
Hi Dani, On Tue, 2003-11-11 at 18:59, PALFFY Daniel wrote: > > > I think you can just re-write the boot table completely though (e.g without > > caring for the flashupd image). If you want to update the flash then dd in > > the original and run the updater.exe... Assuming people screw up and don't > > save a backup I think the updater.exe does the equivalent of a dd anyhow. > > Ok, I'm doing this. However the first 512 bytes still have to be copied in > from an original firmware. Do you know the meaning of those few bytes at > 0x100? The text before doesn't seem to be important, but the first dword > seems to be some magic number (it's included as a literal in the loader > right after 0x55aa - the PC boot sector magic. I haven't disassembled it > further yet). The other values seem to be required, too. That reference in the bootloader is for the pdisk command which I would assume to be a command to partition the disk. Its not called by the startup. I can't see any other references to it in the bootloader... > > Anyhow I'll take a look see in a few hours and see about giving it a whirl. > > Try this instead! > > Oh, I've nearly forgotten: This version can load up to 5 images, any of > which can be the default, the others are load for the four keys on the top > (or around the wheel). > > PS: I should really read ARM documentation before writing a boot loader... > It's really funny to find out the hard way that the address of the > current instruction is (pc & ~3) - 8 :) <http://www.arm.com/techdocs.nsf/html/ARM7Docs> The one called ARM7TDM_Rev4.pdf covers pretty much everything you need to know. cheers, bern. |