Merge pull request #329 from g-oikonomou/8051-updates

Various Updates for 8051-based Platforms
This commit is contained in:
Nicolas Tsiftes 2013-08-09 10:19:34 -07:00
commit 6afb978bc8
24 changed files with 109 additions and 77 deletions

View File

@ -2,7 +2,7 @@
CC = sdcc
LD = sdcc
AS = sdcc
AR = sdcclib
AR = sdar
OBJCOPY = objcopy
STRIP = strip
PACKIHX = packihx
@ -12,13 +12,16 @@ SEGMENT_RULES = $(OBJECTDIR)/segment.rules
CFLAGS += --model-$(MEMORY_MODEL) --stack-auto -DSDCC_CC2430 --std-c99
CFLAGS += --fomit-frame-pointer
### Disable warning 110 (EVELYN the modified dog) and 126 (unreachable code)
CFLAGS += --disable-warning 110 --disable-warning 126
LDFLAGS += --model-$(MEMORY_MODEL) --stack-auto -DSDCC_CC2430 --out-fmt-ihx
LDFLAGS += --xram-loc 0xE000 --xram-size 0x1F00
LDFLAGS += --code-loc $(START_ADDR) --code-size $(CODE_SIZE)
ASFLAGS += -plosgff
AROPTS = -a
AROPTS = -rc
### Our object files are .rel, so we can't use the default finalize dependency
### generation. Override here.
@ -126,16 +129,10 @@ CUSTOM_RULE_C_TO_OBJECTDIR_O=1
CUSTOM_RULE_ALLOBJS_TO_TARGETLIB=1
$(OBJECTDIR)/%.rel: %.c $(SEGMENT_RULES) | $(OBJECTDIR)
$(CC) $(call c_seg,$<,$@) $(CFLAGS) -c $< -o $@ -Wp,-MMD,$(@:.rel=.d),-MQ,$@
$(TRACE_CC)
$(Q)$(CC) $(call c_seg,$<,$@) $(CFLAGS) -c $< -o $@ -Wp,-MMD,$(@:.rel=.d),-MQ,$@
@$(FINALIZE_SDCC_DEPENDENCY)
$(OBJECTDIR)/%.rel: %.cS | $(OBJECTDIR)
cp $< $(OBJECTDIR)/$*.c
$(CC) $(CFLAGS) -E $(OBJECTDIR)/$*.c > $(OBJECTDIR)/tmp
perl -pe "s/^#(.*)/;$$1/" $(OBJECTDIR)/tmp > $(OBJECTDIR)/$*.S
$(AS) $(ASFLAGS) -o $@ $(OBJECTDIR)/$*.S
rm -f $(OBJECTDIR)/tmp
contiki-$(TARGET).lib: $(CONTIKI_OBJECTFILES) $(PROJECT_OBJECTFILES) \
$(CONTIKI_ASMOBJECTFILES) $(CONTIKI_CASMOBJECTFILES)
rm -f $@
@ -146,7 +143,8 @@ contiki-$(TARGET).lib: $(CONTIKI_OBJECTFILES) $(PROJECT_OBJECTFILES) \
# build app/example local object files. We need a separate rule so that we can
# pass -DAUTOSTART_ENABLE for those files only
$(OBJECTDIR)/%.app.rel: %.c $(SEGMENT_RULES) | $(OBJECTDIR)
$(CC) $(call c_seg,$<,$@) -DAUTOSTART_ENABLE $(CFLAGS) -c $< -o $@
$(TRACE_CC)
$(Q)$(CC) $(call c_seg,$<,$@) -DAUTOSTART_ENABLE $(CFLAGS) -c $< -o $@
# .ihx is the sdcc binary output file
%.ihx: $(OBJECTDIR)/%.app.rel $(CONTIKI_TARGET_MAIN) contiki-$(TARGET).lib
@ -154,14 +152,16 @@ $(OBJECTDIR)/%.app.rel: %.c $(SEGMENT_RULES) | $(OBJECTDIR)
ifeq ($(HAVE_BANKING),1)
@echo "\nFirst Link"
@echo "==============="
$(CC) $(LDFLAGS) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib > /dev/null
$(TRACE_LD)
$(Q)$(LD) $(LDFLAGS) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib
@echo "\nBank Allocation"
@echo "==============="
python $(BANK_ALLOC) $(basename $(@F)) $(SEGMENT_RULES) $(OFFSET_FIRMWARE)
@echo "\nFinal Link"
@echo "==============="
endif
$(CC) $(LDFLAGS) $(LD_POST_FLAGS) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib > /dev/null
$(TRACE_LD)
$(Q)$(LD) $(LDFLAGS) $(LD_POST_FLAGS) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib
# Pack the hex file for programmers which dislike SDCC output hex format
%.hex: %.ihx

