Project

General

Profile

Revision 89f527ad

ID89f527ad74f884b26429c0436fc0fbf0bdf39d17
Parent 6030b995
Child d88f80e5

Added by Thomas Mullins about 10 years ago

Added makefile magic to program bootloader in correct place

View differences:

scout_avr/bom/Makefile
12 12
SRC=bom.c tiny-twi.c
13 13
HDR=
14 14
FLAGS=-mmcu=$(MCU) -DF_CPU=$(F_CPU)UL -funsigned-char -Os -fpack-struct -Wall
15
BOOT_FLAGS=$(FLAGS) -Wl,-Ttext=0xA00
16
VECT_FLAGS=$(FLAGS) -nostartfiles
15 17

  
16 18
default: bom.hex
17 19

  
......
30 32
test.elf: test.c tiny-twi-sync.c tiny-twi-sync.h
31 33
	avr-g++ $(FLAGS) test.c tiny-twi-sync.c -o $@
32 34

  
35
bootloader.elf: bootloader.c tiny-twi-sync.c tiny-twi-sync.h
36
	avr-g++ $(BOOT_FLAGS) bootloader.c tiny-twi-sync.c -o $@
37

  
38
bootvectors.elf: bootvectors.S
39
	avr-g++ $(VECT_FLAGS) bootvectors.S -o $@
40

  
41
burn: bootloader.hex bootvectors.hex
42
	avrdude -p $(PART) -c $(PROG) -P usb -B 5 -U flash:w:bootloader.hex \
43
	  -U flash:w:bootvectors.hex

Also available in: Unified diff