MCH wrote: > Am I reading the PIC 18F4520 docs correctly that you can only assign > analog inputs in ascending order? IOW, if I want only three analog > inputs, I have to use pins AN0, AN1, and AN2 and I cannot make the > selection based on open pins such as AN3, AN8, and AN9? > > Put another way, if I want AN5 to be analog, AN4-AN0 has to be analog as > well. > Yes and no Yes you can only put pins into analog mode in order. However afaict the only thing that putting a pin in analog input mode does is disable the digitial input buffers. So you can still use a pin as a digital output when it's set as analog (this was very useful when I had to drive a resistive touchscreen) and if you are prepared to put up with the extra power consumption caused by having a digital input floating between the rails you can use a pin as an analog input when it's set as digitial. -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist