mirror of
https://github.com/espressif/openthread.git
synced 2026-09-16 06:00:13 +00:00
Add API to retrieve router diag information. (#225)
This commit is contained in:
@@ -394,6 +394,24 @@ typedef enum
|
||||
kDeviceRoleLeader, ///< The Thread Leader role.
|
||||
} otDeviceRole;
|
||||
|
||||
/**
|
||||
* This structure holds diagnostics information for a Thread Router
|
||||
*
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
otExtAddress mExtAddress; ///< IEEE 802.15.4 Extended Address
|
||||
uint16_t mRloc16; ///< RLOC16
|
||||
uint8_t mRouterId; ///< Router ID
|
||||
uint8_t mNextHop; ///< Next hop to router
|
||||
uint8_t mPathCost; ///< Path cost to router
|
||||
uint8_t mLinkQualityIn; ///< Link Quality In
|
||||
uint8_t mLinkQualityOut; ///< Link Quality Out
|
||||
uint8_t mAge; ///< Time last heard
|
||||
bool mAllocated : 1; ///< Router ID allocated or not
|
||||
bool mLinkEstablished : 1; ///< Link established with Router ID or not
|
||||
} otRouterInfo;
|
||||
|
||||
/**
|
||||
* This structure represents the MAC layer counters.
|
||||
*/
|
||||
|
||||
@@ -907,6 +907,15 @@ uint16_t otGetRloc16(void);
|
||||
*/
|
||||
uint8_t otGetRouterIdSequence(void);
|
||||
|
||||
/**
|
||||
* The function retains diagnostic information for a given Thread Router.
|
||||
*
|
||||
* @param[in] aRouterId The router ID or RLOC16 for a given router.
|
||||
* @param[out] aRouterInfo A pointer to where the router information is placed.
|
||||
*
|
||||
*/
|
||||
ThreadError otGetRouterInfo(uint16_t aRouterId, otRouterInfo *aRouterInfo);
|
||||
|
||||
/**
|
||||
* Get the Stable Network Data Version.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user