Skip to content

Instantly share code, notes, and snippets.

@ulitiy
Created October 30, 2020 12:49
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ulitiy/a2b55c8d6ff86dca5956551208b76921 to your computer and use it in GitHub Desktop.
Save ulitiy/a2b55c8d6ff86dca5956551208b76921 to your computer and use it in GitHub Desktop.
#include <Servo.h>
Servo myservo;
const int servoPin = 9;
const int ledPin = 13;
void setup() {
myservo.attach(servoPin);
pinMode(ledPin, OUTPUT);
digitalWrite(ledPin, LOW);
myservo.write(180);
delay(1000);
myservo.detach();
}
void loop() {
myservo.attach(servoPin);
myservo.write(30);
delay(575);
myservo.write(180);
delay(1500);
myservo.detach();
delay(3600000);
}
@dwinbam18
Copy link

Where to change the code when the interval is 4 hours

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment