Displaying 5 results from an estimated 5 matches for "ser_comm_fail".
2008 Jul 10
2
[PATCH] tripplite driver updates
...365,57 +352,111 @@ void upsdrv_shutdown(void)
void upsdrv_updateinfo(void)
{
char buf[256];
- int bp;
- float bv;
+ int bp, volt, temp, load, vmax, vmin, stest, len;
+ int bcond, lstate, tstate, mode;
+ float bv, freq;
+
+ len = send_cmd(":D\r", buf, sizeof buf);
+ if (len != 21) {
+ ser_comm_fail("Data command failed: [%d] bytes != 21 bytes.", len);
+ 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[...
2008 Aug 06
1
possible regression in genericups with Tripplite UPS
reported through launchpad: https://bugs.launchpad.net/bugs/253999
the possible regression is between nut 2.0.1 (sarge) and 2.2.1
(confirmed Jamie?)
@Arjen: it may be related to some of your changes there...
@Jamie: we'll need some debug output from the drivers (-DDD)
Arnaud
2014 Feb 02
2
Powerware (Eaton) Prestige 9 UPS
...sever an
error handling path.
So, if anyone is still trying, this should get you going . . .
- Tim
-- /* if (command <= 0x43) { */
if (command << 0x43) {
if ((command - 0x30) != block_number){
ser_comm_fail("Receive error (Request
command):
%x!!!\n", block_number);
return -1;
}
}
/* Dawson - Powerware Prestige is an odd reply to topology_init . . .
but works!
Fool it into thinking it got the correct block . . ....
2006 Aug 23
3
bcmxcp: stop whining (and log spamming)
...ing already.
$OpenBSD$
--- drivers/bcmxcp_ser.c.orig Wed Aug 23 11:15:54 2006
+++ drivers/bcmxcp_ser.c Wed Aug 23 11:26:37 2006
@@ -168,8 +168,8 @@ int get_answer(unsigned char *data, unsi
/* now we have the whole answer from the ups, we can checksum it */
if (!checksum_test(my_buf)) {
- ser_comm_fail("checksum error! ");
- return -1;
+ upsdebugx(2, "checksum error!");
+ return -1;
}
memcpy(data+end_length, my_buf+4, length);
--
Henning Brauer, hb@bsws.de, henning@openbsd.org
BS Web Services, http://bsws.de
OpenBSD-based Webhosting, Mail Services, Managed Se...
2008 Aug 15
2
Problem with APC and Fedora 8 I86_64
...ze_t?
serial.c: In function ?ser_send_pace?:
serial.c:259: warning: format ?%d? expects type ?int?, but argument 3 has type ?long unsigned int?
serial.c: In function ?ser_send?:
serial.c:289: warning: format ?%d? expects type ?int?, but argument 3 has type ?long unsigned int?
serial.c: In function ?ser_comm_fail?:
serial.c:511: warning: format ?%d? expects type ?int?, but argument 3 has type ?long unsigned int?
libusb.c: In function ?libusb_open?:
libusb.c:289: warning: format ?%d? expects type ?int?, but argument 4 has type ?long unsigned int?
libusb.c: In function ?libusb_get_string?:
libusb.c:376: warni...