Verify issue - and maybe a push in the right direction

Hi,

First of all I am a beginner in the Arduino univers, so I apolligies for stupidity. :wink:

I am trying to program a timer for a fan that is connected to my Nano board (Power = 5V[27], Ground[04] and PWM = D3[06]) and have tried to write some code to do this but am running into an issue when trying to verify the code "Compilation failed. Please report this issue on our Forum" .. the code is:

const int AirFan = 4;

void setup() {
    Serial.begin(9600);
    pinMode(AirFan, OUTPUT);
    
}

void loop() {
    int delayPeriod = 100;
    digitalWrite(AirFan, HIGH);
    delay(delayPeriod);
    digitalWrite(AirFan, LOW);
    delay(delayPeriod);
}

What can be wrong?

.. another question:

I would like to make so that the fan starts delayed by 30 seconds after power is turned on .. after that the fan should run for 15 seconds and turn off, and every 15 minutes the fan should run for 15 seconds .. how can I program this? .. any examples is very much appriciated :slight_smile:

Best Regards
Stig :slight_smile:

Hi, do you get any specific error? Can you share the sketch link?