Simplify the internal serial extraction routines for each architecture.
[pub/lufa.git] / Bootloaders / HID / makefile
index 555c727..6d8fbf5 100644 (file)
 MCU = at90usb1287\r
 \r
 \r
 MCU = at90usb1287\r
 \r
 \r
+# Target architecture (see library "Board Types" documentation).\r
+ARCH = AVR8\r
+\r
+\r
 # Target board (see library "Board Types" documentation, NONE for projects not requiring\r
 # LUFA board drivers). If USER is selected, put custom board drivers in a directory called\r
 # "Board" inside the application directory.\r
 # Target board (see library "Board Types" documentation, NONE for projects not requiring\r
 # LUFA board drivers). If USER is selected, put custom board drivers in a directory called\r
 # "Board" inside the application directory.\r
@@ -91,7 +95,7 @@ F_CLOCK = $(F_CPU)
 # Note that the bootloader size and start address given in AVRStudio is in words and not\r
 # bytes, and so will need to be doubled to obtain the byte address needed by AVR-GCC.\r
 FLASH_SIZE_KB        = 128\r
 # Note that the bootloader size and start address given in AVRStudio is in words and not\r
 # bytes, and so will need to be doubled to obtain the byte address needed by AVR-GCC.\r
 FLASH_SIZE_KB        = 128\r
-BOOT_SECTION_SIZE_KB = 2\r
+BOOT_SECTION_SIZE_KB = 4\r
 BOOT_START           = 0x$(shell echo "obase=16; ($(FLASH_SIZE_KB) - $(BOOT_SECTION_SIZE_KB)) * 1024" | bc)\r
 \r
 \r
 BOOT_START           = 0x$(shell echo "obase=16; ($(FLASH_SIZE_KB) - $(BOOT_SECTION_SIZE_KB)) * 1024" | bc)\r
 \r
 \r
@@ -126,11 +130,6 @@ LUFA_OPTS += -D NO_DEVICE_SELF_POWER
 LUFA_OPTS += -D NO_DEVICE_REMOTE_WAKEUP\r
 LUFA_OPTS += -D NO_SOF_EVENTS\r
 \r
 LUFA_OPTS += -D NO_DEVICE_REMOTE_WAKEUP\r
 LUFA_OPTS += -D NO_SOF_EVENTS\r
 \r
-#LUFA_OPTS += -D NO_BLOCK_SUPPORT\r
-#LUFA_OPTS += -D NO_EEPROM_BYTE_SUPPORT\r
-#LUFA_OPTS += -D NO_FLASH_BYTE_SUPPORT\r
-#LUFA_OPTS += -D NO_LOCK_BYTE_WRITE_SUPPORT\r
-\r
 \r
 # Create the LUFA source path variables by including the LUFA root makefile\r
 include $(LUFA_PATH)/LUFA/makefile\r
 \r
 # Create the LUFA source path variables by including the LUFA root makefile\r
 include $(LUFA_PATH)/LUFA/makefile\r
@@ -187,7 +186,7 @@ CSTANDARD = -std=c99
 # Place -D or -U options here for C sources\r
 CDEFS  = -DF_CPU=$(F_CPU)UL\r
 CDEFS += -DF_CLOCK=$(F_CLOCK)UL\r
 # Place -D or -U options here for C sources\r
 CDEFS  = -DF_CPU=$(F_CPU)UL\r
 CDEFS += -DF_CLOCK=$(F_CLOCK)UL\r
-CDEFS += -DBOARD=BOARD_$(BOARD)\r
+CDEFS += -DBOARD=BOARD_$(BOARD) -DARCH=ARCH_$(ARCH)\r
 CDEFS += -DBOOT_START_ADDR=$(BOOT_START)UL\r
 CDEFS += $(LUFA_OPTS)\r
 \r
 CDEFS += -DBOOT_START_ADDR=$(BOOT_START)UL\r
 CDEFS += $(LUFA_OPTS)\r
 \r
@@ -199,6 +198,7 @@ ADEFS += -DBOARD=BOARD_$(BOARD)
 ADEFS += -DBOOT_START_ADDR=$(BOOT_START)UL\r
 ADEFS += $(LUFA_OPTS)\r
 \r
 ADEFS += -DBOOT_START_ADDR=$(BOOT_START)UL\r
 ADEFS += $(LUFA_OPTS)\r
 \r
+\r
 # Place -D or -U options here for C++ sources\r
 CPPDEFS  = -DF_CPU=$(F_CPU)UL\r
 CPPDEFS += -DF_CLOCK=$(F_CLOCK)UL\r
 # Place -D or -U options here for C++ sources\r
 CPPDEFS  = -DF_CPU=$(F_CPU)UL\r
 CPPDEFS += -DF_CLOCK=$(F_CLOCK)UL\r