# Makefile für ATmega32U4-Firmware für STS Multiplex Trockenätzmaschine
# Gaskasten-Steuerung
DEVICE = atmega16u4
F_CPU = 16000000
CC=c:\programs\Atmel-Studio\7.0\toolchain\avr8\avr8-gnu-toolchain\bin\avr-gcc.exe
CL = $(CC) -Wall -Wno-parentheses -Wno-char-subscripts -Os -mmcu=$(DEVICE) -D F_CPU=$(F_CPU) -D DEBUG $(LUFA)
all: sts.hex sts.lst
sts.elf: startup.S sts.cpp usb.cpp
$(CL) -o $@ $^ -nostartfiles -D MYSTARTUP
avr-size -C --mcu=$(DEVICE) $@
sts.hex: sts.elf
avr-objcopy -j .text -j .data -O ihex $< $@
sts.lst: sts.elf
avr-objdump -d $< > $@
flash: sts.hex
dfu-programmer $(DEVICE) erase
dfu-programmer $(DEVICE) flash $<
dfu-programmer $(DEVICE) launch
Detected encoding: UTF-8 | 0
|