mikroSDK Reference Manual
udp_mib_module.h
Go to the documentation of this file.
1
31#ifndef _UDP_MIB_MODULE_H
32#define _UDP_MIB_MODULE_H
33
34//Dependencies
35#include "mibs/mib_common.h"
36
37//UDP MIB module support
38#ifndef UDP_MIB_SUPPORT
39 #define UDP_MIB_SUPPORT DISABLED
40#elif (UDP_MIB_SUPPORT != ENABLED && UDP_MIB_SUPPORT != DISABLED)
41 #error UDP_MIB_SUPPORT parameter is not valid
42#endif
43
44//Macro definitions
45#if (UDP_MIB_SUPPORT == ENABLED)
46 #define UDP_MIB_INC_COUNTER32(name, value) udpMibBase.name += value
47 #define UDP_MIB_INC_COUNTER64(name, value) udpMibBase.name += value
48#else
49 #define UDP_MIB_INC_COUNTER32(name, value)
50 #define UDP_MIB_INC_COUNTER64(name, value)
51#endif
52
53//C++ guard
54#ifdef __cplusplus
55extern "C" {
56#endif
57
58
63typedef struct
64{
65 uint32_t udpInDatagrams;
66 uint32_t udpNoPorts;
67 uint32_t udpInErrors;
68 uint32_t udpOutDatagrams;
69 uint64_t udpHCInDatagrams;
70 uint64_t udpHCOutDatagrams;
72
73
74//UDP MIB related constants
75extern UdpMibBase udpMibBase;
76extern const MibObject udpMibObjects[];
77extern const MibModule udpMibModule;
78
79//C++ guard
80#ifdef __cplusplus
81}
82#endif
83
84#endif
Common definitions for MIB modules.
MIB module.
Definition mib_common.h:288
UDP MIB base.
Definition udp_mib_module.h:64