/* Erase All FLASH This performs all operations necessary to erase all sectors in the FLASH memory.  */
void flash_erase_all_sectors(void)
/* Erase All FLASH This performs all operations necessary to erase all sectors in the FLASH memory.  */
void flash_erase_all_sectors(void)
{
	flash_wait_for_last_operation();
	FLASH_CR |= FLASH_CR_MER1 | FLASH_CR_MER2;
	FLASH_CR |= FLASH_CR_START;
	flash_wait_for_last_operation();
	FLASH_CR &= ~FLASH_CR_MER1 & ~FLASH_CR_MER2;
}