|
|
|
Component
IntFLASH
Internal FLASH
Events:
(Events are call-back functions called when an important event occurrs.
Please see the Embedded Components page for more information.)
-
EventModule
- Name of the user module (without extension), where the events from this component are placed.
-
OnWritePageEnd
- Event is called after entire virtual page is written to FLASH. This event is available only if Virtual page property is selected and an Interrupt service/event is selected.
ANSIC prototype: void OnWritePageEnd(void)
- Priority - Priority of the event routine. Default value is based on the interrupt priority defined in property Interrupt priority. For details see description below of the page.
-
OnWriteEnd
- Event is called after a write operation to FLASH memory is finished. This event is available only if an and an Interrupt service/event is selected.
ANSIC prototype: void OnWriteEnd(void)
- Priority - Priority of the event routine. Default value is based on the interrupt priority defined in property Interrupt priority. For details see description below of the page.
-
OnSaveBuffer
- This event is only available if Safe write is selected in Write method property and "Buffer type" property is set to Implemented by the user. The event is called when it is needed to save the content of FLASH before erasing it. It could be called twice during the write operation depending on the location of the written data inside of the flash sector. The total sum of bytes to save never exceeds the size of the flash sector. Calling order of OnSaveBuffer and OnRestoreBuffer events also depends on the size and location of the written data.
ANSIC prototype: void OnSaveBuffer(%'ModuleName'_TAddress Addr, word Size)
- Addr:ComponentName_TAddress - Address in FLASH
- Size:word - The size of a buffer to save
-
OnRestoreBuffer
- This event is available only if Safe write is selected in Write method property and "Buffer type" property is set to Implemented by the user. The event is called after the erasure of the sector, which is needed to be modified. The backup data should be restored by the event. RestoreToFlash method must be used for such a purpose (other write-to-FLASH methods returns an error if called during this event).
ANSIC prototype: void OnRestoreBuffer(%'ModuleName'_TAddress Addr, word Size)
- Addr:ComponentName_TAddress - Address in FLASH
- Size:word - The size of a buffer to restore
-
OnEraseError
- This event is only available when Safe write is selected in Write method property and "Buffer type" property is set to "Implemented by the user" value. The Event is called when a sector erase error occurred. The event allows user to de-allocate the buffer with the stored data, even the OnRestoreBuffer event is not called because FLASH erase error.
ANSIC prototype: void OnEraseError(void)
For each generated event it is possible to set:
|