Other Parts Discussed in Thread: UNIFLASH
I was thinking of doing the following to store a constant into OTP. I was wondering when the value gets written. Is during writing to the flash or loading of the program? If the location is already written, and if I have another program that tries to write a different value, will the write fail gracefully. i.e. in the debugger, I get load fail.
In linker file:
DDCID : > OTP, PAGE = 0
In code:
#pragma DATA_SECTION(DDCID, "DDCID")
const Uint16 DDCID = 0x4DDC;
We are developing a feature where we have 2 cards on a CAN bus, and we want to write into OTP something different for each card so that the operator can't inadvertently load the wrong program into the card.