Contiki 3.x
contiki-conf.h
1 /*
2  * Copyright (c) 2015, SICS Swedish ICT.
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions
7  * are met:
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.
16  *
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
27  * SUCH DAMAGE.
28  *
29  * This file is part of the Contiki operating system.
30  *
31  */
32 
33 #ifndef CONTIKI_CONF_H_
34 #define CONTIKI_CONF_H_
35 
36 #ifdef PLATFORM_CONF_H
37 #include PLATFORM_CONF_H
38 #else
39 #include "platform-conf.h"
40 #endif /* PLATFORM_CONF_H */
41 
42 #ifndef CCM_STAR_CONF
43 #define CCM_STAR_CONF ccm_star_driver_jn516x
44 #endif /* CCM_STAR_CONF */
45 
46 #ifndef NETSTACK_CONF_MAC
47 #define NETSTACK_CONF_MAC csma_driver
48 #endif /* NETSTACK_CONF_MAC */
49 
50 #ifndef NETSTACK_CONF_RDC
51 #define NETSTACK_CONF_RDC nullrdc_driver
52 #endif /* NETSTACK_CONF_RDC */
53 
54 #ifndef NETSTACK_CONF_RADIO
55 #define NETSTACK_CONF_RADIO micromac_radio_driver
56 #endif /* NETSTACK_CONF_RADIO */
57 
58 #ifndef NETSTACK_CONF_FRAMER
59 #define NETSTACK_CONF_FRAMER framer_802154
60 #endif /* NETSTACK_CONF_FRAMER */
61 
62 #define PACKETBUF_CONF_ATTRS_INLINE 1
63 
64 #ifndef IEEE802154_CONF_PANID
65 #define IEEE802154_CONF_PANID 0xABCD
66 #endif /* IEEE802154_CONF_PANID */
67 
68 #ifndef ENERGEST_CONF_ON
69 #define ENERGEST_CONF_ON 1
70 #endif /* ENERGEST_CONF_ON */
71 
72 #define WITH_ASCII 1
73 
74 #define PROCESS_CONF_NUMEVENTS 8
75 #define PROCESS_CONF_STATS 1
76 
77 #if !defined NETSTACK_CONF_WITH_IPV6 && !defined NETSTACK_CONF_WITH_IPV4 && !defined NETSTACK_CONF_WITH_RIME
78 #define NETSTACK_CONF_WITH_IPV6 1
79 #endif /* NETSTACK_CONF_ not defined */
80 
81 /* Network setup for IP */
82 #if NETSTACK_CONF_WITH_IPV4 || NETSTACK_CONF_WITH_IPV6
83 
84 #define LINKADDR_CONF_SIZE 8
85 
86 #ifndef QUEUEBUF_CONF_NUM
87 #define QUEUEBUF_CONF_NUM 16
88 #endif
89 
90 /* Network setup for non-IP (rime). */
91 #else
92 
93 #define LINKADDR_CONF_SIZE 2
94 
95 #ifndef COLLECT_NEIGHBOR_CONF_MAX_COLLECT_NEIGHBORS
96 #define COLLECT_NEIGHBOR_CONF_MAX_COLLECT_NEIGHBORS 32
97 #endif /* COLLECT_NEIGHBOR_CONF_MAX_COLLECT_NEIGHBORS */
98 
99 #ifndef QUEUEBUF_CONF_NUM
100 #define QUEUEBUF_CONF_NUM 16
101 #endif /* QUEUEBUF_CONF_NUM */
102 
103 #endif /* NETSTACK_CONF_WITH_IPV4 || NETSTACK_CONF_WITH_IPV6 */
104 
105 /* Network setup for IPv6 */
106 #if NETSTACK_CONF_WITH_IPV6
107 
108 /* Network setup for IPv6 */
109 #define NETSTACK_CONF_NETWORK sicslowpan_driver
110 #define UIP_CONF_BROADCAST 1
111 
112 /* Configure NullRDC for when it is selected */
113 #define NULLRDC_CONF_802154_AUTOACK_HW 1
114 
115 #define UIP_CONF_LL_802154 1
116 #define UIP_CONF_LLH_LEN 0
117 
118 #define UIP_CONF_ROUTER 1
119 #ifndef UIP_CONF_IPV6_RPL
120 #define UIP_CONF_IPV6_RPL 1
121 #endif /* UIP_CONF_IPV6_RPL */
122 
123 /* configure number of neighbors and routes */
124 #ifndef NBR_TABLE_CONF_MAX_NEIGHBORS
125 #define NBR_TABLE_CONF_MAX_NEIGHBORS 20
126 #endif /* NBR_TABLE_CONF_MAX_NEIGHBORS */
127 #ifndef UIP_CONF_MAX_ROUTES
128 #define UIP_CONF_MAX_ROUTES 20
129 #endif /* UIP_CONF_MAX_ROUTES */
130 
131 #define UIP_CONF_ND6_SEND_RA 0
132 #define UIP_CONF_ND6_REACHABLE_TIME 600000
133 #define UIP_CONF_ND6_RETRANS_TIMER 10000
134 
135 #ifndef UIP_CONF_IPV6_QUEUE_PKT
136 #define UIP_CONF_IPV6_QUEUE_PKT 0
137 #endif /* UIP_CONF_IPV6_QUEUE_PKT */
138 #define UIP_CONF_IPV6_CHECKS 1
139 #define UIP_CONF_IPV6_REASSEMBLY 0
140 #define UIP_CONF_NETIF_MAX_ADDRESSES 3
141 #define UIP_CONF_ND6_MAX_PREFIXES 3
142 #define UIP_CONF_ND6_MAX_DEFROUTERS 2
143 #define UIP_CONF_IP_FORWARD 0
144 #ifndef UIP_CONF_BUFFER_SIZE
145 #define UIP_CONF_BUFFER_SIZE 1280
146 #endif
147 
148 #define SICSLOWPAN_CONF_COMPRESSION_IPV6 0
149 #define SICSLOWPAN_CONF_COMPRESSION_HC1 1
150 #define SICSLOWPAN_CONF_COMPRESSION_HC01 2
151 #define SICSLOWPAN_CONF_COMPRESSION SICSLOWPAN_COMPRESSION_HC06
152 #ifndef SICSLOWPAN_CONF_FRAG
153 #define SICSLOWPAN_CONF_FRAG 1
154 #define SICSLOWPAN_CONF_MAXAGE 8
155 #endif /* SICSLOWPAN_CONF_FRAG */
156 #define SICSLOWPAN_CONF_MAX_ADDR_CONTEXTS 2
157 #define UIP_CONF_ICMP_DEST_UNREACH 1
158 
159 #define UIP_CONF_DHCP_LIGHT
160 #ifndef UIP_CONF_RECEIVE_WINDOW
161 #define UIP_CONF_RECEIVE_WINDOW 48
162 #endif
163 #ifndef UIP_CONF_TCP_MSS
164 #define UIP_CONF_TCP_MSS 48
165 #endif
166 #define UIP_CONF_MAX_CONNECTIONS 4
167 #define UIP_CONF_MAX_LISTENPORTS 8
168 #define UIP_CONF_UDP_CONNS 12
169 #define UIP_CONF_FWCACHE_SIZE 30
170 #define UIP_CONF_BROADCAST 1
171 #define UIP_ARCH_CHKSUM 0
172 #define UIP_ARCH_ADD32 0
173 #define UIP_CONF_UDP 1
174 #define UIP_CONF_UDP_CHECKSUMS 1
175 #define UIP_CONF_PINGADDRCONF 0
176 #define UIP_CONF_LOGGING 0
177 #define LOG_CONF_ENABLED 0
178 
179 #define UIP_CONF_TCP_SPLIT 0
180 
181 #define UIP_CONF_BYTE_ORDER UIP_BIG_ENDIAN
182 #define UIP_CONF_LOGGING 0
183 
184 #endif /* NETSTACK_CONF_WITH_IPV6 */
185 
186 /* include the project config */
187 /* PROJECT_CONF_H might be defined in the project Makefile */
188 #ifdef PROJECT_CONF_H
189 #include PROJECT_CONF_H
190 #endif /* PROJECT_CONF_H */
191 
192 #endif /* CONTIKI_CONF_H_ */