liblightmodbus 3.0
A lightweight, header-only, hardware-agnostic Modbus RTU/TCP library
Loading...
Searching...
No Matches
debug.impl.h File Reference

Debug utilities (implementation) More...

#include "debug.h"
+ Include dependency graph for debug.impl.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define ESTR(x)   [(int)(x)] = #x
 Defines a field in array holding name of the enum value.
 
#define ECASE(x)   case (int)(x): return #x; break;
 Defines a case halding enum value, returning the name of the enum value.
 

Functions

const char * modbusErrorStr (ModbusError err)
 Returns a string containing the name of the ModbusError value.
 
const char * modbusErrorSourceStr (uint8_t src)
 Returns a string containing the name error source.
 
const char * modbusExceptionCodeStr (ModbusExceptionCode code)
 Returns a string containing the name of the ModbusExceptionCode enum value.
 
const char * modbusDataTypeStr (ModbusDataType type)
 Returns a string containing the name of the ModbusDataType enum value.
 
const char * modbusRegisterQueryStr (ModbusRegisterQuery query)
 Returns a string containing the name of the ModbusRegisterQuery enum value.
 

Detailed Description

Debug utilities (implementation)

Macro Definition Documentation

◆ ECASE

#define ECASE (   x)    case (int)(x): return #x; break;

Defines a case halding enum value, returning the name of the enum value.

◆ ESTR

#define ESTR (   x)    [(int)(x)] = #x

Defines a field in array holding name of the enum value.

Function Documentation

◆ modbusDataTypeStr()

const char * modbusDataTypeStr ( ModbusDataType  type)

Returns a string containing the name of the ModbusDataType enum value.

◆ modbusErrorSourceStr()

const char * modbusErrorSourceStr ( uint8_t  src)

Returns a string containing the name error source.

◆ modbusErrorStr()

const char * modbusErrorStr ( ModbusError  err)

Returns a string containing the name of the ModbusError value.

+ Here is the caller graph for this function:

◆ modbusExceptionCodeStr()

const char * modbusExceptionCodeStr ( ModbusExceptionCode  code)

Returns a string containing the name of the ModbusExceptionCode enum value.

◆ modbusRegisterQueryStr()

const char * modbusRegisterQueryStr ( ModbusRegisterQuery  query)

Returns a string containing the name of the ModbusRegisterQuery enum value.