]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - support/make/iris.target
added channel selection support to makefiles for micaz and iris
[tinyos-2.x.git] / support / make / iris.target
index ce4e7d5158ebef6fa2d426c84c0f8063124679d1..c0149bcdc7369cf2018078073167cc8648f3f1af 100644 (file)
@@ -4,6 +4,12 @@
 PLATFORM = iris
 SENSORBOARD ?= micasb
 PROGRAMMER ?= avrdude
+
+AVRGCC_SUPPORTS_ATM1281 = $(shell avr-gcc --target-help 2>&1 | grep -c atmega1281)
+ifneq ($(AVRGCC_SUPPORTS_ATM1281),1)
+  $(error Found avr-gcc with no ATMega1281 support. For details on upgrading your toolchain, please see "http://www.isis.vanderbilt.edu/projects/NEST/tinyos-2.x-iris/doc/html/install-tinyos-iris.html")
+endif
+
 ifeq ($(PROGRAMMER),avrdude)
   PROGRAMMER_PART ?= -pm1281 -U efuse:w:0xff:m
 endif
@@ -14,6 +20,11 @@ endif
 
 AVR_FUSE_H ?= 0xd9
 AVR_FUSE_L ?= 0xff
+
+ifdef RF230_CHANNEL
+PFLAGS += -DRF230_DEF_CHANNEL=$(RF230_CHANNEL)
+endif
+
 $(call TOSMake_include_platform,avr)
 
 iris: $(BUILD_DEPS)