why this happen ...? when i pressed second button the voltage at led drop to 1v why but when i pressed first button it 5v..
plss help me.Someone...
this here my code
int buttonState = 0;
int buttonState2 = 0;
void setup()
{
pinMode(2, INPUT);
pinMode(3, INPUT);
pinMode(13, OUTPUT);
}
void loop()
{
// read the state of the pushbutton value
buttonState = digitalRead(2);
buttonState2 = digitalRead(3);
// check if pushbutton is pressed. if it is, the
// buttonState is HIGH
if (buttonState == HIGH)
{
// turn LED on
digitalWrite(13, HIGH);
}
if (buttonState2 == HIGH)
{
// turn LED on
digitalWrite(13, HIGH);
}
else
{
// turn LED off
digitalWrite(13, LOW);
}
delay(10); // Delay a little bit to improve simulation performance
}
for image download that below...