View File

@ -2,7 +2,7 @@
CC = sdcc
LD = sdcc
AS = sdcc
AR = sdcclib
AR = sdar
OBJCOPY = objcopy
STRIP = strip
@ -18,13 +18,16 @@ CFLAGS += --model-$(MEMORY_MODEL) --stack-auto --std-c99
CFLAGS += -DCC2530_LAST_FLASH_BANK=$(HIGH_FLASH_BANK)
CFLAGS += --fomit-frame-pointer
### Disable warning 110 (EVELYN the modified dog) and 126 (unreachable code)
CFLAGS += --disable-warning 110 --disable-warning 126
LDFLAGS += --model-$(MEMORY_MODEL) --stack-auto --out-fmt-ihx
LDFLAGS += --xram-loc 0x0000 --xram-size 0x1F00
LDFLAGS += --code-loc $(START_ADDR) --code-size $(CODE_SIZE)
ASFLAGS += -plosgff
AROPTS = -a
AROPTS = -rc
### Our object files are .rel, so we can't use the default finalize dependency
### generation. Override here.
@ -147,16 +150,10 @@ CUSTOM_RULE_C_TO_OBJECTDIR_O=1
CUSTOM_RULE_ALLOBJS_TO_TARGETLIB=1
$(OBJECTDIR)/%.rel: %.c $(SEGMENT_RULES) | $(OBJECTDIR)
$(CC) $(call c_seg,$<,$@) $(CFLAGS) -c $< -o $@ -Wp,-MMD,$(@:.rel=.d),-MQ,$@
$(TRACE_CC)
$(Q)$(CC) $(call c_seg,$<,$@) $(CFLAGS) -c $< -o $@ -Wp,-MMD,$(@:.rel=.d),-MQ,$@
@$(FINALIZE_SDCC_DEPENDENCY)
$(OBJECTDIR)/%.rel: %.cS | $(OBJECTDIR)
cp $< $(OBJECTDIR)/$*.c
$(CC) $(CFLAGS) -E $(OBJECTDIR)/$*.c > $(OBJECTDIR)/tmp
perl -pe "s/^#(.*)/;$$1/" $(OBJECTDIR)/tmp > $(OBJECTDIR)/$*.S
$(AS) $(ASFLAGS) -o $@ $(OBJECTDIR)/$*.S
rm -f $(OBJECTDIR)/tmp
contiki-$(TARGET).lib: $(CONTIKI_OBJECTFILES) $(PROJECT_OBJECTFILES) \
$(CONTIKI_ASMOBJECTFILES) $(CONTIKI_CASMOBJECTFILES)
rm -f $@
@ -167,7 +164,8 @@ contiki-$(TARGET).lib: $(CONTIKI_OBJECTFILES) $(PROJECT_OBJECTFILES) \
# build app/example local object files. We need a separate rule so that we can
# pass -DAUTOSTART_ENABLE for those files only
$(OBJECTDIR)/%.app.rel: %.c $(SEGMENT_RULES) | $(OBJECTDIR)
$(CC) $(call c_seg,$<,$@) -DAUTOSTART_ENABLE $(CFLAGS) -c $< -o $@
$(TRACE_CC)
$(Q)$(CC) $(call c_seg,$<,$@) -DAUTOSTART_ENABLE $(CFLAGS) -c $< -o $@
# .ihx is the sdcc binary output file
ifeq ($(HAVE_BANKING),1)
@ -175,7 +173,8 @@ ifeq ($(HAVE_BANKING),1)
%.ihx: $(OBJECTDIR)/%.app.rel $(CONTIKI_TARGET_MAIN) contiki-$(TARGET).lib
@echo "\nFirst Link"
@echo "==============="
$(CC) $(LDFLAGS) $(LD_PRE_FLAGS) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib > /dev/null
$(TRACE_LD)
$(Q)$(CC) $(LDFLAGS) $(LD_PRE_FLAGS) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib
%.flags: %.ihx
### Allocate modules to banks and relocate object files
@ -187,7 +186,8 @@ ifeq ($(HAVE_BANKING),1)
### Link again with new bank allocations
@echo "\nFinal Link"
@echo "==============="
$(CC) $(LDFLAGS) $(shell cat $<) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib > /dev/null
$(TRACE_LD)
$(Q)$(LD) $(LDFLAGS) $(shell cat $<) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib
%.hex: %.banked-hex
### Post-process the hex file for programmers which dislike SDCC output hex format
@ -209,7 +209,8 @@ ifeq ($(HAVE_BANKING),1)
else
### Build non-banked firmware
%.ihx: $(OBJECTDIR)/%.app.rel $(CONTIKI_TARGET_MAIN) contiki-$(TARGET).lib
$(CC) $(LDFLAGS) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib > /dev/null
$(TRACE_LD)
$(Q)$(LD) $(LDFLAGS) -o $@ $(CONTIKI_TARGET_MAIN) $(OBJECTDIR)/$*.app.rel -llibsdcc.lib -lcontiki-$(TARGET).lib
%.hex: %.ihx
$(PACKIHX) $< > $@

