search for: _initv

Displaying 2 results from an estimated 2 matches for "_initv".

Did you mean: _init
2006 Nov 26
1
Patch for optiups to support Zinto D from ONLINE USV-Systeme AG
...V", "output.voltage", 2.0 }, + { "OF", "output.frequency", 0.1 }, + { "NF", "input.frequency", 0.1 }, + { "BT", "ups.temperature" }, +}; /* model "IO" is parsed differently in upsdrv_initinfo() */ static ezfill _initv[] = { @@ -105,6 +117,10 @@ r=-2; upsdebugx(1, "READ: <unsupported command>"); } + if ( _buf[0] == 0x06 ) + { + upsdebugx(2, "READ: <command done>"); + } else { upsdebugx(2, "READ: \"%s\"", _buf ); @@ -125,6 +141,7 @@ {...
2011 Oct 03
2
patch: Replace many usleep and some sleep calls with nanosleep
...MGE_REPLY_ENDCHAR, MGE_REPLY_IGNCHAR, 3, 0); Index: b/drivers/optiups.c =================================================================== --- a/drivers/optiups.c 2011-05-31 13:36:49.000000000 +0300 +++ b/drivers/optiups.c 2011-08-17 00:40:17.000000000 +0300 @@ -133,7 +133,7 @@ static ezfill_t _initv[] = { static inline int optireadline(void) { int r; - usleep(150000); + struct timespec delay = {0, 150e6}; nanosleep(&delay, NULL); r = ser_get_line(upsfd, _buf, sizeof(_buf), ENDCHAR, IGNCHARS, 0, 500000 ); _buf[sizeof(_buf)-1] = 0; if ( r > 0 ) Index: b/drivers/powerp-bin.c ====...