mirror of
https://github.com/espressif/openthread.git
synced 2026-09-16 14:10:09 +00:00
[ip6] define NetworkPrefix type (#5213)
This commit adds `Ip6::NetworkPrefix` mirroring `otIp6NetworkPrefix` which represents the Network Prefix (most significant 64 bits) of an IPv6 address. Methods in `Ip6::Address` are updated to use the new type. The `otMeshLocalPrefix` and `Mle::MeshLocalPrefix` are also updated use the `NetworkPrefix` type.
This commit is contained in:
@@ -99,23 +99,13 @@ struct otExtendedPanId
|
||||
*/
|
||||
typedef struct otExtendedPanId otExtendedPanId;
|
||||
|
||||
#define OT_MESH_LOCAL_PREFIX_SIZE 8 ///< Size of the Mesh Local Prefix (bytes)
|
||||
#define OT_MESH_LOCAL_PREFIX_SIZE OT_IP6_PREFIX_SIZE ///< Size of the Mesh Local Prefix (bytes)
|
||||
|
||||
/**
|
||||
* This structure represents a Mesh Local Prefix.
|
||||
*
|
||||
*/
|
||||
OT_TOOL_PACKED_BEGIN
|
||||
struct otMeshLocalPrefix
|
||||
{
|
||||
uint8_t m8[OT_MESH_LOCAL_PREFIX_SIZE]; ///< Byte values
|
||||
} OT_TOOL_PACKED_END;
|
||||
|
||||
/**
|
||||
* This structure represents a Mesh Local Prefix.
|
||||
*
|
||||
*/
|
||||
typedef struct otMeshLocalPrefix otMeshLocalPrefix;
|
||||
typedef otIp6NetworkPrefix otMeshLocalPrefix;
|
||||
|
||||
#define OT_PSKC_MAX_SIZE 16 ///< Maximum size of the PSKc (bytes)
|
||||
|
||||
|
||||
@@ -53,7 +53,7 @@ extern "C" {
|
||||
* @note This number versions both OpenThread platform and user APIs.
|
||||
*
|
||||
*/
|
||||
#define OPENTHREAD_API_VERSION (16)
|
||||
#define OPENTHREAD_API_VERSION (17)
|
||||
|
||||
/**
|
||||
* @addtogroup api-instance
|
||||
|
||||
Reference in New Issue
Block a user