erase and write internal flash
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2024-04-24 12:27 AM - edited 2024-04-25 1:23 AM
Do I need to disable global interrupts for internal flash erase and write operations?
__disable_irq();
erase();
__enable_irq();
__disable_irq();
write();
__enable_irq();
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2024-05-22 4:38 AM
Hello @xiewenliang,
Could you specify the product or serie are you looking to reprogram the internal flash memory on? Additionally, could you share the intended purpose and any other relevant information that might aid in offering you the best support.
Thanks and Best Regards,
Dorsaf
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2024-05-22 6:20 AM
Generally NO, but you don't want to erase active code or the vector table.
If you read data/code from the same bank whilst the write/erase is occuring, it will STALL the MCU, basically stuff wait-states. As this can take a lot of time it can block read-time operation, like servicing a UART properly, or USB repressiveness, etc.
Up vote any posts that you find helpful, it shows what's working..
