Hi, I've got an Atmega168 on a breadboard connected to power with only one LED attached to pin 5 (digital pin 3). I also have a 100nF capacitor across ground the +5v. Either way the program it is running should leave the LED off, but it randomly strobes.
Here's where I get confused:
if I lift said breadboard off the table...the LED goes off and stays off. Put it on...or even near the table (within maybe 8mm) and the LED starts going crazy again. It also seems to have a similar effect if I replace the table with my hand. I played with it some more, and it seems the closer my hand/table is to the pins of the atmega the more likely it is to strobe, the other side of the breadboard (where there is no micro) isn't effected.
I even tried swapping breadboards...still got the same effect.
a painted metal table will cause the same thing. The board and the table are at different potentials and the board is picking up noise (local High Power AM Radio station?) and 'displaying' it. The Clue was that the light changed when you picked it up. Likely if you use a piece of wood perhaps an inch 25.4mm thick the problem will go away.
Yeah someone else had a very similar issue with a Mega2560 and a GLCD... Turned out to be the same problem exactly...
Noise pickup on an 'un-terminated' input lead. Still a good puzzler for a while though.
Yeah, come to think of it... the OP noted that he went to basics and still had the issue with pin "38? 39?, I really don't remember
Just a silly issue that 100k pull downs would have prevented.
Floating CMOS ports are Always a possible issue, As you Well Know.