2013-11-24 16:57:08 +01:00
|
|
|
#ifndef CONTIKI_CONF_H_
|
|
|
|
#define CONTIKI_CONF_H_
|
2006-08-15 01:53:55 +02:00
|
|
|
|
2013-04-20 14:44:27 +02:00
|
|
|
#ifdef __CYGWIN__
|
|
|
|
#include <sys/types.h>
|
|
|
|
#endif
|
|
|
|
|
2006-08-15 01:53:55 +02:00
|
|
|
#define CC_CONF_REGISTER_ARGS 1
|
2007-12-15 01:00:34 +01:00
|
|
|
#define CC_CONF_FASTCALL __fastcall
|
|
|
|
#define CC_CONF_INLINE __inline
|
2006-08-15 01:53:55 +02:00
|
|
|
|
2013-03-14 23:17:59 +01:00
|
|
|
#define ARCH_DOESNT_NEED_ALIGNED_STRUCTS 1
|
|
|
|
|
2006-08-15 01:53:55 +02:00
|
|
|
|
|
|
|
#if _USRDLL
|
2006-08-15 16:46:33 +02:00
|
|
|
#define CCIF __declspec(dllimport)
|
2007-12-15 01:00:34 +01:00
|
|
|
#else /* _USRDLL */
|
2006-08-15 16:46:33 +02:00
|
|
|
#define CCIF __declspec(dllexport)
|
2007-12-15 01:00:34 +01:00
|
|
|
#endif /* _USRDLL */
|
2006-08-17 00:47:01 +02:00
|
|
|
#define CLIF __declspec(dllexport)
|
2006-08-15 01:53:55 +02:00
|
|
|
|
2007-11-18 01:55:19 +01:00
|
|
|
#ifdef __CYGWIN__
|
|
|
|
int strcasecmp(const char*, const char*);
|
2013-03-13 14:43:05 +01:00
|
|
|
int strncasecmp(const char*, const char*, size_t);
|
2007-11-18 03:16:57 +01:00
|
|
|
char* strdup(const char*);
|
2007-12-15 01:00:34 +01:00
|
|
|
#else /* __CYGWIN__ */
|
2008-02-10 13:13:06 +01:00
|
|
|
#define HAVE_SNPRINTF
|
2013-03-13 14:43:05 +01:00
|
|
|
#define snprintf _snprintf
|
|
|
|
#define strcasecmp _stricmp
|
|
|
|
#define strncasecmp _strnicmp
|
|
|
|
#define strdup _strdup
|
2007-12-15 01:00:34 +01:00
|
|
|
#endif /* __CYGWIN__ */
|
2006-08-31 00:07:53 +02:00
|
|
|
|
|
|
|
|
2006-08-15 01:53:55 +02:00
|
|
|
#define LOG_CONF_ENABLED 1
|
|
|
|
#include "sys/log.h"
|
2006-09-23 22:12:40 +02:00
|
|
|
CCIF void debug_printf(char *format, ...);
|
2006-08-15 01:53:55 +02:00
|
|
|
|
|
|
|
|
2007-04-15 01:23:15 +02:00
|
|
|
#define CLOCK_CONF_SECOND 1000
|
2006-08-15 01:53:55 +02:00
|
|
|
typedef unsigned long clock_time_t;
|
|
|
|
|
|
|
|
|
2007-12-06 23:09:56 +01:00
|
|
|
typedef signed char int8_t;
|
|
|
|
typedef unsigned char uint8_t;
|
|
|
|
typedef signed short int16_t;
|
|
|
|
typedef unsigned short uint16_t;
|
2010-04-21 22:35:22 +02:00
|
|
|
typedef signed int int32_t;
|
|
|
|
typedef unsigned int uint32_t;
|
2007-12-06 23:09:56 +01:00
|
|
|
|
|
|
|
/* These names are deprecated, use C99 names. */
|
|
|
|
typedef unsigned char u8_t;
|
|
|
|
typedef unsigned short u16_t;
|
|
|
|
typedef unsigned long u32_t;
|
|
|
|
typedef long s32_t;
|
|
|
|
|
|
|
|
typedef unsigned short uip_stats_t;
|
|
|
|
|
2014-01-17 22:07:03 +01:00
|
|
|
#define UIP_CONF_LLH_LEN 14
|
|
|
|
#define UIP_CONF_BUFFER_SIZE 1514
|
|
|
|
#define UIP_CONF_TCP_SPLIT 1
|
|
|
|
#define UIP_CONF_LOGGING 1
|
|
|
|
#define UIP_CONF_UDP_CHECKSUMS 1
|
|
|
|
#define UIP_CONF_IP_FORWARD 0
|
2015-06-21 14:15:41 +02:00
|
|
|
#if NETSTACK_CONF_WITH_IPV6
|
2014-01-17 22:07:03 +01:00
|
|
|
#define NBR_TABLE_CONF_MAX_NEIGHBORS 100
|
|
|
|
#define UIP_CONF_DS6_DEFRT_NBU 2
|
|
|
|
#define UIP_CONF_DS6_PREFIX_NBU 5
|
|
|
|
#define UIP_CONF_MAX_ROUTES 100
|
|
|
|
#define UIP_CONF_DS6_ADDR_NBU 10
|
|
|
|
#define UIP_CONF_DS6_MADDR_NBU 0 //VC++ does not allow zero length arrays
|
|
|
|
#define UIP_CONF_DS6_AADDR_NBU 0 //inside a struct
|
2011-06-28 14:24:23 +02:00
|
|
|
#endif
|
2007-12-06 23:09:56 +01:00
|
|
|
|
2015-05-02 00:17:53 +02:00
|
|
|
#define RESOLV_CONF_SUPPORTS_MDNS 0
|
|
|
|
#define RESOLV_CONF_SUPPORTS_RECORD_EXPIRATION 0
|
2006-08-15 01:53:55 +02:00
|
|
|
|
|
|
|
#include <ctype.h>
|
|
|
|
#define ctk_arch_isprint isprint
|
|
|
|
|
2007-04-15 15:30:16 +02:00
|
|
|
#include "ctk/ctk-console.h"
|
|
|
|
|
2013-02-09 02:02:46 +01:00
|
|
|
#define CH_ULCORNER '+'
|
|
|
|
#define CH_URCORNER '+'
|
|
|
|
#define CH_LLCORNER '+'
|
|
|
|
#define CH_LRCORNER '+'
|
|
|
|
#define CH_ENTER '\r'
|
|
|
|
#define CH_DEL '\b'
|
|
|
|
#define CH_CURS_UP -1
|
|
|
|
#define CH_CURS_LEFT -2
|
|
|
|
#define CH_CURS_RIGHT -3
|
|
|
|
#define CH_CURS_DOWN -4
|
2006-08-15 01:53:55 +02:00
|
|
|
|
|
|
|
#define CTK_CONF_MENU_KEY -5 /* F10 */
|
|
|
|
#define CTK_CONF_WINDOWSWITCH_KEY -6 /* Ctrl-Tab */
|
|
|
|
#define CTK_CONF_WIDGETUP_KEY -7 /* Shift-Tab */
|
2007-12-16 00:02:16 +01:00
|
|
|
#define CTK_CONF_WIDGETDOWN_KEY '\t'
|
2007-12-15 01:00:34 +01:00
|
|
|
#define CTK_CONF_WIDGET_FLAGS 0
|
|
|
|
#define CTK_CONF_SCREENSAVER 0
|
|
|
|
|
|
|
|
#ifdef PLATFORM_BUILD
|
2006-08-15 01:53:55 +02:00
|
|
|
#define CTK_CONF_MOUSE_SUPPORT 1
|
2007-12-06 23:09:56 +01:00
|
|
|
#define CTK_CONF_WINDOWS 1
|
2007-12-15 01:00:34 +01:00
|
|
|
#define CTK_CONF_WINDOWMOVE 1
|
|
|
|
#define CTK_CONF_WINDOWCLOSE 1
|
2006-08-15 01:53:55 +02:00
|
|
|
#define CTK_CONF_ICONS 1
|
|
|
|
#define CTK_CONF_ICON_BITMAPS 0
|
|
|
|
#define CTK_CONF_ICON_TEXTMAPS 1
|
|
|
|
#define CTK_CONF_MENUS 1
|
|
|
|
#define CTK_CONF_MENUWIDTH 16
|
|
|
|
#define CTK_CONF_MAXMENUITEMS 10
|
2007-12-15 01:00:34 +01:00
|
|
|
#else /* PLATFORM_BUILD */
|
2007-12-15 22:30:56 +01:00
|
|
|
#define CTK_CONF_MOUSE_SUPPORT 1
|
2007-12-15 01:00:34 +01:00
|
|
|
#define CTK_CONF_WINDOWS 0
|
|
|
|
#define CTK_CONF_WINDOWMOVE 0
|
|
|
|
#define CTK_CONF_WINDOWCLOSE 0
|
|
|
|
#define CTK_CONF_ICONS 0
|
|
|
|
#define CTK_CONF_MENUS 0
|
2007-12-15 22:39:06 +01:00
|
|
|
#endif /* PLATFORM_BUILD */
|
2007-12-15 01:00:34 +01:00
|
|
|
|
2013-03-26 11:50:09 +01:00
|
|
|
#define CTK_COLOR_BLACK (0)
|
|
|
|
#define CTK_COLOR_BLUE (1)
|
|
|
|
#define CTK_COLOR_GRAY (1 | 2 | 4)
|
|
|
|
#define CTK_COLOR_CYAN (1 | 2 | 8)
|
|
|
|
#define CTK_COLOR_YELLOW (2 | 4 | 8)
|
|
|
|
#define CTK_COLOR_WHITE (1 | 2 | 4 | 8)
|
|
|
|
|
|
|
|
#define COLOR_BG CTK_COLOR_BLUE
|
|
|
|
|
|
|
|
#define BORDERCOLOR CTK_COLOR_BLACK
|
|
|
|
#define SCREENCOLOR CTK_COLOR_BLACK
|
|
|
|
#define BACKGROUNDCOLOR CTK_COLOR_BLACK
|
|
|
|
#define WINDOWCOLOR_FOCUS CTK_COLOR_WHITE | COLOR_BG * 0x10
|
|
|
|
#define WINDOWCOLOR CTK_COLOR_GRAY | COLOR_BG * 0x10
|
|
|
|
#define DIALOGCOLOR CTK_COLOR_WHITE | COLOR_BG * 0x10
|
|
|
|
#define WIDGETCOLOR_HLINK CTK_COLOR_CYAN | COLOR_BG * 0x10
|
|
|
|
#define WIDGETCOLOR_FWIN CTK_COLOR_WHITE | COLOR_BG * 0x10
|
|
|
|
#define WIDGETCOLOR CTK_COLOR_GRAY | COLOR_BG * 0x10
|
|
|
|
#define WIDGETCOLOR_DIALOG CTK_COLOR_WHITE | COLOR_BG * 0x10
|
|
|
|
#define WIDGETCOLOR_FOCUS CTK_COLOR_YELLOW | COLOR_BG * 0x10
|
|
|
|
#define MENUCOLOR CTK_COLOR_WHITE | COLOR_BG * 0x10
|
|
|
|
#define OPENMENUCOLOR CTK_COLOR_WHITE | COLOR_BG * 0x10
|
|
|
|
#define ACTIVEMENUITEMCOLOR CTK_COLOR_YELLOW | COLOR_BG * 0x10
|
2006-08-15 01:53:55 +02:00
|
|
|
|
|
|
|
|
2007-12-15 01:00:34 +01:00
|
|
|
#ifdef PLATFORM_BUILD
|
2006-08-15 01:53:55 +02:00
|
|
|
#define LOADER_CONF_ARCH "loader/dll-loader.h"
|
2010-10-12 13:03:53 +02:00
|
|
|
#else /* PLATFORM_BUILD */
|
|
|
|
#define LOADER_CONF_ARCH "loader/unload.h"
|
2007-12-15 22:39:06 +01:00
|
|
|
#endif /* PLATFORM_BUILD */
|
2006-08-15 01:53:55 +02:00
|
|
|
|
|
|
|
#define PROGRAM_HANDLER_CONF_MAX_NUMDSCS 10
|
2006-08-31 00:41:52 +02:00
|
|
|
#define PROGRAM_HANDLER_CONF_QUIT_MENU 1
|
2006-08-15 01:53:55 +02:00
|
|
|
|
|
|
|
|
2007-12-06 23:09:56 +01:00
|
|
|
#define EMAIL_CONF_WIDTH 76
|
2008-02-08 00:06:03 +01:00
|
|
|
#define EMAIL_CONF_HEIGHT 30
|
2010-01-31 22:49:13 +01:00
|
|
|
#ifndef PLATFORM_BUILD
|
|
|
|
#define EMAIL_CONF_ERASE 0
|
|
|
|
#endif
|
2007-11-17 23:40:33 +01:00
|
|
|
|
2007-12-06 23:09:56 +01:00
|
|
|
#define IRC_CONF_WIDTH 78
|
|
|
|
#define IRC_CONF_HEIGHT 30
|
|
|
|
#define IRC_CONF_SYSTEM_STRING "Win32"
|
2007-11-17 23:40:33 +01:00
|
|
|
|
2006-08-15 01:53:55 +02:00
|
|
|
|
2007-12-06 23:09:56 +01:00
|
|
|
#define SHELL_CONF_WITH_PROGRAM_HANDLER 1
|
2006-08-15 01:53:55 +02:00
|
|
|
|
|
|
|
|
2008-02-08 00:06:03 +01:00
|
|
|
#define SHELL_GUI_CONF_XSIZE 78
|
|
|
|
#define SHELL_GUI_CONF_YSIZE 30
|
2006-08-15 01:53:55 +02:00
|
|
|
|
|
|
|
|
2015-07-06 12:25:20 +02:00
|
|
|
#define TELNETD_CONF_MAX_IDLE_TIME 300
|
2011-04-10 17:08:50 +02:00
|
|
|
#ifdef PLATFORM_BUILD
|
2015-07-06 12:25:20 +02:00
|
|
|
#define TELNETD_CONF_GUI 1
|
2011-04-10 17:08:50 +02:00
|
|
|
#endif /* PLATFORM_BUILD */
|
2007-04-13 23:04:52 +02:00
|
|
|
|
|
|
|
|
2007-12-15 22:39:06 +01:00
|
|
|
#ifdef PLATFORM_BUILD
|
2007-12-06 23:09:56 +01:00
|
|
|
#define WWW_CONF_WEBPAGE_WIDTH 76
|
|
|
|
#define WWW_CONF_WEBPAGE_HEIGHT 30
|
2014-02-02 20:19:47 +01:00
|
|
|
#else /* PLATFORM_BUILD */
|
2014-01-24 16:09:30 +01:00
|
|
|
#define WWW_CONF_WGET_EXEC(url) execlp("wget.win32", "wget.win32", \
|
|
|
|
"192.168.0.2", url, (char *)NULL)
|
2014-02-02 20:19:47 +01:00
|
|
|
#endif /* PLATFORM_BUILD */
|
2007-04-13 23:04:52 +02:00
|
|
|
|
2013-11-24 16:57:08 +01:00
|
|
|
#endif /* CONTIKI_CONF_H_ */
|