VMUPro SDK v1.0.0
Application Development SDK for the VMUPro
Loading...
Searching...
No Matches
vmupro_log.h File Reference

VMUPro Logging API. More...

Go to the source code of this file.

Enumerations

enum  vmupro_log_level_t {
  VMUPRO_LOG_NONE = 0 , VMUPRO_LOG_ERROR , VMUPRO_LOG_WARN , VMUPRO_LOG_INFO ,
  VMUPRO_LOG_DEBUG
}
 Log level enumeration. More...
 

Functions

void vmupro_set_log_level (vmupro_log_level_t level)
 Set the global log level.
 
void vmupro_log (vmupro_log_level_t level, const char *tag, const char *fmt,...)
 Output a formatted log message.
 

Detailed Description

VMUPro Logging API.

This header provides the logging API for the VMUPro SDK. It includes functions for setting log levels and outputting formatted log messages with different severity levels.

Author
8BitMods
Version
1.0.0
Date
2025-06-17

Definition in file vmupro_log.h.

Enumeration Type Documentation

◆ vmupro_log_level_t

Log level enumeration.

Defines the different logging levels available in the VMUPro SDK. Higher values indicate more verbose logging.

Enumerator
VMUPRO_LOG_NONE 

No logging output

VMUPRO_LOG_ERROR 

Error level - critical issues

VMUPRO_LOG_WARN 

Warning level - potential issues

VMUPRO_LOG_INFO 

Info level - general information

VMUPRO_LOG_DEBUG 

Debug level - detailed debug information

Definition at line 28 of file vmupro_log.h.

Function Documentation

◆ vmupro_log()

void vmupro_log ( vmupro_log_level_t  level,
const char *  tag,
const char *  fmt,
  ... 
)

Output a formatted log message.

Outputs a formatted log message with the specified level and tag. The message will only be output if the level is greater than or equal to the current global log level.

Parameters
levelThe log level for this message
tagA string tag to identify the source of the log message
fmtPrintf-style format string
...Variable arguments for the format string
Examples
/home/runner/work/vmupro-sdk/vmupro-sdk/sdk/include/vmupro_display.h.

◆ vmupro_set_log_level()

void vmupro_set_log_level ( vmupro_log_level_t  level)

Set the global log level.

Sets the minimum log level for output. Messages with a level lower than the set level will be filtered out.

Parameters
levelThe minimum log level to output