Hi Alice
My work is to manufacture a programmer which can flashing the file to the mcu's flash. I am not using any IDE, the debugger is what i am working for. It uses swd interface to communicate with the mcu. Don't worry about my program function and read function of my programmer. I test for them with JTAG and his program software(J-Flash), it was work.
I just use a blank chip, I read the flash by swd interface. But the address between 0x0000 to 0x01FF of the data is still wrong data. Except for the address 0x0000-0x01FF, other data what i read back is correct.
Only in this situation what i write the correct check-sum of vector table entries 0 through 6 which locate in 0x0000001c by the IAP command, I can read back all correct data by swd interface. So the checksum is correct or not will affect to what i read back from the flash by swd interface. If the checksum is correct, all the data what i read back from the flash is correct. If the checksum is wrong, the top of 512 bytes(the address: 0x0000-0x01FF) data is wrong, other data (the address: 0x0200-0x7FFFF) is correct.
But the blank chip's value must be 0xFF in all flash memory, even in this address 0x001C -0x001F area(the area to store checksum), so I think it must be having some ways to disable this checksum function, if not, when the chip is blank, I can't read the all correct data forever. So how can i read all correct data in this situation?
About your suggest to flash a file whick is not whole 0xFF, the situation is the same as what I said above.
Thanks in adavance,
Jerry