ds30 Loader free edition forums

Full Version: Program Checksum issue [solved]
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have used the bootloader on PIC24FJ without problem. Think the GUI is version 1.4.6. and bootloader 1.04? Probably superseded now, but, if it isn't broken don't fix it.

I have a requirement for runtime program checksum verification.

Cutting a long story short programming the device with the same hex file by importing to MPLAB and bootloading produces different results. The bootloader appears to fill gaps in the hex file with zeros and MPLAB with FFs.

Is this expected behaviour? is it adjustable or changed in later versions?
That is not expected behavior. It is supposed to fill with 0xff. Can you send me the the two hex files.
The checksum won't match anyway because the goto at 0x00 is moved to just before the boot loader and in it's a goto to the boot loader is placed.
(2012-03-18, 16:00:46)Mikael Gustafsson Wrote: [ -> ]That is not expected behavior. It is supposed to fill with 0xff. Can you send me the the two hex files.
The checksum won't match anyway because the goto at 0x00 is moved to just before the boot loader and in it's a goto to the boot loader is placed.

My checksum generation and checking skips the reset GOTO at 0. The difference between MPLAB and bootloader programming is two words at 0x100 (the start of the aivt which is a gap in the hex file) and a block after the last address (excepting the config words) in the hex file. These are FFs with MPLAB and 00s with the bootloader.

I have worked around the problem by filling in the gap with this
Code:
int hexpad[2] __attribute__ ((space(prog), address(0x100)));
in the program.
Thanks, this is fixed in the version that will be released soon.
(2012-03-18, 21:11:17)Mikael Gustafsson Wrote: [ -> ]Thanks, this is fixed in the version that will be released soon.

Ok, my workaround seems to be good. I assume the fix is in the GUI and I posted this in the right forum? Smile
You are absolutely correct and the new version is finally released now Smile
http://mrmackey.no-ip.org/elektronik/ds3...120318.php