This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSP430F6736: About Flash overwriting

Part Number: MSP430F6736


Hi experts,

Please let me confirm the Flash Memory Controller of MSP430F6xxx.

If I execute Byte Access Write without Erase for the Flash memory area (0x21200 to 0x2127F), will the write process be executed? Or, will the write access itself not be executed?

For example, Write 0x01 without Erase to the location where 0x55 is stored. It will go from 0x55 to 0x56.

In 7.3.1 Erasing Flash Memory in the User's Guide(SLAU208Q), it looks like there is a possibility of data rewriting in bit units. I know that Erase should always be performed when writing a new value, but if there are any differences in the way it is handled depending on the segment, etc., I would appreciate it if you could let me know.

7.3.1 Erasing Flash Memory
The logical value of an erased flash memory bit is 1. Each bit can be programmed from 1 to 0 individually, but to reprogram from 0 to 1 requires an erase cycle. The smallest amount of flash that can be erased is one segment. Table 7-2 lists the three erase modes selected by the ERASE and MERAS bits.

Best regards,
O.H

  • Hello OH,

    So, you can write a byte of Flash without erasing, but there is a problem.  The Logical Value of erased flash memory bit = 1.  Then each bit can be programmed from a '1' to '0', but to reprogram a bit from a '0' to a '1', you have to erase it.   This is explained in Section 7.3.1.  

    So, if you have a byte that is 0x55 = 0101 0101b  and write a 0x01, Only the Zero's can be written.  It basically will AND the two bytes together.  0x55 & 0x01 = 0x01.  It won't preserve the other non-zero bits and it definitely will not add them together to make 0x56.  

    Hope this helps.  

    Thanks,

    JD

  • Besides that fact that writing can only turn a '1' into a '0', you have a timing problem. There is a strict limit on the amount of time that the programming voltage can be applied to a particular block of memory. (see data sheet)  The limit is far too tight to allow for significant bit twiddling of this type.

  • hello,

    I was able to confirm the above behavior as the actual operation.

    I appreciate the support from both of you.

    Best regards,
    O.H

**Attention** This is a public forum