/* check for FLASH wipe protection enabled. 
Use this function to determine if FLASH wipe protection is enabled. */
bool am_hal_flash_wipe_flash_enable_check(void)
/* check for FLASH wipe protection enabled. 
Use this function to determine if FLASH wipe protection is enabled. */
bool am_hal_flash_wipe_flash_enable_check(void)
{
    if ( customer_info_signature_erased() )
    {
        return false;
    }
    if ( !am_hal_flash_customer_info_signature_check() )
    {
        return false;
    }
    return AM_REGVAL(AM_HAL_FLASH_INFO_SECURITY_ADDR) &
            AM_HAL_FLASH_INFO_SECURITY_FLASHWIPE_M ? false : true;
}