Displaying 9 results from an estimated 9 matches for "ignchar".
Did you mean:
ignchars
2007 Feb 01
2
Re: [Nut-upsuser] Ablerex 625L USB version
...*****
> *** 243,251 ****
> char buffer[RECV_BUFFER_LEN];
> int ret;
>
> ! upsdebugx(2, "Sending \"Q1\" command...");
> ! comm->send("Q1%c", ENDCHAR);
> ret = comm->recv(buffer, RECV_BUFFER_LEN, ENDCHAR, IGNCHARS);
> if (ret < Q1_CMD_REPLY_LEN) {
> upsdebugx(2, "Wrong answer to \"Q1\" command.");
>
> --- 243,253 ----
> char buffer[RECV_BUFFER_LEN];
> int ret;
>
> ! upsdebugx(2, "check_ups: Sending \"...
2006 Dec 05
3
megatec over USB - new driver patch
...3,14 @@
return value * 100;
}
-
static int check_ups(void)
{
char buffer[RECV_BUFFER_LEN];
int ret;
upsdebugx(2, "Sending \"F\" command...");
- ser_send_pace(upsfd, SEND_PACE, "F%c", ENDCHAR);
- ret = ser_get_line(upsfd, buffer, RECV_BUFFER_LEN, ENDCHAR, IGNCHARS, READ_TIMEOUT, 0);
+ comm->send("F%c", ENDCHAR);
+ ret = comm->recv(buffer, RECV_BUFFER_LEN, ENDCHAR, IGNCHARS);
if (ret < F_CMD_REPLY_LEN) {
upsdebugx(2, "Wrong answer to \"F\" command.");
@@ -195,8 +189,8 @@
upsdebugx(2, "\"F\" comma...
2011 Mar 05
19
[RFC apcsmart V3 00/18] apcsmart driver updates
Sorry for a bit longer delay than I anticipated, I was stuffed with the work.
This is the next iteration of the patch adding some functionality to apcsmart
driver, and relying on 'ignorelb' recently added.
Follow up from previous thread:
http://www.mail-archive.com/nut-upsdev at lists.alioth.debian.org/msg02331.html
Main differences is that V3 is split into many small patches, so the
2010 Apr 19
1
Patch for the bestfortress driver 0.02
...);
upssend ("f\r");
+ while (ser_get_char(upsfd, &ch, 0, UPSDELAY) > 0 && ch != '\n'); // response starts with \r\n
+ temp[2] = 0;
do {
- if (upsrecv (temp+2, sizeof temp - 2, ENDCHAR, IGNCHARS) <= 0) {
+ if ((len = upsrecv (temp+2, sizeof temp - 2, ENDCHAR, IGNCHARS)) <= 0) {
upsflushin (0, 0, "\r ");
upssend ("f\r");
+ while (ser_get_char(upsfd,...
2011 Jan 25
1
[RFC] Updates to ACP smart driver
This patch introduces a handful of new options, I mentioned earlier in:
http://www.mail-archive.com/nut-upsdev at lists.alioth.debian.org/msg02088.html
See the large commit message in the follow-up for the details and rationale.
I realize it's a bit larger diff - so if it's required I can split it into few
smaller ones.
Michal Soltys (1):
APC smart driver update and new features.
2011 Feb 07
4
[PATCH/RFC v2 0/3] Updates to ACP smart driver
This is 2nd version of the earlier patch featuring a few new features
and fixes to the apcsmart driver, following the remarks in:
http://www.mail-archive.com/nut-upsdev at lists.alioth.debian.org/msg02294.html
Major changes from v1:
- handle battery.charge and battery.runtime checks at main.c level
- handle "immutable but writable" conflict gracefully at driver level
-
2011 Oct 03
2
patch: Replace many usleep and some sleep calls with nanosleep
...ivers/victronups.c
===================================================================
--- a/drivers/victronups.c 2011-05-31 13:36:49.000000000 +0300
+++ b/drivers/victronups.c 2011-08-17 03:09:10.000000000 +0300
@@ -49,8 +49,8 @@ upsdrv_info_t upsdrv_info = {
#define ENDCHAR '\r'
#define IGNCHARS "\n"
-#define UPS_DELAY 150000
-#define UPS_LONG_DELAY 450000
+#define UPS_DELAY 150e6
+#define UPS_LONG_DELAY 450e6
#define VICTRON_OVER 128
#define VICTRON_RB 1
@@ -86,7 +86,7 @@ static int get_data (const char *out_str
{
int ret_code;
ser_send(upsfd, "%s%c", out_s...
2008 Jul 10
2
[PATCH] tripplite driver updates
...rver/upscmd.cpp, formerly (but not longer) available from
+ Tripp Lite at http://www.tripplite.com/linux/.
*/
/* REFERENCE 2
@@ -111,30 +111,6 @@
#include <math.h>
#include <ctype.h>
-#define ENDCHAR '\n' /* replies end with CR LF -- use LF to end */
-#define IGNCHAR '\r' /* ignore CR */
-#define MAXTRIES 3
-#define SER_WAIT_SEC 3 /* allow 3.0 sec for ser_get calls */
-#define SER_WAIT_USEC 0
-#define DEFAULT_OFFDELAY 64 /* seconds (max 0xFF) */
-#define DEFAULT_STARTDELAY 60 /* seconds (max 0xFFFFFF) */
-#define DEFAULT_BOOTDELAY...
2009 Aug 14
2
Bestfortress driver, network serial patch for nut-2.0
...is optional
anything else is mandatory
*/
#include "main.h"
#include "serial.h"
#define UPSDELAY 50000 /* 50 ms delay required for reliable operation */
#define SER_WAIT_SEC 2 /* allow 2.0 sec for ser_get calls */
#define SER_WAIT_USEC 0
#define ENDCHAR '\r'
#define IGNCHARS " \n"
#if defined(__sgi) && ! defined(__GNUC__)
#define inline __inline
#endif
static int instcmd (const char *cmdname, const char *extra);
static int upsdrv_setvar (const char *varname, const char *val);
/* rated VA load if known */
static int maxload = 0;
void upsdr...