Professional Documents
Culture Documents
蓝峰 POS通讯协议 修改版1.0
蓝峰 POS通讯协议 修改版1.0
CheckSum = NOT (Command + Data1 + … + Data9) + 1, the addition has no carry bit.
The setting of computer (PC) COM port is “9600, n, 8, 1”; the mode of input is binary; the handshaking is none.
From Computer (PC) to Dispenser (All data in the following table is Hex, ‘XX’ stands for a Hex datum, such as ‘37’):
枪号 Data1 Command Data2 Data3 Data4 Data5 Data6 Data7 Data8 Data9 CheckSum Memo
XX 00 B8 00 00 00 00 00 00 00 00 48 Query State
XX 00 A0 00 00 00 00 00 00 00 00 60 Control Dispenser
XX 00 B0 00 00 00 00 00 00 00 00 50 Uncontrol Dispenser
XX 00 A1 00 00 00 00 00 00 00 00 5F Fueling
XX 00 B1 00 00 00 00 00 00 00 00 4F Stop
XX 00 A2 XX XX XX 00 00 00 00 00 Fueling with fixed cash(1)
XX 00 A3 XX XX XX 00 00 00 00 00 Fueling with fixed liter(2)
XX 00 A4 XX XX 00 00 00 00 00 00 Setting Price(3)
XX 00 A6 XX 00 00 00 00 00 00 00 Setting Pre-valve(4)
XX 00 A8 00 00 00 00 00 00 00 00 58 Clear Shift Sum
XX 00 A9 00 00 00 00 00 00 00 00 57 Query Shift Sum
XX 00 AC 00 00 00 00 00 00 00 00 54 Query Total Cash
XX 00 AD 00 00 00 00 00 00 00 00 53 Query Total Liter
(1): The maximal value of fixed cash is 9999.99. For example, if the fixed cash is 2356.47 in decimal system, the data2, data3, and data4 will be 0x23, 0x56, and 0x47
respectively.
(2): The maximal value of fixed liter is 9999.99. For example, if the fixed liter is 9876.32 in decimal system, the data2, data3, and data4 will be 0x98, 0x76, and 0x32
respectively.
(3): The maximal value of price is 99.99. For example, if the price is 25.43 in decimal system, the data2 and data3 will be 0x25 and 0x43 respectively.
(4): The maximal value of pre-valve is 0.99. For example, if the pre-valve is 0.50 in decimal system, the data2 will be 0x50 respectively.
1
From Dispenser to Computer (PC) (All data in the following table is Hex, ‘XX’ stands for a Hex datum, such as ‘37’):
枪号 Data1 Command Data2 Data3 Data4 Data5 Data6 Data7 Data8 Data9 CheckSum Memo
Price Cash Liter State
XX 00 Query State(1)
XX XX XX XX XX XX XX XX XX
XX 00 A0 Control Dispenser
XX 00 B0 Uncontrol Dispenser
XX 00 A1 No Feedback Fueling
XX 00 B1 No Feedback Stop
XX 00 A2 No Feedback Fueling with fixed cash
XX 00 A3 No Feedback Fueling with fixed liter
XX 00 A4 No Feedback Setting Price
XX 00 A6 No Feedback Setting Pre-valve
XX 00 A8 No Feedback Clear Shift Sum
Shift Liter Sum Shift Money Sum
XX 00 A9 Query Shift Sum(2)
XX XX XX XX XX XX XX XX
XX 00 AC XX XX XX XX XX XX XX XX Query Total Cash(3)
XX 00 AD XX XX XX XX XX XX XX XX Query Total Liter(4)
(1): If the command and data2 are 0x06 and 0x43 respectively, the price will be 6.43 in decimal system. If the data3, data4, and data5 are 0x16, 0x27, and 0x43 respectively,
the current cash will be 1627.43 in decimal system. If the data6, data7, and data8 are 0x23, 0x47, and 0x18 respectively, the current liter will be 2347.18 in decimal system.
If the data9 is 0x02, the dispenser is fueling now; if the data9 is 0x01, the dispenser is stopping now.
(2): If the data2, data3, data4, and data5 are 0x98, 0x76, 0x53, and 0x43 respectively, the shift liter sum will be 987653.43 in decimal system. If the data6, data7, data8, and
data9 are 0x89, 0x45, 0x63, and 0x23 respectively, the shift liter sum will be 894563.23 in decimal system.
(3): If the data2, data3, data4, and data5, data6, data7, data8, and data9 are 0x98, 0x76, 0x54, 0x32, 0x10, 0x12, 0x 45, and 0x43 respectively, the total cash will be
98765432011245.43 in decimal system.
(4):If the data2, data3, data4, and data5, data6, data7, data8, and data9 are 0x01, 0x02, 0x45, 0x30, 0x10, 0x13, 0x 65, and 0x00 respectively, the total liter will be
2
1024530101365.00 in decimal system.
增加
状态位 的第 5 位 1=有预制 0=没有
B2 L 凑整
B3 P 凑整
3
新增或者修改的部分功能:
修改细节如下: