From 364fc9cacff3e488b8245dc88b57de4cd8b4002e Mon Sep 17 00:00:00 2001 From: George Oikonomou Date: Fri, 1 May 2015 15:54:28 +0100 Subject: [PATCH 1/2] Define button_sensor in contiki-conf.h --- platform/srf06-cc26xx/contiki-conf.h | 7 +++++++ platform/srf06-cc26xx/sensortag/button-sensor.h | 1 - platform/srf06-cc26xx/srf06/button-sensor.h | 1 - 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/platform/srf06-cc26xx/contiki-conf.h b/platform/srf06-cc26xx/contiki-conf.h index 6a99c29b3..d87e37954 100644 --- a/platform/srf06-cc26xx/contiki-conf.h +++ b/platform/srf06-cc26xx/contiki-conf.h @@ -310,6 +310,13 @@ /* Notify various examples that we have Buttons */ #define PLATFORM_HAS_BUTTON 1 + +/* + * Override button symbols from dev/button-sensor.h, for the examples that + * include it + */ +#define button_sensor button_left_sensor +#define button_sensor2 button_right_sensor /** @} */ /*---------------------------------------------------------------------------*/ /* Platform-specific define to signify sensor reading failure */ diff --git a/platform/srf06-cc26xx/sensortag/button-sensor.h b/platform/srf06-cc26xx/sensortag/button-sensor.h index 6e15b4d4c..25acb104f 100644 --- a/platform/srf06-cc26xx/sensortag/button-sensor.h +++ b/platform/srf06-cc26xx/sensortag/button-sensor.h @@ -54,7 +54,6 @@ #define BUTTON_SENSOR_VALUE_RELEASED 0 #define BUTTON_SENSOR_VALUE_PRESSED 1 /*---------------------------------------------------------------------------*/ -#define button_sensor button_left_sensor extern const struct sensors_sensor button_left_sensor; extern const struct sensors_sensor button_right_sensor; /*---------------------------------------------------------------------------*/ diff --git a/platform/srf06-cc26xx/srf06/button-sensor.h b/platform/srf06-cc26xx/srf06/button-sensor.h index 1f5752059..2c47f9118 100644 --- a/platform/srf06-cc26xx/srf06/button-sensor.h +++ b/platform/srf06-cc26xx/srf06/button-sensor.h @@ -49,7 +49,6 @@ #define BUTTON_SENSOR_VALUE_RELEASED 0 #define BUTTON_SENSOR_VALUE_PRESSED 1 /*---------------------------------------------------------------------------*/ -#define button_sensor button_select_sensor extern const struct sensors_sensor button_select_sensor; extern const struct sensors_sensor button_left_sensor; extern const struct sensors_sensor button_right_sensor; From a72d90e28356277f6f07fdaf5b33de3b4fbabe40 Mon Sep 17 00:00:00 2001 From: George Oikonomou Date: Fri, 1 May 2015 15:55:21 +0100 Subject: [PATCH 2/2] Control TCP MSS in the project's conf --- examples/cc26xx/cc26xx-web-demo/project-conf.h | 6 +++++- platform/srf06-cc26xx/contiki-conf.h | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/examples/cc26xx/cc26xx-web-demo/project-conf.h b/examples/cc26xx/cc26xx-web-demo/project-conf.h index d49a7b3e9..b7baac119 100644 --- a/examples/cc26xx/cc26xx-web-demo/project-conf.h +++ b/examples/cc26xx/cc26xx-web-demo/project-conf.h @@ -44,10 +44,14 @@ #define CC26XX_WEB_DEMO_CONF_COAP_SERVER 1 #define CC26XX_WEB_DEMO_CONF_NET_UART 1 /*---------------------------------------------------------------------------*/ -/* Shrink the size of the uIP buffer, routing table and ND cache */ +/* + * Shrink the size of the uIP buffer, routing table and ND cache. + * Set the TCP MSS + */ #define UIP_CONF_BUFFER_SIZE 900 #define NBR_TABLE_CONF_MAX_NEIGHBORS 8 #define UIP_CONF_MAX_ROUTES 8 +#define UIP_CONF_TCP_MSS 128 /*---------------------------------------------------------------------------*/ #endif /* PROJECT_CONF_H_ */ /*---------------------------------------------------------------------------*/ diff --git a/platform/srf06-cc26xx/contiki-conf.h b/platform/srf06-cc26xx/contiki-conf.h index d87e37954..d5c1aa402 100644 --- a/platform/srf06-cc26xx/contiki-conf.h +++ b/platform/srf06-cc26xx/contiki-conf.h @@ -220,7 +220,7 @@ #define UIP_CONF_TCP 1 #endif #ifndef UIP_CONF_TCP_MSS -#define UIP_CONF_TCP_MSS 128 +#define UIP_CONF_TCP_MSS 64 #endif #define UIP_CONF_UDP 1