Design a logic circuit that triggers an alarm if motion is detected or if the door is opened

Design a logic circuit that triggers an alarm if motion is detected or if the door is opened, but not if the security system is disarmed. What’s the correct combination of logic gates?

What is the correct Answer? Share your answers and explanations.

Option A:

An AND gate for the motion detector and door sensors, and a NAND gate for the output of the AND gate and the security system

Option B:

An XOR gate for the motion detector and door sensors, and a XNOR gate for the output of the XOR gate and the security system

Option C:

An NOR gate for the motion detector and door sensors, and an OR gate for the output of the NOR gate and the security system

Option D:

An OR gate for the motion detector and door sensors, and a NOR gate for the output of the OR gate and the security system

Show Answer

Answer: D

Show Explanation

An OR gate would be used for the motion detector and door sensors because we want the alarm to trigger if either of these conditions is true (motion is detected OR the door is opened).

However, we don’t want the alarm to sound if the security system is disarmed, regardless of the states of the motion detector or door sensors. To implement this, we would use a NOR gate for the output of the OR gate and the security system.

A NOR gate only outputs true when neither of its inputs is true. So, the alarm would only sound when motion is detected or the door is opened AND the security system is armed.

1 Like