See Flash Memory Control for documentation.

License#

Copyright 2018 Silicon Laboratories Inc. www.silabs.com

The licensor of this software is Silicon Laboratories Inc. Your use of this software is governed by the terms of Silicon Labs Master Software License Agreement (MSLA) available at www.silabs.com/about-us/legal/master-software-license-agreement. This software is distributed to you in Source Code format and is governed by the sections of the MSLA applicable to Source Code.

/***************************************************************************/
#ifndef __FLASH_H__
#define __FLASH_H__

#include "memmap.h"

bool halFlashEraseIsActive(void);

#ifndef DOXYGEN_SHOULD_SKIP_THIS

//[[ The following eraseType definitions must match the FIB erase types! ]]

#define MFB_MASS_ERASE 0x01
#define MFB_PAGE_ERASE 0x02
#define CIB_ERASE      0x03

sl_status_t halInternalFlashErase(uint8_t eraseType, uint32_t address);

sl_status_t halInternalFlashWrite(uint32_t address, uint16_t * data, uint32_t length);

EmberStatus halInternalCibOptionByteWrite(uint8_t byte, uint8_t data);

#endif //DOXYGEN_SHOULD_SKIP_THIS

#endif //__FLASH_H__

Functions#

bool

Tells the calling code if a Flash Erase operation is active.

Function Documentation#

halFlashEraseIsActive#

bool halFlashEraseIsActive (void )

Tells the calling code if a Flash Erase operation is active.

Parameters
N/A

This state is import to know because Flash Erasing is ATOMIC for 21ms and could disrupt interrupt latency. But if an ISR can know that it wasn't serviced immediately due to Flash Erasing, then the ISR has the opportunity to correct in whatever manner it needs to.

Returns

  • A bool flag: true if Flash Erase is active, false otherwise.


Definition at line 46 of file /mnt/raid/workspaces/ws.OJKVohJa4/overlay/gsdk/platform/base/hal/micro/cortexm3/flash.h