View File

@ -55,7 +55,7 @@ uart1_init()
#endif
U1CSR = UCSR_MODE; /* UART mode */
U1UCR = 0x80; /* Flush */
U1UCR |= 0x80; /* Flush */
UART1_RX_INT(1);
U0DBUF = 0;

View File

@ -14,8 +14,8 @@ const struct usb_st_device_descriptor device_descriptor =
0,
0,
CTRL_EP_SIZE,
0x0617, /* EPFL usb ID */
0x000B, /* Don't mess with it please */
CDC_ACM_CONF_VID,
CDC_ACM_CONF_PID,
0x0000,
1,
2,

View File

@ -1,6 +1,3 @@
# To build for the cc2531 USB stick:
DEFINES+=MODEL_CC2531=1,
DEFINES+=PROJECT_CONF_H=\"project-conf.h\"
# We need uIPv6, therefore we also need banking

View File

@ -51,4 +51,9 @@
* Has no effect when building for the SmartRF. */
#define USB_SERIAL_CONF_BUFFERED 1
#define UIP_FALLBACK_INTERFACE slip_interface
/* Change to 0 to build for the SmartRF + cc2530 EM */
#define MODELS_CONF_CC2531_USB_STICK 1
#endif /* PROJECT_CONF_H_ */

View File

@ -1,6 +1,6 @@
CONTIKI_PROJECT = cc2531-usb-demo
DEFINES+=MODEL_CC2531=1
DEFINES+=MODELS_CONF_CC2531_USB_STICK=1
all: $(CONTIKI_PROJECT)

View File

@ -1,5 +1,4 @@
DEFINES+=PROJECT_CONF_H
DEFINES+=MODEL_CC2531=1
PROJECT_SOURCEFILES += stub-rdc.c
CONTIKI_PROJECT = sniffer

View File

@ -47,6 +47,9 @@
#define LPM_CONF_MODE 0
#define UART0_CONF_HIGH_SPEED 1
/* Change to 0 to build for the SmartRF + cc2530 EM */
#define MODELS_CONF_CC2531_USB_STICK 1
/* Used by cc2531 USB dongle builds, has no effect on SmartRF builds */
#define USB_SERIAL_CONF_BUFFERED 1

View File

@ -46,5 +46,6 @@
#define VIZTOOL_MAX_PAYLOAD_LEN 120
#define SLIP_ARCH_CONF_ENABLE 1
#define LPM_CONF_MODE 0
#define UIP_FALLBACK_INTERFACE slip_interface
#endif /* PROJECT_CONF_H_ */

View File

@ -46,6 +46,7 @@
#define BUTTON_SENSOR_CONF_ON 1
#define ADC_SENSOR_CONF_ON 1
#define LPM_CONF_MODE 1
#define LPM_CONF_MODE 0
#define VIZTOOL_CONF_ON 0
#endif /* PROJECT_CONF_H_ */

View File

@ -46,5 +46,6 @@
#define BUTTON_SENSOR_CONF_ON 1
#define RIMESTATS_CONF_ENABLED 1
#define VIZTOOL_CONF_ON 0
#endif /* PROJECT_CONF_H_ */

View File

