I am using a K70FN1M0VMJ12 Tower Module. When I try to program flash, I get an error about writing to the security area. It appears that offsetting by 0x500 fixes this issue. Unfortunately, from some simple test code, I found that I must be running the debugger in order for my code to run successfully (programming using the flash programmer then hitting reset doesn't work?). When I run the debugger, I get a similar error referring to the secure memory area. To resolve this, I created a custom RunAndDebug task that will erase the device, run a blank check on all sectors, program flash, and verify the write. I set my debug configuration to run this custom task instead of the standard one. I am getting a "Error downloading program". Below are the settings I used for the custom task:
Device: FTFE_PFlash1M0 (128Kx64x1)
Erase: Base Addr = 0x0
Blank Check: Base Addr = 0x0
Program and Verify: File Type = Auto; Addr Offset = 0x500
Any help on anything I mentioned is much appreciated!