tfProcessInt valid values for varValType

I am starting to use the SNMP agent. To set an OID object value from other parts of the application the app calls tfset_XXX where XXX is the group of the oid tree. This in turn calls tfProcessInt. This function takes a varValType argument. What are the valid values for varValType? I assume there is some enum or #define for this? More generally where can I find the supporting document for this and other SNMP calls (to Treck). I looked for it in Treck documentation and was unable to find it. I found the signature for the call(s) but no explicit API documentation.



i think it can be either TM_SNMP_STRING or TM_SNMP_INTEGER
by looking at the C:
amib\ and some other examples it does not seem like you need to worry about setting varValType.
here is another example that calls this function:
extern int tfProcessInt(u_char *, int *, u_char *, long *);

u_char *tfvar_character(
struct tsSnmpVariable *vp, oid *name,
int *length, int exact, int *var_len,
int (**write_method)(int action, u_char *var_val,
u_char var_val_type, int var_val_len, oid *name, int length),
int (**create_method)(oid *index, int index_length, oid status),
int (**delete_method)(oid *index, int index_length))

if (var_val_type == TM_SNMP_INTEGER)

else if (var_val_type == TM_SNMP_STRING)

        if ((err = tfProcessInt(var_val, var_val_len, &var_val_type, &intp))
               != TM_SNMP_ERR_NOERROR)
            goto exitFunction;

Thanks Leonid,

I will have data coming in from the serial port on a separate thread that will populate the MIB Object.
So on a related note:

  1. Is this tfProcessint() method of updating the MIB variable thread safe?
  2. Is this the accepted/suggested method of updating the MIB variable from user application threads or should I be using a different method?
  3. In lieu of the above can I just grab a node pointer to the MIB object and modify it directly?
  4. Should I create my own semaphore and add locking to the application on my own?

Ref From Digi Document:
Section 3.5 Theory of Operation
“Device data is your data.”

Thanks in advance.