subject

This is what I currently have, im just not sure about how I should go about making the lights blink since I only have 1 pushbutton int ledPinSingle= 9;
int ledPinFlash1= 10;
int ledPinFlash2= 11;
int ButtonPin =2;

void setup(){
pinMode(ledPinSingle, OUTPUT);
pinMode(ledPinFlash1, OUTPUT);
pinMode(ledPinFlash1, OUTPUT);
pinMode(ButtonPin, INPUT);
Serial. begin(9600);

}

void loop(){
if(digitalRead(ButtonPin)==HIGH)
{
digitalWrite(ledPinSingle, HIGH);
Serial. print("Single LED on");
}
else if (digitalRead(ButtonPin) == LOW){
digitalWrite(ledPinSingle, LOW);
digitalWrite(ledPinFlash1,HIGH);
digitalWrite(ledPinFlash2,LOW);
Serial. print("Flashing back and forth");
delay(50);

}

}


This is what I currently have, im just not sure about how I should go about making the lights blink

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 23:00
Which factor is the most important when choosing a website host? whether customers will make secure transactions the number of email accounts provided the purpose of the website the quality of the host control panel
Answers: 3
question
Computers and Technology, 23.06.2019 19:30
Of the following pieces of information in a document, for which would you most likely insert a mail merge field?
Answers: 3
question
Computers and Technology, 24.06.2019 08:20
Evaluate the scenario below and indicate how to handle the matter appropriately. situation: michael received an e-mail from what he thought was his doctor’s office, requesting his social security number. since he had just been in to see his doctor last week, he replied to the e-mail with his social security number.
Answers: 2
question
Computers and Technology, 24.06.2019 11:40
100 pts. first person gets brainliest
Answers: 2
You know the right answer?
This is what I currently have, im just not sure about how I should go about making the lights blink...
Questions
question
Mathematics, 06.04.2020 18:23
Questions on the website: 13722367