← Boolean Logic

Voting Lamp

easy

2-of-3 majority voting for a lamp output.

What it teaches

Majority voting (2-of-3). The lamp turns on when any pair of buttons agrees — list the pairs that satisfy the vote and combine them with OR. Introduces n-of-m logic that recurs in safety and fault-tolerance patterns.

Parameters

TagDirectionTypeDefaultDescription
In_ButtonAInputBOOL0First push button
In_ButtonBInputBOOL0Second push button
In_ButtonCInputBOOL0Third push button
Out_LampOutputBOOL0Lamp drive signal

Required behavior