ofysctl

Name

ofysctl -- manage Socomec/Sicon Ofys UPS

Synopsis

ofysctl [-Dttydevice] [-?hvqausiobefrtnlBQ] [-S [-E]] [-T[hh:mm:ss,day]] [-N[hh:mm,day]] [-Ls]

DESCRIPTION

ofysctl manages Socomec/Sicon Ofys UPS.

ofysctl allows to check the status of the UPS, and to set a power-on timer, a stand-by timeout, to test the battery and to silent the buzzer.

It assumes the UPS is connected to a serial port. Default port device is chosen at compile time, usually /dev/ttyS0. A different port may be specified in OFYSTTY environment variable or through the -D command line option.

See README file in the documentation directory for informations anout the serial cable.

OPTIONS

One letter parameters can be specified separately or grouped together with one leading dash.

General options

-h, -?

Show summary of options.

-Dttydevice

Specify that the UPS device is connected to ttydevice. Default is chosen at compile time, usually /dev/ttyS0. This option overrides the value specified in OFYSTTY environment variable.

-v

Increase verbosity.

-q

Decrese verbosity

Status options

-a

Display all available infomations. Implies -usiobefrtnl options.

-u

Display UPS version. This is a string provided by the device.

-s

Display UPS status. It includes informations about the input voltage and the inverter status.

-i

Display input voltage.

-o

Display battery voltage.

-b

Display battery charge.

-e

Display UPS internal temperature. Since version 3.0 of the UPS firmware this value is fixed to 27° C.

-f

Display input frequency.

-r

Display output frequency (50 or 60 Hz).

-t

Display UPS clock (hh:mm:ss,day of the week). Set this value with -T option.

-n

Display scheduled power-on time (hh:mm,day of the week). Set this value with -N option.

-l

Display stant-by delay time. This is the time the UPS waits before going in stan-by mode after receiving the shutdown command (-S option). Set this value with -L option.

Control options

-T[hh:mm:ss,day]

Set UPS clock. Syncronizes it with system clock, if no value given; otherwise uses hh:mm:ss,day, where the four values are respectively hours, minutes, seconds and the day of the week in numerical form (1=Monday, 7=Sunday).

-N[hh:mm,day]

Set power-on time. When the UPS clock matches power-on time, the UPS changes from stand-by mode to operating mode. The UPS power-on time is clear if no value is given on the command line, otherwise uses [hh:mm,day], where the three values are respectively hours, minutes and the day of the week in numerical form (1=Monday, 7=Sunday).

-Ls

Set stand-by delay time to s. This is the time the UPS waits before going in stan-by mode after receiving the shutdown command (-S option).

-B

Battery test. Go in battery mode for a few seconds.

-Q

Silent buzzer. Effective in battery mode or in case of low battery charge.

-S

Go to stand-by after the progammed delay (see -l and -L option). If the delay is 0, go stand-by immediately. To make the UPS go back on-line when the power comes back, see -L option. WARNING: all appliances connected to the UPS output will be turned off!!!!

-E

Used with -S option makes the UPS go back on-line when the power comes back.

ENVIRONMENT

OFYSTTY

If defined, ofysctl will use that tty device instead of the default one. It is overridden by the -D option.

COPYRIGHT

This software is released under the terms of the GNU General Public License.

See COPYING file in documentation directory.

AUTHOR

Written by Ludovico Cavedon .

BUG REPORTS

Report bugs to Ludovico Cavedon .

BUGS

The UPS needs a small delay between bytes written to its serial port. For me 2 us (microseconds) is enough. If you expericence reading timeouts, try to increase TTYDELAY value in src/common.h, and let me know, please.