Herunterladen Inhalt Inhalt Diese Seite drucken

Modbus Funktionen - Caleffi 579 Serie Programmieranleitung

Magnetischer, selbstreinigender schlammabscheider-schmutzfänger
Inhaltsverzeichnis

Werbung

MODBUS Funktionen:

Function 0x03 - Read Holding Registers
Used to read one or more parameters (the size of every parameter is 16 bit)
The frame has the following structure:
dev. Addr.
func
03
HH
dev. Addr. – Address of the device on the RS485 net (1-250)
Func – Function code = 3
start addr H - MSByte of the address of the parameter:
start addr L - LSByte of the address of the parameter
N.regs H - MSByte of the number of registers to read (always 0)
N.regs L - LSByte of the number of registers to read
CRC16H - MSByte of CRC16
CRC16L - LSByte of CRC16
If during a multiple reading request, is specified a not allowed quantity of registers, the device will answer with an exception code 0x02 (ILLEGAL DATA
ADDRESS).
Function 0x06 - Write Single Register
Used to write a single parameter ( 16 bit )
The frame has the following structure:
dev. Addr.
func
06
HH
dev. Addr. - Address of the device on the RS485 net (1-250)
Func - Function code = 6
Reg. addr H - MSByte of the address of the parameter
Reg addr L - LSByte of the address of the parameter
Reg. val. H - MSByte of the value of the parameter
Reg val. L - LSByte of the value of the parameter
CRC16H - MSByte of CRC16
CRC16L - LSByte of CRC16
The specified value is not accepted (exception code 2) if it is not consistent with the parameter range or if it is not consistent with the current state of
the device (e.g. day = 31 rejected if month = 4, month = 4 rejected if day = 31).
start addr H
start addr L
N.regs H
HH
HH
Reg. addr H
Reg. addr L
Reg. val. H
HH
HH
N.regs L
CRC16H
00
HH
HH
Reg. val. L
CRC16H
HH
HH
HH
10
CRC16L
HH
CRC16L
HH

Werbung

Inhaltsverzeichnis
loading

Inhaltsverzeichnis