diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..bc43382 --- /dev/null +++ b/Makefile @@ -0,0 +1,18 @@ +TARGETNAME = togglePin +BUILDFOLDER = ./build/ +TARGET = $(BUILDFOLDER)$(TARGETNAME) + +INC = -Isrc/include -I/usr/lib/avr/include/ +CFLAGS = -Wall -Wpedantic -Wextra -g -Os -mmcu=atmega32u4 + +SRC = $(wildcard src/*.c) + +all: $(TARGET) + +$(TARGET): $(SRC) + mkdir -p build + avr-gcc -o $@.elf $^ $(CFLAGS) $(INC) + avr-objcopy -j .text -j .data -O ihex $@.elf $@.hex + +clean: + rm -fr ./src/*.o ./build/ diff --git a/src/togglePin.c b/src/togglePin.c new file mode 100644 index 0000000..77e9a0e --- /dev/null +++ b/src/togglePin.c @@ -0,0 +1,9 @@ +#include +#include +#include + +int main() +{ + + return 0; +}