It would be great if that could be combined with a 'debug' LED shield that shows the state of all pins (one LED per pin). The voltage divider for testing purposes would have to be below the LED threshold to prevent it turning on LEDs. In fact if the LEDs are arranged to come on weakly if tri-state, you could probably visually check the pin functions directly as well as use it as a debugging tool.
HHmmmmm..... (This is a word I learned from 10 years in Semiconductor test)...
mmmmm.. The conflicting desires are to be able to have a very simple, cheap test shield, VS one that can check both tri-state leakage AND source current capability AND sink current capability. Basically we are testing the pullup and pulldown FETS inside the ATMega, and the weak pullup disconnect FET switch, and the input level sensing circuit leakage. And the board/socket for shorts/opens.
The real simple approach I took in the shield I did basically will fail if ANY pin has excessive leakage to Vcc or Gnd in tri-state, and tests individual source/sink and the Analog inputs over some range.
I don't see a simple way to check individual pins for leakage + and - and also do source-sink. I've thought of building a separate leakage test shield.
I can see lots of ways to build a more comprehensive tester with an Arduino Mega test driver and a bunch of FET switches. But that's a lot more complex. (I've designed testers that took $80,000 to build in quantities of 20 .. but this is just as much fun and probably more...)
Any suggestions on circuitry would be appreciated.. always better with multiple people thinking!
I haven't figured a way to test individual low-current leakage per pin in a passive self-test mode.
I think my design just tests for board/socket continuity and shorts, output pin FET damage and Analog multiplexor/A2D. But this is mostly for those of us with several Arduinos that go in Harms Way like classes and workshops (maybe OUR workshop!), and for me, testing Arduino Clones (Um, "Open Source Copies") better than some factory did, before selling them.