I am creating a bootloader SWE that erases an app from block 16 and flashes an app there while flashing suddenly the memory becomes zeros and we cant do any operations on memory and even flashing the app itself through the debugger doesn't work until erasing it through the flash driver. What could be the cause of it?