diff options
| author | Vineet K <git@vineetk.net> | 2024-04-17 13:59:33 -0400 |
|---|---|---|
| committer | Shokara Kou <kou@13f0.net> | 2024-04-17 13:59:33 -0400 |
| commit | 661b58dfd04e84b38d2202387a9f67ff1515e03a (patch) | |
| tree | 108d9d71bbd1f417f40b9539ba88afdbab177068 | |
| parent | 8f258e4e02e1821692d39d87d4073e884bc2798a (diff) | |
update makefile for upcoming lcd code
| -rw-r--r-- | Makefile | 16 |
1 files changed, 13 insertions, 3 deletions
| @@ -4,10 +4,20 @@ OBJCOPY = avr-objcopy | |||
| 4 | 4 | ||
| 5 | PORT ?= /dev/ttyACM0 | 5 | PORT ?= /dev/ttyACM0 |
| 6 | 6 | ||
| 7 | all: | 7 | all: notes lcd |
| 8 | |||
| 9 | notes: | ||
| 10 | ${CC} ${CFLAGS} main.c | ||
| 11 | ${OBJCOPY} -j .text -j .data -O ihex a.out main.hex | ||
| 12 | rm -f a.out | ||
| 13 | |||
| 14 | flash_notes: notes | ||
| 15 | avrdude -p atmega328p -c arduino -P ${PORT} -b 115200 -U flash:w:main.hex:i | ||
| 16 | |||
| 17 | lcd: | ||
| 8 | ${CC} ${CFLAGS} main.c | 18 | ${CC} ${CFLAGS} main.c |
| 9 | ${OBJCOPY} -j .text -j .data -O ihex a.out main.hex | 19 | ${OBJCOPY} -j .text -j .data -O ihex a.out main.hex |
| 10 | rm -f a.out | 20 | rm -f a.out |
| 11 | 21 | ||
| 12 | flash: all | 22 | flash_lcd: notes |
| 13 | avrdude -p atmega328p -c arduino -P /dev/ttyACM0 -b 115200 -U flash:w:main.hex:i | 23 | avrdude -p atmega328p -c arduino -P ${PORT} -b 115200 -U flash:w:main.hex:i |
