summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorVineet K <git@vineetk.net>2024-04-15 21:55:51 -0400
committerkar <kar@13f0.net>2024-04-15 21:55:51 -0400
commitfc85413fa9891c32b4d82cd7d0e27fd04220be91 (patch)
treef265522f5db981cbd5ef787564da85b016aeade6 /Makefile
parent8f3b27a6527cd267c450a3b8018f1ffcc11aeb54 (diff)
start working on the speaker arduino code
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile11
1 files changed, 11 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..9eba3af
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,11 @@
1CC = avr-gcc
2CFLAGS = -O2 -Wall -Wextra -Werror -mmcu=atmega328p
3OBJCOPY = avr-objcopy
4
5all:
6 ${CC} ${CFLAGS} main.c
7 ${OBJCOPY} -j .text -j .data -O ihex a.out main.hex
8 rm -f a.out
9
10flash: all
11 avrdude -p atmega328p -c arduino -P /dev/ttyACM0 -b 115200 -U flash:w:main.hex:i