Cyberpower Serial Protocol

Add a true Serial Port to the Cyberpower UPS!
Post Reply
jmayes
Site Admin
Posts: 9
Joined: Sat Sep 21, 2019 6:48 pm

Cyberpower Serial Protocol

Post by jmayes »

CyberPower UPS Network card internal serial protocol

Serial Setup: 2400 Baud, No Parity, 8 Bits, 1 Stop bit. (2400,N,8,1)

Commands sent to the UPS must end with x0D (CR)

Data responses start with “#” and end with x0D (CR)

Basic UPS Commands

Command to UPS (Add CR,x0D) Result
T self test
S(0x2E)1R9999 Sleep
W(0x2E)1 Wake up
S(0x2E)1 turn off now
TL Deep battery test
CT Cancel deep battery test
S(x2E)1R0000 reboot now
S03R0003 Reboot in 3 (minutes)
S03 Shutdown in 3 minutes
C Cancel reboot or shutdown
C7:1 Turn buzzer on
D # I116.0 O116.0 L000 B100 F060.0 R100 S€%À€€ (Spaces added for readability)
Unrecognized cmds #-3 (error)
Everything above is pretty self evident the “(0x2E)” is the hex 2E char that needs to be inserted. The “D” command provides all the dynamic data from the UPS. The UPS will NOT push any data, you must poll the UPS (every 3 seconds works nicely) using the D command to receive the data. Next you must parse the received data watching for the identifiers which are again plain English I,O,L,B,F,R,S the last 5 bytes of data are the on/off flags that provide on/off online/offline, etc status. See the tables below.

“D” command breakdown

#I116.0O116.0L000B100F060.0R100S€%À€€ (37 bytes total)
Identifier Typical Data Bytes Description
# 0 Start Char
I 116.0 5 Input Volts
O 116.0 5 Output Volts
L 000 3 Load %
B 100 3 Battery %
F 060.0 5 Freq Hz
R 030 3 Run Time Minutes
S €%À€€ 5 Status Bits
The 5 status bits of the “D” string indicate various on/off conditions of the UPS such as on-line, line failure, running, etc. Most of the bits stay static, the only meat I found was in the first two bytes and is detailed below. If anyone finds more information please email and I will update the page.

The normal running online state of the status bits (In Hex) are 0x80,0x84,0xC0,0x88,0x80

Status Bytes 1 & 2 Definitions

Byte-Bit Normal State Description
s1-1 0 ?
s1-2 0 ?
s1-4 0 ?
s1-8 0 ?
s1-16 0 UPS Good = 0
s1-32 0 Line Fail = 1
s1-64 0 Batt Low = 1 (Immanent Fail)
s1-128 1 UPS Testing = 0
s2-1 0 ?
s2-2 0 ?
s2-4 1 UPS Running = 0
s2-8 0 ?
s2-16 0 ?
s2-32 0 ?
s2-64 0 ?
s2-128 1 ?
There are additional commands to read out static info from the UPS such as Model, Serial#, Load rating, Etc. I did not need any of this info for my project so this is not a complete reference, again if anyone can add to this you are welcome to email me your results and I will update this page as needed.

Static Info Commands

CMD RESULT Comments
P1 #12,140,90,10,300 ?
P2 #0500,0300,120,057,063 VA, W, V,min fq, max fq
P3 #06.0,2×1,007.0,00 ?
P4 #OR500LCDRM1U,BF00701ICM1,000000000000,CyberPower Model, Firmware, ?, Manf
P5 #120 ? (3 responses)
P6 #140 Min volts?
P7 #90 Max Volts?
P8 #10,20,30,40,50,60,70,80,90 ?
P9 #Çð ? (Bits/Flags)
Post Reply