You are on page 1of 1

void setup() {

// pins initializition:
Serial.begin(9600);
pinMode(13, OUTPUT);
digitalWrite(13, LOW);
}

void loop() {
if (analogRead(A0) > 900 || analogRead(A2) > 600 || analogRead(A5) < 400)
{
digitalWrite(13, HIGH);
}

if (analogRead(A0) < 900 && analogRead(A2) < 600 && analogRead(A5) > 400)
{
digitalWrite(13, LOW);
}
delay(2);
}