Skip to content

Commit 8167e53

Browse files
author
Mika Tervonen
committed
modified Wi-SUN tasklet to return success when calling connet twice
Modified flagging of mesh APIs to not use internal RF chip flag changed default mesh interface to NULL instead of Thread Added some extra traces for Wi-SUN
1 parent f513bce commit 8167e53

File tree

6 files changed

+6
-6
lines changed

6 files changed

+6
-6
lines changed

features/nanostack/mbed-mesh-api/source/LoWPANNDInterface.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ bool LoWPANNDInterface::getRouterIpAddress(char *address, int8_t len)
171171
}
172172

173173
#define LOWPAN 0x2345
174-
#if MBED_CONF_NSAPI_DEFAULT_MESH_TYPE == LOWPAN && DEVICE_802_15_4_PHY
174+
#if MBED_CONF_NSAPI_DEFAULT_MESH_TYPE == LOWPAN
175175
MBED_WEAK MeshInterface *MeshInterface::get_target_default_instance()
176176
{
177177
static bool inited;

features/nanostack/mbed-mesh-api/source/MeshInterfaceNanostack.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ nsapi_error_t InterfaceNanostack::set_file_system_root_path(const char *root_pat
230230
return MESH_ERROR_UNKNOWN;
231231
}
232232

233-
#if !DEVICE_802_15_4_PHY
233+
#ifndef MBED_CONF_NSAPI_DEFAULT_MESH_TYPE
234234
MBED_WEAK MeshInterface *MeshInterface::get_target_default_instance()
235235
{
236236
return NULL;

features/nanostack/mbed-mesh-api/source/ThreadInterface.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ mesh_error_t Nanostack::ThreadInterface::device_pskd_set(const char *pskd)
261261
}
262262

263263
#define THREAD 0x2345
264-
#if MBED_CONF_NSAPI_DEFAULT_MESH_TYPE == THREAD && DEVICE_802_15_4_PHY
264+
#if MBED_CONF_NSAPI_DEFAULT_MESH_TYPE == THREAD
265265

266266
MBED_WEAK MeshInterface *MeshInterface::get_target_default_instance()
267267
{

features/nanostack/mbed-mesh-api/source/WisunInterface.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ mesh_error_t WisunInterface::remove_trusted_certificates(void)
248248
}
249249

250250
#define WISUN 0x2345
251-
#if MBED_CONF_NSAPI_DEFAULT_MESH_TYPE == WISUN && DEVICE_802_15_4_PHY
251+
#if MBED_CONF_NSAPI_DEFAULT_MESH_TYPE == WISUN
252252
MBED_WEAK MeshInterface *MeshInterface::get_target_default_instance()
253253
{
254254
static bool inited;

features/nanostack/nanostack-interface/Nanostack.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ nsapi_error_t map_mesh_error(mesh_error_t err)
116116
case MESH_ERROR_PARAM:
117117
return NSAPI_ERROR_PARAMETER;
118118
case MESH_ERROR_STATE:
119-
return NSAPI_ERROR_DEVICE_ERROR;
119+
return NSAPI_ERROR_IS_CONNECTED;
120120
default:
121121
return NSAPI_ERROR_DEVICE_ERROR;
122122
}

features/netsocket/mbed_lib.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
},
4141
"default-mesh-type": {
4242
"help": "Configuration type for MeshInterface::get_default_instance(). [LOWPAN/THREAD/WISUN]",
43-
"value": "THREAD"
43+
"value": null
4444
},
4545
"dns-response-wait-time": {
4646
"help": "How long the DNS translator waits for a reply from a server in milliseconds",

0 commit comments

Comments
 (0)