dimention11 said:
hello i have an analog 0-5v i wish to change to a digital (ttl) 0-5v.
I assume it is as simple as hooking up a transistor.
am i right...
Others have given a lot of replies.
There are a whole series of 'questions' that vary the answer. The first
(already mentioned) is the switching 'point'. However there are two values
here. The 'on' point', and the 'off' point. A degree of hysteresis is
normally needed to avoid instability. On a comparator, this is achieved by
a small amount of positive feedback applied around the comparator. Schmitt
trigger gates have this type of behaviour built in. However there is also
the question of speed (if the required switching rates are high, it may
well alter the solution), 'direction' (whether you want/mind the output
being inverted, so a high level gives a logic '0', and a low level a logic
'1'), what load the digital output needs to drive etc..
A very 'cheap' solution for certain of these combinations, is the TL431
voltage regulator IC!. This is a three terminal IC, whose output pin is
pulled 'low', when it's reference input rises above 2.495 (typical) volts.
Connect the reference input to your analog signal, and the output to +5v,
via a resistor, and this gives an inverting output, which otherwise just
about meets your specification, and is small, and cheap. It might be a
solution.
Best Wishes