nRF5 SDK for Thread and Zigbee v4.0.0
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Border Router

This module includes functions to manage local network data with the OpenThread Border Router. More...

Functions

otError otBorderRouterGetNetData (otInstance *aInstance, bool aStable, uint8_t *aData, uint8_t *aDataLength)
 
otError otBorderRouterAddOnMeshPrefix (otInstance *aInstance, const otBorderRouterConfig *aConfig)
 
otError otBorderRouterRemoveOnMeshPrefix (otInstance *aInstance, const otIp6Prefix *aPrefix)
 
otError otBorderRouterGetNextOnMeshPrefix (otInstance *aInstance, otNetworkDataIterator *aIterator, otBorderRouterConfig *aConfig)
 
otError otBorderRouterAddRoute (otInstance *aInstance, const otExternalRouteConfig *aConfig)
 
otError otBorderRouterRemoveRoute (otInstance *aInstance, const otIp6Prefix *aPrefix)
 
otError otBorderRouterGetNextRoute (otInstance *aInstance, otNetworkDataIterator *aIterator, otExternalRouteConfig *aConfig)
 
otError otBorderRouterRegister (otInstance *aInstance)
 

Detailed Description

This module includes functions to manage local network data with the OpenThread Border Router.

Function Documentation

otError otBorderRouterAddOnMeshPrefix ( otInstance aInstance,
const otBorderRouterConfig aConfig 
)

Add a border router configuration to the local network data.

Parameters
[in]aInstanceA pointer to an OpenThread instance.
[in]aConfigA pointer to the border router configuration.
Return values
OT_ERROR_NONESuccessfully added the configuration to the local network data.
OT_ERROR_INVALID_ARGSOne or more configuration parameters were invalid.
OT_ERROR_NO_BUFSNot enough room is available to add the configuration to the local network data.
See also
otBorderRouterRemoveOnMeshPrefix
otBorderRouterRegister
otError otBorderRouterAddRoute ( otInstance aInstance,
const otExternalRouteConfig aConfig 
)

Add an external route configuration to the local network data.

Parameters
[in]aInstanceA pointer to an OpenThread instance.
[in]aConfigA pointer to the external route configuration.
Return values
OT_ERROR_NONESuccessfully added the configuration to the local network data.
OT_ERROR_INVALID_ARGSOne or more configuration parameters were invalid.
OT_ERROR_NO_BUFSNot enough room is available to add the configuration to the local network data.
See also
otBorderRouterRemoveRoute
otBorderRouterRegister
otError otBorderRouterGetNetData ( otInstance aInstance,
bool  aStable,
uint8_t *  aData,
uint8_t *  aDataLength 
)

This method provides a full or stable copy of the local Thread Network Data.

Parameters
[in]aInstanceA pointer to an OpenThread instance.
[in]aStableTRUE when copying the stable version, FALSE when copying the full version.
[out]aDataA pointer to the data buffer.
[in,out]aDataLengthOn entry, size of the data buffer pointed to by aData. On exit, number of copied bytes.
otError otBorderRouterGetNextOnMeshPrefix ( otInstance aInstance,
otNetworkDataIterator aIterator,
otBorderRouterConfig aConfig 
)

This function gets the next On Mesh Prefix in the local Network Data.

Parameters
[in]aInstanceA pointer to an OpenThread instance.
[in,out]aIteratorA pointer to the Network Data iterator context. To get the first on-mesh entry it should be set to OT_NETWORK_DATA_ITERATOR_INIT.
[out]aConfigA pointer to the On Mesh Prefix information.
Return values
OT_ERROR_NONESuccessfully found the next On Mesh prefix.
OT_ERROR_NOT_FOUNDNo subsequent On Mesh prefix exists in the Thread Network Data.
otError otBorderRouterGetNextRoute ( otInstance aInstance,
otNetworkDataIterator aIterator,
otExternalRouteConfig aConfig 
)

This function gets the next external route in the local Network Data.

Parameters
[in]aInstanceA pointer to an OpenThread instance.
[in,out]aIteratorA pointer to the Network Data iterator context. To get the first external route entry it should be set to OT_NETWORK_DATA_ITERATOR_INIT.
[out]aConfigA pointer to the External Route information.
Return values
OT_ERROR_NONESuccessfully found the next External Route.
OT_ERROR_NOT_FOUNDNo subsequent external route entry exists in the Thread Network Data.
otError otBorderRouterRegister ( otInstance aInstance)

Immediately register the local network data with the Leader.

Parameters
[in]aInstanceA pointer to an OpenThread instance.
Return values
OT_ERROR_NONESuccessfully queued a Server Data Request message for delivery.
See also
otBorderRouterAddOnMeshPrefix
otBorderRouterRemoveOnMeshPrefix
otBorderRouterAddRoute
otBorderRouterRemoveRoute
otError otBorderRouterRemoveOnMeshPrefix ( otInstance aInstance,
const otIp6Prefix aPrefix 
)

Remove a border router configuration from the local network data.

Parameters
[in]aInstanceA pointer to an OpenThread instance.
[in]aPrefixA pointer to an IPv6 prefix.
Return values
OT_ERROR_NONESuccessfully removed the configuration from the local network data.
OT_ERROR_NOT_FOUNDCould not find the Border Router entry.
See also
otBorderRouterAddOnMeshPrefix
otBorderRouterRegister
otError otBorderRouterRemoveRoute ( otInstance aInstance,
const otIp6Prefix aPrefix 
)

Remove an external route configuration from the local network data.

Parameters
[in]aInstanceA pointer to an OpenThread instance.
[in]aPrefixA pointer to an IPv6 prefix.
Return values
OT_ERROR_NONESuccessfully removed the configuration from the local network data.
OT_ERROR_NOT_FOUNDCould not find the Border Router entry.
See also
otBorderRouterAddRoute
otBorderRouterRegister