If I understood correctly, the problem arises you have rerogrammed the peripheral and not the central. This is expected as bonding information need to be present in both the devices. But it should have worked once you used the the CyBle_GapRemoveBondedDevice and the further steps you have mentioned on the central side. Even after this if the authentication fails, there could be a possiblity that the flash reomval was not yed done properlt. You need to call the CyBle_StoreBondingData API again and again till that API returns success (usually it requires to call twice, not more). Did you confitm that the API returns true?
- Madhu Sudhan