Displaying 1 result from an estimated 1 matches for "involt_min".
Did you mean:
involt_max
2008 Jul 10
2
[PATCH] tripplite driver updates
...n);
+ dstate_datastale();
+ return;
+ }
+
+ volt = hex2d(buf + 2, 2);
+ temp = (int)(hex2d(buf + 6, 2)*0.3636 - 21.0);
+ load = hex2d(buf + 12, 2);
+ freq = hex2d(buf + 18, 3) / 10.0;
+ bcond = buf[0];
+ lstate = buf[1];
+ tstate = buf[4];
+ mode = buf[5];
+ if (volt > INVOLT_MAX || volt < INVOLT_MIN ||
+ temp > TEMP_MAX || temp < TEMP_MIN ||
+ load > LOAD_MAX || load < LOAD_MIN ||
+ freq > FREQ_MAX || freq < FREQ_MIN) {
+ ser_comm_fail("Data out of bounds: [%0d,%3d,%3d,%02.2f]",
+ volt, temp, load, freq);
+ dstate_datastale();
+ return;
+ }
+
+ send_cmd(...