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.

MSP430F5529 Flash Write in Address 0x000241f0

Other Parts Discussed in Thread: MSP430F5529

Hi,

    i want write  the some Value in the Flash Address range  0x000241f0

but the Value Not Write. is it Possible to write this Location?. Previously in 2X Series i am using Internal Flash to write Values.

my code as follows

char *Flash_ptr = (char *)0x000241f0; // Initialize Flash pointer

FCTL3 = FWKEY; // Clear Lock bit
FCTL1 = FWKEY+WRT; // Set WRT bit for write operation
for(i = 0; i < 256; i++)
{
*Flash_ptr++ = value++; // Write a word to flash
}
FCTL1 = FWKEY; // Clear WRT bit
FCTL3 = FWKEY+LOCK; // Set LOCK bit

  • Hi,

    there are two things which I can think of:

    - first: have you erased the memory erase before writing? Flash memory needs to be erased first before written. Please notice that erasing can be done only per segment (512 bytes in MSP430F5xx devices)

    - second: since you are targeting a 20 bit address, have you tried to activate the large data model? For example in CCS, you need to do the following setting:

  • If I understand correctly, you want to write some value to the Flash memory of MSP430F5529 at address 0x000241F0. But was unable to do so.

    Why do you want to write to this particular address 0x000241F0? Does MSP430F5529 have Flash memory at 0x000241F0? Have you tried to write to some other addresses?

  • if you dont know just keep quit. dont waste others time and Forum Messages. Here lot of people is there to solve the Problem.

  • These were valid question to pin down the problem. However, your answer wasn’t valid by any means.

    Here are many people who want to help you to solve your problem, but most won’t "do your job for you".
    OCY does it his way by asking questions that might shed some light onto the problem. Especially if the information you provided isn’t enough for pinning down the problem.

     OCY: yes, the MSP has that much. It goes up to 0x243FF. However, the code might write to 0x041f0 instead, which is at top of ram and probably in the stack area. Or at least volatile.

**Attention** This is a public forum