# define the cpu used by the Mega Xplained board export CPU = atmega1284p # Found by checking fuse settings (2048 words so 4KB) # https://www.microchip.com/DevelopmentTools/ProductDetails/atmega1284p-xpld BOOTLOADER_SIZE ?= 4K ROM_RESERVED ?= $(BOOTLOADER_SIZE) # configure the terminal program PORT_LINUX ?= /dev/ttyACM0 PORT_DARWIN ?= $(firstword $(sort $(wildcard /dev/tty.usbmodem*))) BAUD ?= 9600 include $(RIOTMAKE)/tools/serial.inc.mk # PROGRAMMER defaults to the external flasher Bus Pirate ISP using avrdude. PROGRAMMER ?= buspirate # set serial port for avrdude with buspirate ifeq ($(OS),Linux) AVRDUDE_PORT ?= /dev/ttyUSB0 else ifeq ($(OS),Darwin) AVRDUDE_PORT ?= $(firstword $(sort $(wildcard /dev/tty.usbserial*))) endif # avoid error if mcu signature doesn't match FFLAGS_EXTRA += -F include $(RIOTMAKE)/tools/avrdude.inc.mk include $(RIOTBOARD)/common/atmega/Makefile.include