Distinguish Reset and  Power-On

Hi,

is there a way to test whether setup was called because the Arduino was powered on or whether the reset button was pressed?

BTW: The Arduino is a great platform! Thanks to all people making this happen. I already did some smaller LED/LCD projects. The current thing is a model train automatic. Video: LGB Arduino Automatic - YouTube

Roland

There is a bit in the AVR status register that tells you which reset was used. I think it's in the one called MCUSR (I can check if you can't find it).

Yes. Thanks a lot!