1UPSCLI_SENDLINE(3)                NUT Manual                UPSCLI_SENDLINE(3)
2
3
4

NAME

6       upscli_sendline - send a single command to a UPS
7

SYNOPSIS

9       #include <upsclient.h>
10
11       int upscli_sendline(UPSCONN_t *ups, const char *buf, size_t buflen);
12

DESCRIPTION

14       The upscli_sendline() function takes the pointer ups to a UPSCONN_t
15       state structure and transmits a buffer buf of size buflen to the
16       server.
17
18       The data in buf must be a fully formatted protocol command as no
19       parsing of the buffer occurs within this function.
20

RETURN VALUE

22       The upscli_sendline() function returns 0 on success, or -1 if an error
23       occurs.
24

SEE ALSO

26       upscli_fd(3), upscli_get(3), upscli_readline(3), upscli_sendline(3),
27       upscli_ssl(3), upscli_strerror(3), upscli_upserror(3)
28
29
30
31Network UPS Tools                 09/15/2011                UPSCLI_SENDLINE(3)
Impressum