I would guess the PCM is crapping out, or you have a wiring problem. You could start by working off each post of the battery. Check the wires closely. Connections should be clean and tight. Corrosion can occur inside the terminal, so give each wire a good tug.