80 #define OID(name, ...) \ 81 static uint32_t name[] = { __VA_ARGS__, -1 }; 90 #define MIB_RESOURCE(name, handler, ...) \ 91 uint32_t name##_oid[] = { __VA_ARGS__, -1 }; \ 92 snmp_mib_resource_t name = { NULL, name##_oid, handler }; An implementation of the Simple Network Management Protocol (RFC 3411-3418)
void(* snmp_mib_resource_handler_t)(snmp_varbind_t *varbind, uint32_t *oid)
The MIB resource handler typedef.
void snmp_api_set_string(snmp_varbind_t *varbind, uint32_t *oid, char *string)
Function to set a varbind with a string.
void snmp_api_add_resource(snmp_mib_resource_t *new_resource)
Function to add a new resource.
void snmp_api_set_time_ticks(snmp_varbind_t *varbind, uint32_t *oid, uint32_t integer)
Function to set a varbind with a time tick.
uint32_t * oid
A array that represents the OID.
An implementation of the Simple Network Management Protocol (RFC 3411-3418)
void snmp_api_set_oid(snmp_varbind_t *varbind, uint32_t *oid, uint32_t *ret_oid)
Function to set a varbind with a oid.