The following may be causes of the failure to program on the PIC32MM:
A
The PIC32MM GPL devices may fail to program when the sleep retention mode is used. This is due to an errata issue where the MCLR function is not functioning after going into retention sleep. We recommend doing the following to workaround the problem:
- Put a long delay after powerup and before going to sleep.
- On powerup, quickly erase the chip before it goes to sleep.
Note: The MPLAB® IPE erase command is faster at accomplishing this erase than MPLAB X IDE, so we recommend using MPLAB IPE erase.
B
Using the PIM for PIC32MM0064GPL036, on the Explorer16 with MPLAB ICD 3 In-Circuit Debugger, you might encounter this error:
Address: 1fc00018 Expected Value: 335a9d00 Received Value: 7fde9900 Failed to program device
This happens when the jumper JP2 is off. Put the jumper on and it will program. Testing shows that this seems related to the RB10/TDO/PGED2 pin. It has to be grounded.