Toyota Repair: ECU error codes & wiring, jumper wire, haynes manual


Question
I have a 1991 Toyota pickup.  390000Kms.  2.4L 22R-E engine, 5spd. I've been having several problems.  Firstly, the truck intermittently idles weird.  It will rev to about 1500 RPM, then suddenly drop to about 400, then rise and fall again.  It will continue for different periods of time, and Im not sure what causes it, or stops it.  I've noticed on certain occasions, that depressing the brake pedal will trigger the problem.  Also, on the diagnostic panel, after connecting a jumper wire, the ECU will give me a flash code. Refrencing this code in my Haynes manual says that the ECU is not receiving the "NE" or "G" signal within 2 seconds of the engine being cranked. The color codes for the wiring in this manual are not correct, so I am unable to diagnose further.  Can you provide a proper ECU wiring diagram for this truck, or suggest any other potential problems please?
   Also, The vehicle gets terrible gas mileage.  There are no leaks that I can find. I've checked injector seals, all fuel lines, gas tank. ect. Any ideas on where to look for probable causes?

Thanks Ted, You've been a super help in the past

-=Dax=-

Answer
NE and G signals are generated by the distributor, they tell the computer that the engine is cranking over and at what rpm, if the values are correct the engine will start and run normally, distributor problems on these engines are common, I recommend replacing the distributor, you can save some money by getting one from an aftermarket source or a used one from a salvage yard. If you still need the wiring diagram send me an email address, reply directly to me at tedrttr@yahoo.com