Hi,
More detailed, more pedantic:
"The difference between two inputs" just means "A-B".
So mathematically the task is: if (A - B) < 0.05V
So if A = 3 and B = 4 ... the result is FALSE.
If you don't want this then you probably mean: if the absolute value of the difference is < 0.05 V
This mathematically means: if |A - B | < 0.05 V
Or in hardware: difference --> rectifier --> comparator
But this is equal to: if --0.05 < (A-B) < 0.05
Or... if (A - B) < 0.05 AND (A-B) > -0.05
This could be done with the above mentioned window comparator, by using thresholds of -0.05V and +0.05V
Things you additionally need to consider/ define:
* what supply voltage do you have? (Do you have limits/ targets for the supply current?
* how accurate do you want the threshold?
* hysteresis to avoid jittery output (chattering)
* timing...how long do you allow the output to get the expectated state? Nanoseconds, milliseconds?
* define the output levels more clear. 0V as well as 1V are absolute values that allow no tolerance. This never can be realized. --> Please define the valid range for each output level.
Lets say: (example)
* LOW: -0.1V .... +0.25V
* HIGH: 0.75V ... 1.25V
Klaus