While driving one of our twelve Prius', the car was missing and not charging the HV battery. The battery of course quickly discharged. I turned the car off and erased the codes; the next time it 3/4 charged the HV battery but had no power for 10 miles.I turned the car off and erased the codes. I then drove it some more until it wouldn't go anymore, maybe 4 miles. Tried the same thing. It then only half charged the HV battery. Drove another 4 miles. The third time the car would just start and turn off(went from ready mode to no "ready" on the dash) . I decided the easiest thing to check was the crank position sensor (behind front right tire, lowest part of engine) . I pulled on the wire and it came unplugged with no effort. It was also full of oil and there was oil on the connector and the engine below the connector. I emptied the oil and plugged the wire back in, started the car and drove home. Some of those error codes mention a bad MG2 in the transmission. Car is running better than ever. I guess...always check the crank sensor first. After being cleaned with electrical spray and re-taped. Also, this is the way you are supposed to release the clip on the crank sensor. Slide the white plastic piece.