William J. Kitchen wrote: > You could get rid of the resistors by just leaving the pins > unconnected and set as outputs, but this leaves the possibility of the > pins floating while the chip is initializing, This is the prototypical example of muddled thinking. So the pins float for a millisecond during initialization. So what? We are talking about currents of perhaps hundreds of microamps (per input) *at most* here, if it really mattered more, then *all transitions* would be prohibited! That is absurd. The situation is: An input in the "switching" voltage range *whether "floating" or biassed deliberately by the application circuit* causes some conduction of both input FETs, resulting in a current from rail to rail (temporary class A operation - class A amplification always has a quiescent current). The chip is designed to tolerate this current, but it represents wasted current in battery-powered applications. There has been a suggestion that inputs "floating" in this range may cause faulty operation. Think carefully! If this were so, then *none* of those nifty time-constant circuits to measure analog voltages or capacitance would be possible. There is *one* caveat to this - it *may* cause problems if you are using the ADC. That's all. > or in a fault situation in which the pins are tristated > unintentionally. Oh dear, what a nasty possibility! *However*, nowhere near as nasty as the equally probable exact opposite - a pin accidentally turned into an output whilst tied directly to rail. Even a 10 kilohm resistor will I suspect, draw more "leakage" current than an input held at ¸Vcc. In summary, leave them open, initialize them as outputs, use shadow registers, rest easy. If the TRIS registers subsequently get scrambled despite all this, well, tough luck, just be glad they weren't tied to a rail. Here endeth the FAQ. -- Cheers, Paul B.