Skip to main content

otGetLogLevel

Function otGetLogLevel 

Source
pub unsafe extern "C" fn otGetLogLevel(
    aInstance: *mut otInstance,
) -> otLogLevel
Expand description

Returns the current log level for a given OpenThread instance.

If dynamic log level feature OPENTHREAD_CONFIG_LOG_LEVEL_DYNAMIC_ENABLE is enabled, this function returns the currently set dynamic log level:

  • In a single-instance configuration, it returns the instance’s log level.
  • In a multi-instance configuration, it returns the instance-specific log level if it has been explicitly set (see otSetLogLevel()). Otherwise, it returns the global log level (see otLoggingGetLevel()).

If the dynamic log level feature is not enabled, this function returns the build-time configured log level.

@param[in] aInstance The OpenThread instance.

@returns The log level.