/* Clear All Status Flags. 
Program error, end of operation, write protect error, busy. Both banks cleared.  */
void flash_clear_status_flags(void)
/* Clear All Status Flags. 
Program error, end of operation, write protect error, busy. Both banks cleared.  */
void flash_clear_status_flags(void)
{
	flash_clear_pgerr_flag();
	flash_clear_eop_flag();
	flash_clear_wrprterr_flag();
	flash_clear_bsy_flag();
	if (DESIG_FLASH_SIZE > 512) {
		flash_clear_pgerr_flag_upper();
		flash_clear_eop_flag_upper();
		flash_clear_wrprterr_flag_upper();
		flash_clear_bsy_flag_upper();
	}
}