duino/Makefile in subduino-0.1.0 vs duino/Makefile in subduino-0.2.0

- old
+ new

@@ -1,65 +1,34 @@ -######################################################################## # -# Arduino command line tools Makefile -# System part (i.e. project independent) # +# duino Arduino command line tools Makefile +# +# # Copyright (C) 2010 Martin Oldfield <m@mjo.tc>, based on work that is # Copyright Nicholas Zambetti, David A. Mellis & Hernando Barragan -# -# This file is free software; you can redistribute it and/or modify it -# under the terms of the GNU Lesser General Public License as -# published by the Free Software Foundation; either version 2.1 of the -# License, or (at your option) any later version. # -# Adapted from Arduino 0011 Makefile by M J Oldfield # -# Original Arduino adaptation by mellis, eighthave, oli.keller +# See footer for copyright/changelog.... +# + # -# Version 0.1 17.ii.2009 M J Oldfield +# CONFIGURATION # -# 0.2 22.ii.2009 M J Oldfield -# - fixes so that the Makefile actually works! -# - support for uploading via ISP -# - orthogonal choices of using the Arduino for -# tools, libraries and uploading -# -# 0.3 21.v.2010 M J Oldfield -# - added proper license statement -# - added code from Philip Hands to reset -# Arduino prior to upload -# -# 0.4 25.v.2010 M J Oldfield -# - tweaked reset target on Philip Hands' advice -# -######################################################################## -# -# STANDARD ARDUINO WORKFLOW -# -# Given a normal sketch directory, all you need to do is to create -# a small Makefile which defines a few things, and then includes this one. -# -# For example: -# +TARGET = duino ARDUINO_DIR = /usr/share/arduino -# -TARGET = DUINO ARDUINO_LIBS = Messenger MCU = atmega328p F_CPU = 16000000 -ARDUINO_PORT = /dev/ttyUSB* #cu.usb* +ARDUINO_PORT = /dev/ttyUSB* # Linux AVR_TOOLS_PATH = /usr/bin AVRDUDE_CONF = /usr/share/arduino/hardware/tools/avrdude.conf # INC_DIRS = ./vendor/Messenger -# -# include /usr/local/share/Arduino.mk -# # Hopefully these will be self-explanatory but in case they're not: # # ARDUINO_DIR - Where the Arduino software has been unpacked # TARGET - The basename used for the final files. Canonically # this would match the .pde file, but it's not needed @@ -68,10 +37,18 @@ # these are in $(ARDUINO_DIR)/hardware/libraries # MCU,F_CPU - The target processor description # ARDUINO_PORT - The port where the Arduino can be found (only needed # when uploading # +# ARDUINO WITH OTHER TOOLS +# +# If the tools aren't in the Arduino distribution, then you need to +# specify their location: +# +# AVR_TOOLS_PATH = /usr/bin +# AVRDUDE_CONF = /etc/avrdude/avrdude.conf + # Once this file has been created the typical workflow is just # # $ make upload # # All of the object files are created in the build-cli subdirectory @@ -88,20 +65,10 @@ # make reset - reset the Arduino by tickling DTR on the serial port # make raw_upload - upload without first resetting # ######################################################################## # -# ARDUINO WITH OTHER TOOLS -# -# If the tools aren't in the Arduino distribution, then you need to -# specify their location: -# -# AVR_TOOLS_PATH = /usr/bin -# AVRDUDE_CONF = /etc/avrdude/avrdude.conf -# -######################################################################## -# # ARDUINO WITH ISP # # You need to specify some details of your ISP programmer and might # also need to specify the fuse values: # @@ -397,5 +364,41 @@ cat $(DEPS) > $(DEP_FILE) .PHONY: all clean depends upload raw_upload reset include $(DEP_FILE) + +# +# This makefile is from: +# http://mjo.tc/atelier/2009/02/arduino-cli.html +# +# With some help: +# +# http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1265576847 +# http://johanneshoff.com/arduino-command-line/Makefile +# +# This file is free software; you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as +# published by the Free Software Foundation; either version 2.1 of the +# License, or (at your option) any later version. +# +# Adapted from Arduino 0011 Makefile by M J Oldfield +# +# Original Arduino adaptation by mellis, eighthave, oli.keller +# +# Version 0.1 17.ii.2009 M J Oldfield +# +# 0.2 22.ii.2009 M J Oldfield +# - fixes so that the Makefile actually works! +# - support for uploading via ISP +# - orthogonal choices of using the Arduino for +# tools, libraries and uploading +# +# 0.3 21.v.2010 M J Oldfield +# - added proper license statement +# - added code from Philip Hands to reset +# Arduino prior to upload +# +# 0.4 25.v.2010 M J Oldfield +# - tweaked reset target on Philip Hands' advice +# +########################################################################