Removed obsolete OC_WELL_KNOWN_PORT that was causing warnings.
Change-Id: I40034334e723b817818f80d9fedd60ed6ebcaf3a
Signed-off-by: Yuliya Kamatkova <yuliya.kamatkova@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/360
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sashi Penta <sashi.kumar.penta@intel.com>
Reviewed-by: Sudarshan Prasad <sudarshan.prasad@intel.com>
static char responsePayloadGet[] = "{\"href\":\"/a/light\",\"rep\":{\"state\":\"on\",\"power\":10}}";
static char responsePayloadPut[] = "{\"href\":\"/a/light\",\"rep\":{\"state\":\"off\",\"power\":0}}";
-/// This is the port which Arduino Server will use for all unicast communication with it's peers
-static uint16_t OC_WELL_KNOWN_PORT = 5683;
-
#ifdef ARDUINOWIFI
// Arduino WiFi Shield
// Note : Arduino WiFi Shield currently does NOT support multicast and therefore
// Note : This will initialize Serial port on Arduino at 115200 bauds
OC_LOG_INIT();
OC_LOG(DEBUG, TAG, PCF("OCServer is starting..."));
- uint16_t port = OC_WELL_KNOWN_PORT;
// Connect to Ethernet or WiFi network
if (ConnectToNetwork() != 0)
}
// Initialize the OC Stack in Server mode
- if (OCInit(NULL, port, OC_SERVER) != OC_STACK_OK)
+ if (OCInit(NULL, 0, OC_SERVER) != OC_STACK_OK)
{
OC_LOG(ERROR, TAG, PCF("OCStack init error"));
return;
//char *gResourceUri= const_cast<char *>("/a/led");
char *gResourceUri= (char *)"/a/led";
-static constexpr uint16_t OC_WELL_KNOWN_PORT = 5683;
-
//This function takes the request as an input and returns the response
//in JSON format.
char* constructJsonResponse (OCEntityHandlerRequest *ehRequest)
#include "oic_lanLib.h"
#define ARDUINO_AVR_MEGA2560 1
-/// This is the port which Arduino Server will use for all unicast communication with it's peers
-#define OC_WELL_KNOWN_PORT 5683
#define JSON_BASE00 "{\"href\":\"\",\"rep\":{"
#define JSON_BASE01 "\"0\":\"MAC\",\"1\":\"string\",\"2\":\""
}
// Initialize the OC Stack in Server mode
- if (OCInit(NULL, OC_WELL_KNOWN_PORT, OC_SERVER) != OC_STACK_OK)
+ if (OCInit(NULL, 0, OC_SERVER) != OC_STACK_OK)
{
OC_LOG(ERROR, TAG, PCF("OCStack init error"));
return;
static THResource TH;
-/// This is the port which Arduino Server will use for all unicast communication with it's peers
-static uint16_t OC_WELL_KNOWN_PORT = 5683;
-
#define JSON_BASE00 "{\"href\":\"\",\"rep\":{"
#define JSON_BASE01 "\"0\":\"temperature\",\"1\":\"int\",\"2\":\""
#define JSON_BASE02 "\",\"3\":\"humidity\",\"4\":\"int\",\"5\":\""
OC_LOG_INIT();
OC_LOG(DEBUG, TAG, PCF("OCServer is starting..."));
- uint16_t port = OC_WELL_KNOWN_PORT;
// Connect to Ethernet or WiFi network
if (ConnectToNetwork() != 0)
}
// Initialize the OC Stack in Server mode
- if (OCInit(NULL, port, OC_SERVER) != OC_STACK_OK)
+ if (OCInit(NULL, 0, OC_SERVER) != OC_STACK_OK)
{
OC_LOG(ERROR, TAG, PCF("OCStack init error"));
return;
static THResource TH;
-/// This is the port which Arduino Server will use for all unicast communication with it's peers
-static uint16_t OC_WELL_KNOWN_PORT = 5683;
-
#define JSON_BASE00 "{\"href\":\"\",\"rep\":{"
#define JSON_BASE01 "\"0\":\"temperature\",\"1\":\"int\",\"2\":\""
#define JSON_BASE02 "\",\"3\":\"humidity\",\"4\":\"int\",\"5\":\""
OC_LOG_INIT();
OC_LOG(DEBUG, TAG, PCF("OCServer is starting..."));
- uint16_t port = OC_WELL_KNOWN_PORT;
// Connect to Ethernet or WiFi network
if (ConnectToNetwork() != 0)
}
// Initialize the OC Stack in Server mode
- if (OCInit(NULL, port, OC_SERVER) != OC_STACK_OK)
+ if (OCInit(NULL, 0, OC_SERVER) != OC_STACK_OK)
{
OC_LOG(ERROR, TAG, PCF("OCStack init error"));
return;
#define SLAVER_EA 2
#define ARDUINO_AVR_MEGA2560 1
-/// This is the port which Arduino Server will use for all unicast communication with it's peers
-#define OC_WELL_KNOWN_PORT 5683
PROGMEM const char TAG[] = "TrackeeSensor";
OC_LOG_INIT();
OC_LOG(DEBUG, TAG, PCF("OCServer is starting..."));
- // uint16_t port = OC_WELL_KNOWN_PORT;
// Connect to Ethernet or WiFi network
if (ConnectToNetwork() != 0)
}
// Initialize the OC Stack in Server mode
- if (OCInit(NULL, OC_WELL_KNOWN_PORT, OC_SERVER) != OC_STACK_OK)
+ if (OCInit(NULL, 0, OC_SERVER) != OC_STACK_OK)
{
OC_LOG(ERROR, TAG, PCF("OCStack init error"));
return;