You would want a voltage comparator. This is best done with op amps. Look at this page, halfway down:
http://home.cogeco.ca/~rpaisley4/Comparators.html
Look for the "Voltage Window Detector Circuit". Notice how the threshold voltages (V reference 1 and V reference 2) are set with 3 resistors. You can make the window as narrow or as wide as you want. For the input, you would connect a resistor (say, 1k) between V+ and the input, and the EOL resistor, also 1k, between the input and 0V.
_________________________
"If you don't know what you're doing, do it neatly..."