2009-12-06 07:33 PM
FLASH_ErasePage function time delay
2011-05-17 04:32 AM
i have used following step To write new data inside the flash of stm32f103rbt6
step 1: FLASHStatus=FLASH_ErasePage(Flash address); Step2: FLASH_ProgramWord(Flash address,data); i am able to write and retreive data in the flash . But ''FLASH_ErasePage'' function creating some time delay(aprox 250ms). this time delay creates flicker in seven segment display(ie Interrupt Driven multiplux) any solution to solve the delay in page erase function [ This message was edited by: missiontous on 01-12-2009 12:28 ]2011-05-17 04:32 AM
Are you saying that FLASH_ErasePage is causing interrupts to be delayed by 250mS or are you saying that FLASH_ErasePage is taking 250mS to return?
2011-05-17 04:32 AM
Hi,
In STM32 product during a write operation to the Flash memory, any attempt to read the Flash memory will stall the bus.I think you should remap your interrupt ISR into internal SRAM to overcome the interrupt latency due to page erase. may this help. A+2011-05-17 04:32 AM
Hi
FLASH_ErasePage is taking 250mS to return i configured SRAM using-> NVIC_SetVectorTable(NVIC_VectTab_RAM, 0x0); but the timer2 interrupt stoped working is there any other solution to solve this problem?[ This message was edited by: missiontous on 03-12-2009 10:13 ]2011-05-17 04:32 AM
Hi missiontous,
If your display is being driven from interrupt it should not matter how long FLASH_ErasePage takes. If your seeing flicker then the interrupt must be being delayed - for the reason stated by armmcu.engineer. Can you confirm that the display code is in an interrupt? If the display code is not in an interrupt routine then we can then look at a solution to your problem. Regards Trevor2011-05-17 04:32 AM
Hi trevor,
i am using Timer2 interrupt to drive sevensegment display. i want to store data inside the flash every 1 minute once. this creating display flicker every 1 minute once. pls guide how to map and configure interrupt vector to SRAM?2011-05-17 04:32 AM
The flash has an endurance of 10000 write cycles. 10000 minutes is less than 7 days!
You realise you don't need an erase for every write -- you erase a page (1 or 2k bytes) and then write a word (2 bytes) at a time. Maybe post some code. Trevor2011-05-17 04:32 AM
Hi trevor
please guide how to move/configure/map IVT to SRAM thanks2011-05-17 04:32 AM
Check SCB->VTOR, resp. NVIC_SetVectorTable.
The offset must be aligned to size of IVT increased to nearest power of 2.