@ -58,7 +58,7 @@ static uint16_t len;
#define SERVER_REPLY 1
/* Should we act as RPL root? */
#define SERVER_RPL_ROOT 1
#define SERVER_RPL_ROOT 0
#if SERVER_RPL_ROOT
static uip_ipaddr_t ipaddr;

View File

@ -43,12 +43,6 @@ FORCE:
@egrep '(^BANK[1-9][^=])' $(<:.hex=.map) | uniq | sort
@egrep -A 5 'Other memory' $(<:.hex=.mem)
%.upload: %.hex
$(PROG) -P $<
sensinode.serialdump:
$(SERIALDUMP)
### Define the CPU directory
CONTIKI_CPU=$(CONTIKI)/cpu/cc253x
include $(CONTIKI_CPU)/Makefile.cc253x

View File

@ -10,6 +10,14 @@
#include "project-conf.h"
#endif /* PROJECT_CONF_H */
/*
* Build for SmartRF05EB+CC2530EM by default.
* This define needs to have its final value before inclusion of models.h
*/
#ifndef MODELS_CONF_CC2531_USB_STICK
#define MODELS_CONF_CC2531_USB_STICK 0
#endif
#include "models.h"
/*
@ -62,6 +70,12 @@
#define USB_SERIAL_CONF_BUFFERED 1
#endif
#define SLIP_RADIO_CONF_NO_PUTCHAR 1
#if defined (UIP_FALLBACK_INTERFACE) || defined (CMD_CONF_OUTPUT)
#define SLIP_ARCH_CONF_ENABLE 1
#endif
/* Are we a SLIP bridge? */
#if SLIP_ARCH_CONF_ENABLE
/* Make sure the UART is enabled, with interrupts */
@ -69,7 +83,6 @@
#undef UART0_CONF_WITH_INPUT
#define UART0_CONF_ENABLE 1
#define UART0_CONF_WITH_INPUT 1
#define UIP_FALLBACK_INTERFACE slip_interface
#endif
/* Output all captured frames over the UART in hexdump format */
@ -151,11 +164,13 @@
#endif /* UIP_CONF_IPV6 */
/* Network Stack */
#ifndef NETSTACK_CONF_NETWORK
#if UIP_CONF_IPV6
#define NETSTACK_CONF_NETWORK sicslowpan_driver
#else
#define NETSTACK_CONF_NETWORK rime_driver
#endif
#endif /* UIP_CONF_IPV6 */
#endif /* NETSTACK_CONF_NETWORK */
#ifndef NETSTACK_CONF_MAC
#define NETSTACK_CONF_MAC csma_driver
@ -171,7 +186,10 @@
#define NETSTACK_CONF_RDC_CHANNEL_CHECK_RATE 8
#endif
#ifndef NETSTACK_CONF_FRAMER
#define NETSTACK_CONF_FRAMER framer_802154
#endif
#define NETSTACK_CONF_RADIO cc2530_rf_driver
/* RF Config */
@ -222,7 +240,9 @@
#endif
/* uIP */
#ifndef UIP_CONF_BUFFER_SIZE
#define UIP_CONF_BUFFER_SIZE 240
#endif
#define UIP_CONF_IPV6_QUEUE_PKT 0
#define UIP_CONF_IPV6_CHECKS 1
#define UIP_CONF_IPV6_REASSEMBLY 0
@ -242,7 +262,10 @@
}
#define MAC_CONF_CHANNEL_CHECK_RATE 8
#ifndef QUEUEBUF_CONF_NUM
#define QUEUEBUF_CONF_NUM 6
#endif
#else /* UIP_CONF_IPV6 */
/* Network setup for non-IPv6 (rime). */

View File

@ -63,7 +63,7 @@ configure_b1(int type, int value)
{
switch(type) {
case SENSORS_HW_INIT:
#if !MODEL_CC2531
#if !MODELS_CONF_CC2531_USB_STICK
P0INP |= 2; /* Tri-state */
#endif
BUTTON_IRQ_ON_PRESS(1);
@ -87,7 +87,7 @@ configure_b1(int type, int value)
/*---------------------------------------------------------------------------*/
/* Button 2 - cc2531 USb Dongle only */
/*---------------------------------------------------------------------------*/
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
static int
value_b2(int type)
{
@ -138,7 +138,7 @@ configure_b2(int type, int value)
#if CC_CONF_OPTIMIZE_STACK_SIZE
#pragma exclude bits
#endif
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
void
port_1_isr(void) __interrupt(P1INT_VECTOR)
{
@ -195,6 +195,6 @@ port_0_isr(void) __interrupt(P0INT_VECTOR)
#pragma restore
/*---------------------------------------------------------------------------*/
SENSORS_SENSOR(button_1_sensor, BUTTON_SENSOR, value_b1, configure_b1, status_b1);
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
SENSORS_SENSOR(button_2_sensor, BUTTON_SENSOR, value_b2, configure_b2, status_b2);
#endif

View File

@ -54,7 +54,7 @@
* B2: P1_3
*
*/
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
#define BUTTON1_PORT 1
#define BUTTON1_PIN 2
#define BUTTON2_PORT 1
@ -73,7 +73,7 @@ extern const struct sensors_sensor button_1_sensor;
extern const struct sensors_sensor button_2_sensor;
#if BUTTON_SENSOR_ON
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
/* USB Dongle */
/* Buttons: P1_2 & P1_3 - Port 1 ISR needed */
void port_1_isr(void) __interrupt(P1INT_VECTOR);
@ -82,12 +82,12 @@ void port_1_isr(void) __interrupt(P1INT_VECTOR);
button_2_sensor.configure(SENSORS_ACTIVE, 1); \
} while(0)
#else /* MODEL_CC2531 */
#else /* MODELS_CONF_CC2531_USB_STICK */
/* SmartRF */
/* Button 1: P0_1 - Port 0 ISR needed */
void port_0_isr(void) __interrupt(P0INT_VECTOR);
#define BUTTON_SENSOR_ACTIVATE() button_sensor.configure(SENSORS_ACTIVE, 1)
#endif /* MODEL_CC2531 */
#endif /* MODELS_CONF_CC2531_USB_STICK */
#else /* BUTTON_SENSOR_ON */
#define BUTTON_SENSOR_ACTIVATE()

View File

@ -48,7 +48,7 @@
#include "contiki.h"
/*---------------------------------------------------------------------------*/
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
#include "dev/usb-serial.h"
#define IO_ARCH_PREFIX usb_serial

View File

@ -44,7 +44,7 @@
void
leds_arch_init(void)
{
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
P1SEL &= ~LED1_MASK;
P1DIR |= LED1_MASK;
P0SEL &= ~LED2_MASK;
@ -58,7 +58,7 @@ leds_arch_init(void)
unsigned char
leds_arch_get(void)
{
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
return (unsigned char)(LED1_PIN | ((LED2_PIN ^ 0x01) << 1));
#else
return (unsigned char)(LED1_PIN | (LED2_PIN << 1) | (LED3_PIN << 2));
@ -69,7 +69,7 @@ void
leds_arch_set(unsigned char leds)
{
LED1_PIN = leds & 0x01;
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
LED2_PIN = ((leds & 0x02) >> 1) ^ 0x01;
#else
LED2_PIN = (leds & 0x02) >> 1;

View File

@ -47,7 +47,7 @@ const struct sensors_sensor *sensors[] = {
#endif
#if BUTTON_SENSOR_ON
&button_1_sensor,
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
&button_2_sensor,
#endif
#endif

View File

@ -68,22 +68,25 @@ static struct {
static const struct {
uint8_t size;
uint8_t type;
uint16_t string[10];
uint16_t string[17];
} string_manufacturer = {
sizeof(string_manufacturer),
3,
{ 'E', 'P', 'F', 'L', '-', 'L', 'S', 'R', 'O', '1' }
{
'T', 'e', 'x', 'a', 's', ' ',
'I', 'n', 's', 't', 'r', 'u', 'm', 'e', 'n', 't', 's'
}
};
static const struct {
uint8_t size;
uint8_t type;
uint16_t string[18];
uint16_t string[17];
} string_product = {
sizeof(string_product),
3, {
'C', 'C', '2', '5', '3', '1', ' ',
'D', 'e', 'v', 'e', 'l', '-', 'B', 'o', 'a', 'r', 'd'
'U', 'S', 'B', ' ', 'D', 'o', 'n', 'g', 'l', 'e'
}
};
/*---------------------------------------------------------------------------*/

View File

@ -64,7 +64,7 @@
* 1: P0_0 (Red)
* 2: P1_1 (Green - active: low)
*/
#if MODEL_CC2531
#if MODELS_CONF_CC2531_USB_STICK
#define MODEL_STRING "TI cc2531 USB Dongle\n"
#define USB_CONF_ENABLE 1
@ -81,6 +81,9 @@
#define USB_CONF_CLASS 1 /* CDC-ACM */
#endif
#define CDC_ACM_CONF_VID 0x0451 /* Vendor: TI */
#define CDC_ACM_CONF_PID 0x16A8 /* cc2531 CDC */
#undef LEDS_CONF_ALL
#define LEDS_CONF_ALL 3
#define LEDS_RED 1

View File

@ -53,7 +53,6 @@ ifeq ($(UIP_CONF_IPV6),1)
CONTIKI_TARGET_SOURCEFILES += disco.c
endif
CONTIKI_TARGET_SOURCEFILES += viztool.c
CONTIKI_SOURCEFILES += rpl-of0.c
endif
FORCE:

View File

@ -62,6 +62,12 @@
#define UART_ONE_CONF_HIGH_SPEED 0
#endif
#define SLIP_RADIO_CONF_NO_PUTCHAR 1
#if defined (UIP_FALLBACK_INTERFACE) || defined (CMD_CONF_OUTPUT)
#define SLIP_ARCH_CONF_ENABLE 1
#endif
/* Are we a SLIP bridge? */
#if SLIP_ARCH_CONF_ENABLE
/* Make sure UART1 is enabled, with interrupts */
@ -69,7 +75,6 @@
#undef UART_ONE_CONF_WITH_INPUT
#define UART_ONE_CONF_ENABLE 1
#define UART_ONE_CONF_WITH_INPUT 1
#define UIP_FALLBACK_INTERFACE slip_interface
#endif
/* Output all captured frames over the UART in hexdump format */
@ -153,11 +158,13 @@
#endif
/* Network Stack */
#ifndef NETSTACK_CONF_NETWORK
#if UIP_CONF_IPV6
#define NETSTACK_CONF_NETWORK sicslowpan_driver
#else
#define NETSTACK_CONF_NETWORK rime_driver
#endif
#endif /* UIP_CONF_IPV6 */
#endif /* NETSTACK_CONF_NETWORK */
#ifndef NETSTACK_CONF_MAC
#define NETSTACK_CONF_MAC csma_driver
@ -173,7 +180,10 @@
#define NETSTACK_CONF_RDC_CHANNEL_CHECK_RATE 8
#endif
#ifndef NETSTACK_CONF_FRAMER
#define NETSTACK_CONF_FRAMER framer_802154
#endif
#define NETSTACK_CONF_RADIO cc2430_rf_driver
/* RF Config */
@ -228,7 +238,9 @@
#endif
/* uIP */
#ifndef UIP_CONF_BUFFER_SIZE
#define UIP_CONF_BUFFER_SIZE 240
#endif
#define UIP_CONF_IPV6_QUEUE_PKT 0
#define UIP_CONF_IPV6_CHECKS 1
#define UIP_CONF_IPV6_REASSEMBLY 0
@ -241,7 +253,7 @@
#define SICSLOWPAN_CONF_MAXAGE 8
/* Define our IPv6 prefixes/contexts here */
#define SICSLOWPAN_CONF_MAX_ADDR_CONTEXTS 2
#define SICSLOWPAN_CONF_MAX_ADDR_CONTEXTS 1
#define SICSLOWPAN_CONF_ADDR_CONTEXT_0 { \
addr_contexts[0].prefix[0] = 0x20; \
addr_contexts[0].prefix[1] = 0x01; \
@ -252,16 +264,6 @@
addr_contexts[0].prefix[6] = 0x64; \
addr_contexts[0].prefix[7] = 0x53; \
}
#define SICSLOWPAN_CONF_ADDR_CONTEXT_1 { \
addr_contexts[1].prefix[0] = 0x20; \
addr_contexts[1].prefix[1] = 0x01; \
addr_contexts[1].prefix[2] = 0x06; \
addr_contexts[1].prefix[3] = 0x30; \
addr_contexts[1].prefix[4] = 0x03; \
addr_contexts[1].prefix[5] = 0x01; \
addr_contexts[1].prefix[6] = 0x11; \
addr_contexts[1].prefix[7] = 0x00; \
}
#define MAC_CONF_CHANNEL_CHECK_RATE 8
#ifndef QUEUEBUF_CONF_NUM