Border Router#

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

Functions#

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.

otBorderRouterAddOnMeshPrefix(otInstance *aInstance, const otBorderRouterConfig *aConfig)

Add a border router configuration to the local network data.

otBorderRouterRemoveOnMeshPrefix(otInstance *aInstance, const otIp6Prefix *aPrefix)

Remove a border router configuration from the local network data.

otBorderRouterGetNextOnMeshPrefix(otInstance *aInstance, otNetworkDataIterator *aIterator, otBorderRouterConfig *aConfig)

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

otBorderRouterAddRoute(otInstance *aInstance, const otExternalRouteConfig *aConfig)

Add an external route configuration to the local network data.

otBorderRouterRemoveRoute(otInstance *aInstance, const otIp6Prefix *aPrefix)

Remove an external route configuration from the local network data.

otBorderRouterGetNextRoute(otInstance *aInstance, otNetworkDataIterator *aIterator, otExternalRouteConfig *aConfig)

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

otBorderRouterRegister(otInstance *aInstance)

Immediately register the local network data with the Leader.

Function Documentation#

otBorderRouterGetNetData#

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]aInstance

A pointer to an OpenThread instance.

[in]aStable

TRUE when copying the stable version, FALSE when copying the full version.

[out]aData

A pointer to the data buffer.

[inout]aDataLength

On entry, size of the data buffer pointed to by aData. On exit, number of copied bytes.


Definition at line 65 of file include/openthread/border_router.h

otBorderRouterAddOnMeshPrefix#

otError otBorderRouterAddOnMeshPrefix (otInstance * aInstance, const otBorderRouterConfig * aConfig)

Add a border router configuration to the local network data.

Parameters
[in]aInstance

A pointer to an OpenThread instance.

[in]aConfig

A pointer to the border router configuration.

See Also


Definition at line 80 of file include/openthread/border_router.h

otBorderRouterRemoveOnMeshPrefix#

otError otBorderRouterRemoveOnMeshPrefix (otInstance * aInstance, const otIp6Prefix * aPrefix)

Remove a border router configuration from the local network data.

Parameters
[in]aInstance

A pointer to an OpenThread instance.

[in]aPrefix

A pointer to an IPv6 prefix.

See Also


Definition at line 94 of file include/openthread/border_router.h

otBorderRouterGetNextOnMeshPrefix#

otError otBorderRouterGetNextOnMeshPrefix (otInstance * aInstance, otNetworkDataIterator * aIterator, otBorderRouterConfig * aConfig)

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

Parameters
[in]aInstance

A pointer to an OpenThread instance.

[inout]aIterator

A 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]aConfig

A pointer to the On Mesh Prefix information.


Definition at line 108 of file include/openthread/border_router.h

otBorderRouterAddRoute#

otError otBorderRouterAddRoute (otInstance * aInstance, const otExternalRouteConfig * aConfig)

Add an external route configuration to the local network data.

Parameters
[in]aInstance

A pointer to an OpenThread instance.

[in]aConfig

A pointer to the external route configuration.

See Also


Definition at line 125 of file include/openthread/border_router.h

otBorderRouterRemoveRoute#

otError otBorderRouterRemoveRoute (otInstance * aInstance, const otIp6Prefix * aPrefix)

Remove an external route configuration from the local network data.

Parameters
[in]aInstance

A pointer to an OpenThread instance.

[in]aPrefix

A pointer to an IPv6 prefix.

See Also


Definition at line 139 of file include/openthread/border_router.h

otBorderRouterGetNextRoute#

otError otBorderRouterGetNextRoute (otInstance * aInstance, otNetworkDataIterator * aIterator, otExternalRouteConfig * aConfig)

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

Parameters
[in]aInstance

A pointer to an OpenThread instance.

[inout]aIterator

A 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]aConfig

A pointer to the External Route information.


Definition at line 153 of file include/openthread/border_router.h

otBorderRouterRegister#

otError otBorderRouterRegister (otInstance * aInstance)

Immediately register the local network data with the Leader.

Parameters
[in]aInstance

A pointer to an OpenThread instance.

See Also


Definition at line 169 of file include/openthread/border_router.h