Perhaps someone else could confirm this, I have an APC UPS with a built-in
network management card with environmental sensor for temp/humidity. The OID
index for the sensors appears to be .1 (the last component for each of the OIDs
listed below). The original source code has them at .0
drivers/apccmib.h
#define APCC_OID_IEM_TEMP ".1.3.6.1.4.1.318.1.1.10.2.3.2.1.4.1"
#define APCC_OID_IEM_TEMP_UNIT ".1.3.6.1.4.1.318.1.1.10.2.3.2.1.5.1"
#define APCC_IEM_FAHRENHEIT 2
#define APCC_OID_IEM_HUMID ".1.3.6.1.4.1.318.1.1.10.2.3.2.1.6.1"
The snmp-ups.c code has a simple logic bug that causes the temperature
APCC_OID_IEM_TEMP to not be utilized, even so it was able to obtain the
temperature value using the OID APCC_OID_IEM_TEMP.
--- nut-2.2.0/drivers/snmp-ups.c.orig 2008-09-07 22:47:06.000000000 -0400
+++ nut-2.2.0/drivers/snmp-ups.c 2008-09-07 22:47:30.000000000 -0400
@@ -800,6 +800,8 @@
/* no response, or units == F */
if ((su == FALSE) || (units == APCC_IEM_FAHRENHEIT))
temp = (value - 32) / 1.8;
+ else
+ temp=value;
}
else {
temp=value;
Steffen
________________________________
Steffen Plotner
Systems Administrator/Programmer
Systems & Networking
Amherst College
PO BOX 5000
Amherst, MA 01002-5000
Tel (413) 542-2348
Fax (413) 542-2626
Email: swplotner at amherst.edu
________________________________
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://lists.alioth.debian.org/pipermail/nut-upsdev/attachments/20080907/e5b4f47f/attachment.htm
> Perhaps someone else could confirm this, I have an APC UPS with a built-in > network management card with environmental sensor for temp/humidity. The > OID index for the sensors appears to be .1 (the last component for each of > the OIDs listed below). The original source code has them at .0I don't use the nut code for our APC temperature probes, but I can confirm that I'm grabbing the value of PowerNet-MIB::iemStatusProbeCurrentTemp.1 to feed into rrdtool. -- Dr George D M Ross, School of Informatics, University of Edinburgh 10 Crichton Street, Edinburgh, Scotland, EH8 9AB Mail: gdmr at inf.ed.ac.uk Voice: +44 131 650 5147 Fax: +44 131 650 6899 PGP: 1024D/AD758CC5 B91E D430 1E0D 5883 EF6A 426C B676 5C2B AD75 8CC5 The University of Edinburgh is a charitable body, registered in Scotland, with registration number SC005336. -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 236 bytes Desc: not available Url : http://lists.alioth.debian.org/pipermail/nut-upsdev/attachments/20080908/5255ab4b/attachment.pgp