Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- Blink Cop
- This code was modified from the public "Blink" script by Rudy Boyer.
- */
- void setup() {
- // initialize the digital pin as an output.
- // Pin 9 LED1 Red
- // Pin 10 LED1 Blue
- // Pin 11 LED2 Red
- // Pin 12 LED2 Blue
- pinMode(9, OUTPUT);
- pinMode(10, OUTPUT);
- pinMode(11, OUTPUT);
- pinMode(12, OUTPUT);
- }
- void loop() {
- digitalWrite(12, HIGH); // LED2 Blue ON
- delay(60); // wait
- digitalWrite(12, LOW); // LED2 Blue OFF
- delay(30); // wait
- digitalWrite(11, HIGH); // LED2 Red ON
- delay(60); // wait
- digitalWrite(11, LOW); // LED2 Red OFF
- delay(30); // wait
- digitalWrite(12, HIGH); // LED2 Blue ON
- delay(60); // wait
- digitalWrite(12, LOW); // LED2 Blue OFF
- delay(30); // wait
- digitalWrite(11, HIGH); // LED2 Red ON
- delay(60); // wait
- digitalWrite(11, LOW); // LED2 Red OFF
- delay(30); // wait
- digitalWrite(10, HIGH); // LED1 Blue ON
- delay(60); // wait
- digitalWrite(10, LOW); // LED1 Blue OFF
- delay(30); // wait
- digitalWrite(9, HIGH); // LED1 Red ON
- delay(60); // wait
- digitalWrite(9, LOW); // LED1 Red OFF
- delay(30); // wait
- digitalWrite(10, HIGH); // LED1 Blue ON
- delay(60); // wait
- digitalWrite(10, LOW); // LED1 Blue OFF
- delay(30); // wait
- digitalWrite(9, HIGH); // LED1 Red ON
- delay(60); // wait
- digitalWrite(9, LOW); // LED1 Red OFF
- delay(30); // wait
- digitalWrite(12, HIGH); // LED2 Blue ON
- delay(60); // wait
- digitalWrite(12, LOW); // LED2 Blue OFF
- delay(30); // wait
- digitalWrite(11, HIGH); // LED2 Red ON
- delay(60); // wait
- digitalWrite(11, LOW); // LED2 Red OFF
- delay(30); // wait
- digitalWrite(12, HIGH); // LED2 Blue ON
- delay(60); // wait
- digitalWrite(12, LOW); // LED2 Blue OFF
- delay(30); // wait
- digitalWrite(11, HIGH); // LED2 Red ON
- delay(60); // wait
- digitalWrite(11, LOW); // LED2 Red OFF
- delay(30); // wait
- digitalWrite(10, HIGH); // LED1 Blue ON
- delay(60); // wait
- digitalWrite(10, LOW); // LED1 Blue OFF
- delay(30); // wait
- digitalWrite(9, HIGH); // LED1 Red ON
- delay(60); // wait
- digitalWrite(9, LOW); // LED1 Red OFF
- delay(30); // wait
- digitalWrite(10, HIGH); // LED1 Blue ON
- delay(60); // wait
- digitalWrite(10, LOW); // LED1 Blue OFF
- delay(30); // wait
- digitalWrite(9, HIGH); // LED1 Red ON
- delay(60); // wait
- digitalWrite(9, LOW); // LED1 Red OFF
- delay(30); // wait
- digitalWrite(12, HIGH); // LED2 Blue ON
- delay(150); // wait
- digitalWrite(12, LOW); // LED2 Blue OFF
- delay(30); // wait
- digitalWrite(9, HIGH); // LED1 Red ON
- delay(150); // wait
- digitalWrite(9, LOW); // LED1 Red OFF
- delay(30); // wait
- digitalWrite(12, HIGH); // LED2 Blue ON
- delay(150); // wait
- digitalWrite(12, LOW); // LED2 Blue OFF
- delay(30); // wait
- digitalWrite(9, HIGH); // LED1 Red ON
- delay(150); // wait
- digitalWrite(9, LOW); // LED1 Red OFF
- delay(30); // wait
- digitalWrite(12, HIGH); // LED2 Blue ON
- delay(150); // wait
- digitalWrite(12, LOW); // LED2 Blue OFF
- delay(30); // wait
- digitalWrite(9, HIGH); // LED1 Red ON
- delay(150); // wait
- digitalWrite(9, LOW); // LED1 Red OFF
- delay(30); // wait
- digitalWrite(12, HIGH); // LED2 Blue ON
- digitalWrite(9, HIGH); // LED1 Red ON
- delay(150); // wait
- digitalWrite(12, LOW); // LED2 Blue OFF
- digitalWrite(9, LOW); // LED1 Red OFF
- delay(150); // wait
- digitalWrite(11, HIGH); // LED2 Red ON
- digitalWrite(10, HIGH); // LED1 Blue ON
- delay(150); // wait
- digitalWrite(11, LOW); // LED2 Red OFF
- digitalWrite(10, LOW); // LED1 Blue OFF
- delay(150); // wait
- digitalWrite(12, HIGH); // LED2 Blue ON
- digitalWrite(9, HIGH); // LED1 Red ON
- delay(150); // wait
- digitalWrite(12, LOW); // LED2 Blue OFF
- digitalWrite(9, LOW); // LED1 Red OFF
- delay(150); // wait
- digitalWrite(11, HIGH); // LED2 Red ON
- digitalWrite(10, HIGH); // LED1 Blue ON
- delay(150); // wait
- digitalWrite(11, LOW); // LED2 Red OFF
- digitalWrite(10, LOW); // LED1 Blue OFF
- delay(150); // wait
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement