Using the LM139AD and simulating using TINA with Hysteresis, however the results are not as expected. Using a non inverting configuration with R2 = 10M, and R1 = 290K. My Vref is 12V, so this brings my top trip point to around 15V. However, I want the bottom trip point to be 9V, but for some reason it's around the same amount as the rising trip point. My output is being pulled up to 3.3V, however my Vcc is 28V so my input can be 0 to 28V. Is there a way to set the lower trip point? I want 3V of hysteresis above and below 12V.
Key here is likely that your output is pulled up to only 3V3. Using comparator hysteresis - you rely on the difference in levels between comparator "on" and "off." As your comparator output may "swing" only ~ 3V - it will not be possible to create the 6V swing you seek - employing "just" Rfeedback (R2) and Rinput (R1). You would have to implement additional circuit paths and components to achieve your wide ranging trip points.
One method may be to allow the comparator's output to swing the full 28V - and limit just your applied output to 3V3. (a simple voltage divider downstream from the comparator's output should easily achieve)
I'm thinking maybe I don't need a 6V swing. More likly a 3V swing around 12V. Do you think this would be possible? and how does one achieve the lower trip point? Does it require more than just R2 and R1?
We've used such analog comparators for past 20+ years - have never required so high a hysteresis swing. Usual purpose of hysteresis is to prevent oscillation on/around the switching point - usually 100-300mV of hysteresis is more than adequate.
May well be that you can better achieve your objective by using a 2nd section of this 4 section comparator - having one trip @ 13.5V and second @ 10.5V. Use external logic to detect the appropriate condition. (note - comparator ap notes show how one may achieve "and, or, and invert" logic - using another section of same comparator.)
The more you allow the comparator output to "swing" - the greater the potential range of your hysteresis. As the comparator is open collector - you can pull-up the output to just about anywhere (positive) so long as you don't exceed Vcc. As stated - voltage divider can limit output high to 3V3 for your target circuit - even though the comparator output may yield a logic high of 12-24V.
The ratio between feedback & input resistors along with the difference in comparator output voltage (Voh vs Vol) will determine hysteresis. Again - suspect the broad range you seek is best achieved via 2nd section of your quad comparator. You may wish to implement a "window comparator" which will "report" when your input signal is w/in the range "greater than Vlo-set and less than Vhi-set." Two comparator sections can so implement...
Yes, I'm used to seeing much lower hysteresis myself. I saw 3V hysteresis on this other vendor's discrete interface IC. So if I ultimately select 100-300mV hysteresis I will still only have one trip point correct? Is this because I have a single supply comparator?
Continue to believe my earlier post fully guides - very doubtful that 3V is "hysteresis" - sounds much like IC's switching "level" - which is not hysteresis. Again - hysteresis usually comes into play when the input signal changes relatively slowly - and may "hang" at/around the switching threshold - causing the output to "chatter."
One of the thing you have to be careful about while using comparators is not to exceed the input common-mode voltage range as you set the trip point; doing so will virtually shut-off one side of the input differential pair resulting in very high Vos (perhaps >1V) that changes dramatically depending on the input voltage at the other input terminal. This could be perceived as very large input voltage hysteresis but it has actually nothing to do with a true hysteresis (commonly used in de-glitching comparators) but it's rather result of a non-working input differential pair. LM139 valid input common-mode voltage ranges from a negative rail ONLY up to Vcc-2V so you may NOT set a trip point closer than 2V below a positive rail - see PDS table below.
If this is not what causes your problem, instead of describing the circuit please provide us with the circuit diagram showing supply voltages, component values and input voltages.
Marek LisSr Application EngineerPrecision Analog - Burr-Brown ProductsTexas Instruments - Tucson
A 6V hysteresis swing is still possible even with a 3.3V pull-up voltage.
The amount of hysteresis is (Voh- Vol) * Rin / Rf Swing is 6V, Voh is 3.3V, and Vol is zero. So Rin/Rf is 1.82Rf could be 10k and Rin could be 18.2kNow, the reference voltage on the inverting input must be calculated. Vref = [ (VT+)(Rf) - (Rin)(VOL) ] / (Rin+Rf)Vref = [ 15V*10k - 18.2k*0V ] / 28.2kVref = 150kV / 28.2k = 5.32V
A resistor divider can lower your 12V to 5.32V for the inverting input.The final circuit is non-inverting and will switch output states at 9V and 15V
Regards,Ronald MichallickLinear Applications
TI assumes no liability for applications assistance or customer product design. Customer is fully responsible for all design decisions and engineering with regard to its products, including decisions relating to application of TI products. By providing technical information, TI does not intend to offer or provide engineering services or advice concerning Customer's design. If Customer desires engineering services, the Customer should rely on its retained employees and consultants and/or procure engineering services from a licensed professional engineer (LPE).
There is one precaution. The input voltage will have an effect on VOH.The pull up resistor should be at least 100 times less than the sum of the input and feedback resistors.In the example, that would be less than 282 ohms. So it would be good to increase the Rin and Rf resistors.To prevent IIB from causing a threshold shift, I suggest that the total resistances on both inputs be matched.
All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.
TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs andembedded processors, along with software, tools and the industry’s largest sales/support staff.