Comparator with Hysteresis Calculator

Comparator with Hysteresis










Formulas

1. To calculate \( V_{inL} \):

\[ V_{inL} = \frac{R1}{R1 + R2} \cdot (V_{OL} - V_{ref}) + V_{ref} \]

2. To calculate \( V_{inH} \):

\[ V_{inH} = \frac{R1}{R1 + R2} \cdot (V_{OH} - V_{ref}) + V_{ref} \]

3. To calculate Hysteresis \( H \):

\[ H = \frac{R1}{R1 + R2} \cdot (V_{OH} - V_{OL}) \]

Example Calculation

Let's assume the following values:

Step 1: Compute the lower threshold voltage:

\[ V_{inL} = \frac{10}{10 + 100} \cdot (0 - 2.5) + 2.5 = \frac{10}{110} \cdot (-2.5) + 2.5 = -0.227 + 2.5 = 2.27 \text{ V} \]

Step 2: Compute the upper threshold voltage:

\[ V_{inH} = \frac{10}{10 + 100} \cdot (5 - 2.5) + 2.5 = \frac{10}{110} \cdot 2.5 + 2.5 = 0.227 + 2.5 = 2.73 \text{ V} \]

Step 3: Compute the hysteresis:

\[ H = \frac{10}{10 + 100} \cdot (5 - 0) = \frac{10}{110} \cdot 5 = 0.454 \text{ V} \]