Represents the Thread MLE counters.

Public Attributes#

uint16_t

Number of times device entered OT_DEVICE_ROLE_DISABLED role.

uint16_t

Number of times device entered OT_DEVICE_ROLE_DETACHED role.

uint16_t

Number of times device entered OT_DEVICE_ROLE_CHILD role.

uint16_t

Number of times device entered OT_DEVICE_ROLE_ROUTER role.

uint16_t

Number of times device entered OT_DEVICE_ROLE_LEADER role.

uint16_t

Number of attach attempts while device was detached.

uint16_t

Number of changes to partition ID.

uint16_t

Number of attempts to attach to a better partition.

uint64_t

Role time tracking.

uint64_t

Number of milliseconds device has been in OT_DEVICE_ROLE_DETACHED role.

uint64_t

Number of milliseconds device has been in OT_DEVICE_ROLE_CHILD role.

uint64_t

Number of milliseconds device has been in OT_DEVICE_ROLE_ROUTER role.

uint64_t

Number of milliseconds device has been in OT_DEVICE_ROLE_LEADER role.

uint64_t

Number of milliseconds tracked by previous counters.

uint16_t

Number of times device changed its parent.

Public Attribute Documentation#

mDisabledRole#

uint16_t otMleCounters::mDisabledRole

Number of times device entered OT_DEVICE_ROLE_DISABLED role.


mDetachedRole#

uint16_t otMleCounters::mDetachedRole

Number of times device entered OT_DEVICE_ROLE_DETACHED role.


mChildRole#

uint16_t otMleCounters::mChildRole

Number of times device entered OT_DEVICE_ROLE_CHILD role.


mRouterRole#

uint16_t otMleCounters::mRouterRole

Number of times device entered OT_DEVICE_ROLE_ROUTER role.


mLeaderRole#

uint16_t otMleCounters::mLeaderRole

Number of times device entered OT_DEVICE_ROLE_LEADER role.


mAttachAttempts#

uint16_t otMleCounters::mAttachAttempts

Number of attach attempts while device was detached.


mPartitionIdChanges#

uint16_t otMleCounters::mPartitionIdChanges

Number of changes to partition ID.


mBetterPartitionAttachAttempts#

uint16_t otMleCounters::mBetterPartitionAttachAttempts

Number of attempts to attach to a better partition.


mDisabledTime#

uint64_t otMleCounters::mDisabledTime

Role time tracking.

When uptime feature is enabled (OPENTHREAD_CONFIG_UPTIME_ENABLE = 1) time spent in each MLE role is tracked. Number of milliseconds device has been in OT_DEVICE_ROLE_DISABLED role.


mDetachedTime#

uint64_t otMleCounters::mDetachedTime

Number of milliseconds device has been in OT_DEVICE_ROLE_DETACHED role.


mChildTime#

uint64_t otMleCounters::mChildTime

Number of milliseconds device has been in OT_DEVICE_ROLE_CHILD role.


mRouterTime#

uint64_t otMleCounters::mRouterTime

Number of milliseconds device has been in OT_DEVICE_ROLE_ROUTER role.


mLeaderTime#

uint64_t otMleCounters::mLeaderTime

Number of milliseconds device has been in OT_DEVICE_ROLE_LEADER role.


mTrackedTime#

uint64_t otMleCounters::mTrackedTime

Number of milliseconds tracked by previous counters.


mParentChanges#

uint16_t otMleCounters::mParentChanges

Number of times device changed its parent.

A parent change can happen if device detaches from its current parent and attaches to a different one, or even while device is attached when the periodic parent search feature is enabled (please see option OPENTHREAD_CONFIG_PARENT_SEARCH_ENABLE).