Golioth Firmware SDK
golioth_debug.h File Reference
#include "golioth_config.h"
#include "golioth_time.h"
#include <stdbool.h>

Go to the source code of this file.

Macros

#define __UNUSED
 
#define LOG_TAG_DEFINE(tag)   static __UNUSED const char* TAG = #tag
 

Typedefs

typedef void * golioth_client_t
 

Enumerations

enum  golioth_debug_log_level_t {
  GOLIOTH_DEBUG_LOG_LEVEL_NONE , GOLIOTH_DEBUG_LOG_LEVEL_ERROR , GOLIOTH_DEBUG_LOG_LEVEL_WARN , GOLIOTH_DEBUG_LOG_LEVEL_INFO ,
  GOLIOTH_DEBUG_LOG_LEVEL_DEBUG , GOLIOTH_DEBUG_LOG_LEVEL_VERBOSE
}
 

Functions

void golioth_debug_set_log_level (golioth_debug_log_level_t level)
 
golioth_debug_log_level_t golioth_debug_get_log_level (void)
 
void golioth_debug_hexdump (const char *tag, const void *addr, int len)
 
void golioth_debug_set_client (golioth_client_t client)
 
void golioth_debug_set_cloud_log_enabled (bool enable)
 
void golioth_debug_printf (uint64_t tstamp_ms, golioth_debug_log_level_t level, const char *tag, const char *format,...)
 

Macro Definition Documentation

◆ __UNUSED

#define __UNUSED

Definition at line 11 of file golioth_debug.h.

◆ LOG_TAG_DEFINE

#define LOG_TAG_DEFINE (   tag)    static __UNUSED const char* TAG = #tag

Definition at line 16 of file golioth_debug.h.

Typedef Documentation

◆ golioth_client_t

typedef void* golioth_client_t

Definition at line 19 of file golioth_debug.h.

Enumeration Type Documentation

◆ golioth_debug_log_level_t

Enumerator
GOLIOTH_DEBUG_LOG_LEVEL_NONE 
GOLIOTH_DEBUG_LOG_LEVEL_ERROR 
GOLIOTH_DEBUG_LOG_LEVEL_WARN 
GOLIOTH_DEBUG_LOG_LEVEL_INFO 
GOLIOTH_DEBUG_LOG_LEVEL_DEBUG 
GOLIOTH_DEBUG_LOG_LEVEL_VERBOSE 

Definition at line 21 of file golioth_debug.h.

Function Documentation

◆ golioth_debug_get_log_level()

golioth_debug_log_level_t golioth_debug_get_log_level ( void  )

◆ golioth_debug_hexdump()

void golioth_debug_hexdump ( const char *  tag,
const void *  addr,
int  len 
)

◆ golioth_debug_printf()

void golioth_debug_printf ( uint64_t  tstamp_ms,
golioth_debug_log_level_t  level,
const char *  tag,
const char *  format,
  ... 
)

◆ golioth_debug_set_client()

void golioth_debug_set_client ( golioth_client_t  client)

◆ golioth_debug_set_cloud_log_enabled()

void golioth_debug_set_cloud_log_enabled ( bool  enable)

◆ golioth_debug_set_log_level()

void golioth_debug_set_log_level ( golioth_debug_log_level_t  level)