# Draw a circuit with a voltage divider, two comparator ICs, LDR sensors

Discussion in 'Homework Help' started by imtrouvaille, May 30, 2018.

1. ### imtrouvaille Thread Starter New Member

May 2, 2018
2
0
I got this last question to practice for my exam and I got stuck. The question is draw a circuit with

• a voltage divider circuit,
• two Comparator ICs,
• LDR(Light Dependent Resistor) sensor
Outputs:

• If LDR at dark, comparator 1 = high and comparator 2 = low.
• If LDR under the light, comparator 1 = low and comparator 2 = high.
• If LDR at dark, the value of R in LDR becomes higher.
Assume that the range of R value in LDR = 0-100 kohm.

I've just tried to draw it as I understand it. If there's anything wrong, please kindly tell me. Thank you

2. ### MrAl AAC Fanatic!

Jun 17, 2014
5,368
1,150
Hi,

The resistance goes higher when dark so what does that mean for the voltage across the 10k resistor? What does that mean for the output of say cmp 1?

It looks like you have the two comparators swapped but you should think this out to see if that conclusion is right or wrong.

3. ### imtrouvaille Thread Starter New Member

May 2, 2018
2
0
I've just revised my circuit and it becomes like this. So, you said that voltage input from resistor LDR should be in V- on CMP 1 instead of V+?
and V+ on CMP 2 instead of V-?

4. ### WBahn Moderator

Mar 31, 2012
23,228
7,005
Your specs imply just two regions of operation. Your second circuit has three. If the specs really want just two regions of operation, I'd recommend chaining them instead of putting them in parallel.

You need to decide what the resistance of the LDR is at the boundary between "light" and "dark". Don't spend a lot of time on this part -- just pick a reasonable value. Then design the circuit so that the input to the comparators is half the supply voltage at this point.

5. ### dl324 AAC Fanatic!

Mar 30, 2015
7,489
1,785
Welcome to AAC!
Since you're still learning, you should learn to draw more readable schematics. Avoid unnecessary wire crossings and wire jogs. Use connection dot methodology or don't, but don't mix. If you use connection dots, you don't use "humps" when wires cross.

This is your schematic drawn more conventionally:

You still need to address any functionality issues.

6. ### MrAl AAC Fanatic!

Jun 17, 2014
5,368
1,150

Hello again,

When the LDR is dark the resistance is highest (assume 100k) and when the LDR is lighted the resistance is lowest (assume 0k). The requirement is that CMP1 goes high when dark, and goes low when lighted.
Your circuit seems to do the opposite but now that you've added a third resistor (for some reason i dont know) you created a point where neither CMP1 nor CMP2 is high, so that does not satisfy the requirement that one be low when the other is high.

A comparator ouput goes high when the non inverting input voltage is higher than the inverting input voltage. Look again at your first circuit and see if you can find out what is wrong. To find out, just replace the 100k LDR with either a 100k resistor (dark) or a 0k resistor (lighted). Make a table of what happens for each of those two conditions for both comparators. Compare the table to what is required from the problem statement.