2024-01-07 15:45:51 +01:00
|
|
|
const int OUT = LED_BUILTIN; // Ausgangs pin
|
2024-05-12 15:55:59 +02:00
|
|
|
const int TIME_ON = 5 * 60; //länge des Pulses in Sekunden
|
|
|
|
const int TIME_OFF = 30 * 60; //zeit zwischen den Pulsen in Sekunden
|
|
|
|
const int T_ON = TIME_ON * 1000;
|
|
|
|
const int T_OFF = TIME_OFF * 1000;
|
2024-01-07 15:45:51 +01:00
|
|
|
void setup() {
|
|
|
|
// put your setup code here, to run once:
|
|
|
|
pinMode(OUT, OUTPUT);
|
2024-05-12 15:55:59 +02:00
|
|
|
Serial.begin(9600);
|
|
|
|
Serial.print("Länge des Pulses: ");
|
|
|
|
Serial.print(TIME_ON);
|
|
|
|
Serial.println(" Sekunden.");
|
|
|
|
|
|
|
|
Serial.print("Zeit zwischen den Pulsen: ");
|
|
|
|
Serial.print(TIME_OFF);
|
|
|
|
Serial.println(" Sekunden.");
|
2024-01-07 15:45:51 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
void loop() {
|
|
|
|
// put your main code here, to run repeatedly:
|
|
|
|
digitalWrite(OUT, HIGH);
|
2024-05-12 15:55:59 +02:00
|
|
|
delay(T_ON);
|
2024-01-07 15:45:51 +01:00
|
|
|
digitalWrite(OUT, LOW);
|
2024-05-12 15:55:59 +02:00
|
|
|
delay(T_OFF);
|
2024-01-07 15:45:51 +01:00
|
|
|
}
|