x-cube EEPROM failing at EE_Init between step 3 and step 4
Two of my MCUs are halting in same problem after running for about a year. There have not been many writes/cycles as I have a erase cycle counter which shows 27 so its not wear out problem. The EE_Init function gets stuck at step 4 and returns with EE_WRITE_ERROR. Here is the page situation. I use page 2 and 3 of second bank. Page 2 is in state RECEIVE (aaaa, ffff, ffff, ffff), the page is otherwise empty. Page 3 is in state ERASING (aaaa, aaaa, ffff, aaaa) and the page is full with data. The problem is already found in step 3 (pagestate = STATE_CORRUPTED), where it checks that page 2 is RECEIVE but page 3 is not ERASED. The code however does not do anything about it. It only deals with the case if (pagestate = STATE_RELIABLE). Recovery transfer occurs in step 3 only for reliable page state . Therfore in step 4, there is no active page, no valid page and finally the function exits with EE_WRITE_ERROR
Here are the contents of page 2 starting at 0x08041000:

Here are the contents of page 3 starting at 0x08041800:

Can someone help me out with this?
