Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: e8bc1cd609
Fetching contributors…

Cannot retrieve contributors at this time

31 lines (22 sloc) 0.624 kb
DEVICE = atmega1284p
MCU = atmega1284p
AVRDUDE_DEVICE = m1284p
PORT = \\\\.\USBSER000
CFLAGS=-g -Wall -mcall-prologues -mmcu=$(MCU) $(DEVICE_SPECIFIC_CFLAGS) -Os
CC=avr-gcc
OBJCOPY=avr-objcopy
OBJDUMP=avr-objdump
LDFLAGS=-Wl,-gc-sections -Wl,-relax -Wl,-Map="$(@:%.elf=%.map)"
AVRDUDE=avrdude
TARGET=led_strip
all: $(TARGET).hex $(TARGET).lss
clean:
rm -f *.o *.hex *.elf *.map *.lss
%.hex: %.elf
$(OBJCOPY) -R .eeprom -O ihex $< $@
%.lss: %.elf
$(OBJDUMP) -h -S $< > $@
%.elf: %.o
$(CC) $(CFLAGS) $^ $(LDFLAGS) -o $@
program: $(TARGET).hex
$(AVRDUDE) -p $(AVRDUDE_DEVICE) -c avrisp2 -P $(PORT) -U flash:w:$<
Jump to Line
Something went wrong with that request. Please try again.