analogRead Basic Help.

What's wrong with the even simpler version?

It has no hysteresis.