lwIP  2.1.0
Lightweight IP stack

Data Structures

struct  stats_mib2_netif_ctrs
 

Macros

#define MIB2_STATS_NETIF_INC(n, x)   do { ++(n)->mib2_counters.x; } while(0)
 
#define MIB2_STATS_NETIF_ADD(n, x, val)   do { (n)->mib2_counters.x += (val); } while(0)
 
#define MIB2_INIT_NETIF(netif, type, speed)
 

Enumerations

enum  snmp_ifType
 

Detailed Description

Macro Definition Documentation

◆ MIB2_INIT_NETIF

#define MIB2_INIT_NETIF (   netif,
  type,
  speed 
)
Value:
do { \
(netif)->link_type = (type); \
(netif)->link_speed = (speed);\
(netif)->ts = 0; \
(netif)->mib2_counters.ifinucastpkts = 0; \
(netif)->mib2_counters.ifindiscards = 0; \
(netif)->mib2_counters.ifinunknownprotos = 0; \
(netif)->mib2_counters.ifoutucastpkts = 0; \
(netif)->mib2_counters.ifoutdiscards = 0; \
(netif)->mib2_counters.ifouterrors = 0; } while(0)
u32_t ifoutoctets
Definition: stats.h:212
u32_t ifinnucastpkts
Definition: stats.h:194
u8_t link_type
Definition: netif.h:361
u32_t ts
Definition: netif.h:365
u32_t ifouterrors
Definition: stats.h:228
u32_t ifoutnucastpkts
Definition: stats.h:220
Definition: netif.h:260
u32_t link_speed
Definition: netif.h:363
u32_t ifinerrors
Definition: stats.h:203
struct stats_mib2_netif_ctrs mib2_counters
Definition: netif.h:367
u32_t ifinoctets
Definition: stats.h:188

Init MIB2 statistic counters in netif

Parameters
netifNetif to init
typeone of enum snmp_ifType
speedyour link speed here (units: bits per second)

◆ MIB2_STATS_NETIF_ADD

#define MIB2_STATS_NETIF_ADD (   n,
  x,
  val 
)    do { (n)->mib2_counters.x += (val); } while(0)

Add value to stats member for SNMP MIB2 stats (struct stats_mib2_netif_ctrs)

◆ MIB2_STATS_NETIF_INC

#define MIB2_STATS_NETIF_INC (   n,
 
)    do { ++(n)->mib2_counters.x; } while(0)

Increment stats member for SNMP MIB2 stats (struct stats_mib2_netif_ctrs)

Enumeration Type Documentation

◆ snmp_ifType

See also
RFC1213, "MIB-II, 6. Definitions"