I have designed a program which sends a get request to a device
This returns integer values which when compare with the MIB file, are correct.
However I would like the program to return the String value of the request OID.
In the java API for SNMP4J there are functions which look like they do what I'm requesting but I've tried these and to no avail.
Here is some code -
so if I tryCode :
oid = new OID(OidArray[z]); } VariableBinding vb = new VariableBinding(oid); Pdu = new PDU(); Pdu.add(vb);
None of these work and returned null.Code :
vb.toString(); //Or this vb.toValueString();
eg - oid = 220.127.116.11.18.104.22.168.3.44.0 returns - 22.214.171.124.126.96.36.199.3.44.0 = 4
and 4 in the MIB file is QPSK which is the string value i would like returned
Thanks for your help