Roger Weichert wrote: > I'm building a project (using a PIC16F627) and have reached the stage > where I'm ready to design the board layout, so need to decide what > I'm going to do with the unused port lines. ... > > I'm aiming for a tiny pcb with no wasted space, so am trying to avoid > any components I don't absolutely need to have. In that case make them outputs and make sure the firmware drives them. If any are input-only pins, then tie them to Vss or Vdd directly or thru a resistor. If you have a little extra space, bring the unused pins out to pads and still make sure they are driven. If you have a little more extra space you can add 100Kohm pullup or pulldown resistor pads. You don't actually have to load the parts, so it's only a board area issue. Any changes to make use of the pins would require rework and firmware change anyway. The parts can be added to the pads and the firmware changed at that time to make pins inputs if that's what's needed. If you were able to fit the resistor pads then the next step up is to install at least a few of the resistors and make the pins inputs. Unless this is a very high volume project, a few cents for the extra resistors won't matter. The advantage here is the same firmware can then auto-detect different hardware versions. In future versions or reworked versions of this board the input lines would be pulled differently. This topic comes up occasionally, so from experience I expect you'll hear voodoo electronics about how lines should always have resistors on them, not driven by the micro in case of short, etc. All these come down to protecting the hardware from firmware bugs. That may make sense for the development prototype, but is just silly superstition for volume production. ******************************************************************** Embed Inc, Littleton Massachusetts, http://www.embedinc.com/products (978) 742-9014. Gold level PIC consultants since 2000. -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist