2 * Copyright (c) 2006, Technical University of Munich
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright
11 * notice, this list of conditions and the following disclaimer in the
12 * documentation and/or other materials provided with the distribution.
13 * 3. Neither the name of the Institute nor the names of its contributors
14 * may be used to endorse or promote products derived from this software
15 * without specific prior written permission.
17 * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
18 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20 * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
21 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29 * This file is part of the Contiki operating system.
36 * Configuration for sample STK 501 Contiki kernel
39 * Simon Barner <barner@in.tum.de
42 #ifndef __CONTIKI_CONF_H__
43 #define __CONTIKI_CONF_H__
47 typedef int32_t s32_t
;
53 #define PLATFORM PLATFORM_AVR
55 /* Clock ticks per second */
56 #define CLOCK_CONF_SECOND 125
58 /* COM port to be used for SLIP connection */
59 #define SLIP_PORT RS232_PORT_0
61 /* Pre-allocated memory for loadable modules heap space (in bytes)*/
62 #define MMEM_CONF_SIZE 256
64 /* Use the following address for code received via the codeprop
67 #define EEPROMFS_ADDR_CODEPROP 0x8000
72 #define RIMEADDR_CONF_SIZE 8
73 //#define PACKETBUF_CONF_HDR_SIZE 0 //undefine when using the barebones driver
75 /* 0 for IPv6, or 1 for HC1, 2 for HC01 */
76 #define SICSLOWPAN_CONF_COMPRESSION_IPV6 0
77 #define SICSLOWPAN_CONF_COMPRESSION_HC1 1
78 #define SICSLOWPAN_CONF_COMPRESSION_HC01 2
80 #define SICSLOWPAN_CONF_COMPRESSION SICSLOWPAN_CONF_COMPRESSION_HC01
81 #define SICSLOWPAN_CONF_MAX_ADDR_CONTEXTS 2
82 #define SICSLOWPAN_CONF_FRAG 1 //set zero for sky equivalence with barebones driver
84 /* Below will prevent fragmentation of TCP packets, undef for faster page loads, simpler wireshark captures */
85 //#define UIP_CONF_TCP_MSS 48
87 /* Fragmentation uses queuebuf.c to save packets */
88 #define QUEUEBUF_CONF_NUM 1
89 #define QUEUEBUF_CONF_REF_NUM 1
91 /* Logging adds 200 bytes to program size */
92 #define LOG_CONF_ENABLED 1
95 #define SICSLOWPAN_CONF_CONVENTIONAL_MAC 1 //for barebones driver
96 //#define SICSLOWPAN_CONF_FRAG 0 //for sky equivalence with barebones driver
97 //#define UIP_CONF_BUFFER_SIZE 256 //for sky equivalence with barebones driver
98 //#define UIP_CONF_ROUTER 1
99 #define UIP_CONF_ROUTER 0
102 #define SICSLOWPAN_CONF_MAXAGE 5
104 #define UIP_CONF_LL_802154 1
105 #define UIP_CONF_LLH_LEN 0
107 #define UIP_CONF_MAX_CONNECTIONS 2
108 #define UIP_CONF_MAX_LISTENPORTS 2
109 #define UIP_CONF_UDP_CONNS 2
111 #define UIP_CONF_IP_FORWARD 0
112 #define UIP_CONF_FWCACHE_SIZE 0
114 #define UIP_CONF_IPV6 1
115 #define UIP_CONF_IPV6_CHECKS 1
116 #define UIP_CONF_IPV6_QUEUE_PKT 1
117 #define UIP_CONF_IPV6_REASSEMBLY 0
118 #define UIP_CONF_NETIF_MAX_ADDRESSES 3
119 #define UIP_CONF_ND6_MAX_PREFIXES 3
120 #define UIP_CONF_ND6_MAX_NEIGHBORS 4
121 #define UIP_CONF_ND6_MAX_DEFROUTERS 2
122 #define UIP_CONF_ICMP6 1
124 #define UIP_CONF_UDP 1
125 #define UIP_CONF_UDP_CHECKSUMS 1
127 #define UIP_CONF_TCP 1
128 #define UIP_CONF_TCP_SPLIT 1
131 typedef unsigned short clock_time_t
;
132 typedef unsigned char u8_t
;
133 typedef unsigned short u16_t
;
134 typedef unsigned long u32_t
;
135 typedef unsigned short uip_stats_t
;
136 typedef unsigned long off_t
;
138 void clock_delay(unsigned int us2
);
139 void clock_wait(int ms10
);
140 void clock_set_seconds(unsigned long s
);
141 unsigned long clock_seconds(void);
143 #endif /* __CONTIKI_CONF_H__ */