diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..f720bb9 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "Arduino-Makefile"] + path = arduino-makefile + url = https://github.com/sudar/Arduino-Makefile diff --git a/arduino-makefile b/arduino-makefile new file mode 160000 index 0000000..6f786a9 --- /dev/null +++ b/arduino-makefile @@ -0,0 +1 @@ +Subproject commit 6f786a96b0acfb0c9b2d2f4e39911d2803088729 diff --git a/src/makefile b/src/makefile new file mode 100644 index 0000000..5c2b1c7 --- /dev/null +++ b/src/makefile @@ -0,0 +1,19 @@ +ARCHITECTURE = avr +BOARD_TAG = nano +BOARD_SUB = atmega328old +ARDUINO_LIBS = arduino-mcp2515 + +ARDUINO_DEV ?= /dev/ttyUSB0 + +ARDUINO_VERSION ?= 1.5 +ifeq ($(origin ARDUINO_SKETCHBOOK), undefined) +ARDUINO_SKETCHBOOK := $(shell sed -n 's/^sketchbook.path=//p' ~/.arduino$(subst .,,$(ARDUINO_VERSION))/preferences.txt) +endif +ifeq ($(origin BOARDS_TXT), undefined) +BOARDS_TXT := $(shell locate '*/arduino/*/boards.txt') # ¯\_(ツ)_/¯ +endif + +ARDMK_DIR ?= ../arduino-makefile +AVR_TOOLS_DIR ?= /usr + +include $(ARDMK_DIR)/Arduino.mk