osd-contiki/platform/osd-merkur-128/Makefile.osd-merkur-128
Ralf Schlatterbeck 04bbba6c12 Multi-platform support, osd-merkur-{128,256}
Rename guhRF platform to osd-merkur-256, previous osd-merkur platform is
now osd-merkur-128. Also check that everything is consistent.
Add both platforms to the regression tests.
Move redundant files in platform dev directory of both platforms to
cpu/avr/dev. Note that this probably needs some rework. Already
discovered some inconsistency in io definitions of both devices in the
avr/io.h includes. Added a workaround in the obvious cases.
The platform makefiles now set correct parameters for bootloader and for
reading mac-address from flash memory.
Factor the flash programming into cpu/avr and platform/osd-merkur* and
rework *all* osd example makefiles to use the new settings. Also update
all the flash.sh and run.sh to use the new settings.
The suli ledstrip modules (and osd example) have also been removed.
2016-04-22 17:59:40 +02:00

92 lines
2.9 KiB
Makefile

CONTIKI_TARGET_DIRS = . dev apps net loader dev/arduino
CONTIKI_CORE=contiki-main
CONTIKI_TARGET_MAIN = ${CONTIKI_CORE}.o
CONTIKI_TARGET_SOURCEFILES += contiki-main.c params.c node-id.c
#Needed for slip
CONTIKI_TARGET_SOURCEFILES += led.c sensors.c slip_uart0.c slip.c leds-arch.c
CONTIKI_TARGET_SOURCEFILES += temperature-sensor.c adc.c
#Needed for Button
CONTIKI_TARGET_SOURCEFILES += button-sensor.c
# i2c Master
#CONTIKI_TARGET_SOURCEFILES += i2c.c
#Needed for DHT11 humidity sensor
CONTIKI_TARGET_SOURCEFILES += dht11.c
#Needed for DS18S20 temperature sensor
CONTIKI_TARGET_SOURCEFILES += ds1820.c
#Needed for Battery test
CONTIKI_TARGET_SOURCEFILES += battery-sensor.c batmon.c
#Needed for PIR
CONTIKI_TARGET_SOURCEFILES += pir-sensor.c
#Needed for OPTRIAC
CONTIKI_TARGET_SOURCEFILES += optriac-sensor.c
#Needed for SERVO
CONTIKI_TARGET_SOURCEFILES += servo.c servo-sensor.c
#Needed for Timer4 Servo
#CONTIKI_TARGET_SOURCEFILES += t4-servo.c t4-servo-sensor.c
#Needed for Relay 1 to 4
CONTIKI_TARGET_SOURCEFILES += relay.c relay-sensor.c
# Arduino
CONTIKI_TARGET_SOURCEFILES += wiring_digital.c
CONTIKI_TARGET_SOURCEFILES += new.cpp twi.c Wire.cpp WMath.cpp
CONTIKI_TARGET_SOURCEFILES += Print.cpp Stream.cpp WString.cpp
# guh Source Files
# Smart Grid Ready Interface
CONTIKI_TARGET_SOURCEFILES += sg-ready.c
CONTIKIAVR=$(CONTIKI)/cpu/avr
CONTIKIBOARD=.
BOOTLOADER_START = 0x1F000
CONTIKI_PLAT_DEFS = -DF_CPU=16000000UL -DAUTO_CRC_PADDING=2 -DPLAT_TIMER=5
MCU=atmega128rfa1
#AVRDUDE_PROGRAMMER=jtag2
AVRDUDE_PROGRAMMER=arduino
# For usb devices, you may either use PORT=usb, or (e.g. if you have
# more than one programmer connected) you can use the following trick to
# find out the serial number:
#
# The example is for an JTAGICE mkII used to program an ATmega128:
# avrdude -v -P usb:xxxx -c jtag2 -p atmega128
# AVRDUDE_PORT=usb:00B000000D79
# For serial devices with bootloader we also use the AVRDUDE_PORT setting:
AVRDUDE_PORT=/dev/ttyUSB0
# Only needed for serial devices, use empty setting for other
# programmers
AVRDUDE_BAUD_OPTION=-b 57600
# Additional avrdude options
# First some flash options:
# Verify off is -V
# Erase is -e
# No-Erase (needed by some stk500 variants) is -D
AVRDUDE_FLASH_OPTIONS=-e
AVRDUDE_OPTIONS=$(AVRDUDE_BAUD_OPTION) $(AVRDUDE_FLASH_OPTIONS)
AVRDUDE_MCU=m128rfa1
#debug
# CFLAGS += -save-temps
# Bootloader bonsai
# LDFLAGS += -save-temps
# For the old bonsai bootloader compiled with squeeze gcc-avr we
# directly used the address of the bootloader:
#BOOTLOADER_GET_MAC=0x0001f3a0
# For newer bonsai we have a jump table at the end of the bootloader
# section:
BOOTLOADER_GET_MAC=0x0001ff80
LDFLAGS += -Wl,--defsym,bootloader_get_mac=$(BOOTLOADER_GET_MAC)
include $(CONTIKIAVR)/Makefile.avr
include $(CONTIKIAVR)/radio/Makefile.radio
MODULES += core/net/mac core/net core/net/mac/sicslowmac \
core/net/mac/contikimac core/net/llsec \
# core/net/ipv6 core/net/ipv4 core/net/ip \
# core/net/rime \
# core/net/rpl \