I found a mistake in IAP from ST in source:ymodem.c If the file is between 64K and 128K, the protection of sector1 is not diasbled -> you cannot write data in this sector. change the source in ymodem.c in Ymodem_Receive () as follws: else if (size <= 0x1FFFF) { /* Disable S0 and S1 write protection and erase them */ FMI_WriteProtectionCmd(FMI_B0S0, DISABLE); FMI_WriteProtectionCmd(FMI_B0S1, DISABLE);//This missing FMI_EraseSector(FMI_B0S0); FMI_WaitForLastOperation(FMI_BANK_0); FMI_EraseSector(FMI_B0S1); } Best regards