#include <Arduino.h>
#define LED 2
void setup() {
// put your setup code here, to run once:
pinMode(LED, OUTPUT);
}
void loop() {
// put your main code here, to run repeatedly:
digitalWrite(LED, LOW);
delay(500);
digitalWrite(LED,HIGH);
delay(500);
}
This is my code very simple with here no errors but when i try and run it I have those errors :
C:\Users\jauda\AppData\Local\Temp\ccB7euus.ltrans0.ltrans.o: In function `main’:
:(.text.startup+0x0): undefined reference to `init’
:(.text.startup+0x4c): undefined reference to `delay’
:(.text.startup+0x5e): undefined reference to `delay’
collect2.exe: error: ld returned 1 exit status
*** [.pio\build\nanoatmega328\firmware.elf] Error 1
and I searched on internet but didn’t find any answer so I try here