M850 3x Register Order


The M850 has the facility to re-order their Modbus 3X registers to suit an existing Modbus network.
The integrated register re-ordering function ('Registers' button) in the MultiView Program provides an easy method of achieving it.
If MultiView isn't going to be used, Modbus function code 42h (66) can be used to request this data and Modbus function code 41h (65) can be used to send a string of data to set the order of the registers. The new order will be saved in non-volatile memory.

UNLIKE THE 3X AND 4X REGISTERS, THESE DATA ARE WORD WIDE INTEGER.

It is important to remember that each register in the packet's data field contains two references to the registers to be re-ordered.

A sample read packet will look like this:-
[Node][42][start address(always 0000h)][001C][CRC(2 bytes)]
e.g. To read the Mobus register order in node 23h:-
[23h][42h][0000h][001Ch][CRC(2 bytes)]

A sample write packet will look like this:-
[Node][41][start address(always 0000h)][No. of Double Registers][Data length in bytes] [REGISTERS][CRC(2 bytes)]

e.g. To set the 48 Modbus registers to their default order in node 23h:-
[23h][41h][0000h][0018h][30h][0102h][0304h][0506h][0708h][090Ah][0B0Ch][0D0Eh]
[0F10h][1112h][1314h][1516h][1718h][191Ah][1B1Ch][1D1Eh][1F20h][2122h]
[2324h][2526h][2728h][292Ah][2B2Ch][2D2Eh][2F30h][CRC(2 bytes)]

Sample Coding
WRITE
1) Set the default order for a standard M850

Slave Address = 1
Writing - code 65 (41 hex)

Message Packet To SLAVE
01 41 00 00 00 18 30 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D 1E 1F 20 21 22 23 24 25 26 27 28 29 2A 2B 2C 2D 2E 2F 30 4A 53

Response Packet From SLAVE
01 41 00 00 00 18 3D CF

2) Move registers kW Sum (position 10), kVAr Sum (position 12) and kVA Sum (position 11) into the first three positions in the table so that the measurements can be retrieved from the slave by reading just the first three registers (30001-30005 or 42001-42005).

Slave Address = 1
Writing - code 65 (41 hex)

Message Packet To SLAVE
01 41 00 00 00 18 30 0A 0C 0B 01 02 03 04 05 06 07 08 09 0D 0E 0F 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D 1E 1F 20 21 22 23 24 25 26 27 28 29 2A 2B 2C 2D 2E 2F 30 FF 34

Response Packet From SLAVE
01 41 00 00 00 18 3D CF

READ
N.B. Asking for more registers than the M850 supports will not result in an error.

1) Default order
Slave Address = 1
Reading - code 66 (42 hex)

Asking for register order

Message Packet To SLAVE
01 42 00 00 00 1C 78 0C

Response Packet From SLAVE
01 42 00 00 00 1C 30 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D 1E 1F 20 21 22 23 24 25 26 27 28 29 2A 2B 2C 2D 2E 2F 30 10 5B

2)
W Sum, VAr Sum, VA Sum order
Slave Address = 1
Reading - code 66 (42 hex)
Asking for register order

Message Packet To SLAVE
01 42 00 00 00 1C 78 0C

Response Packet From SLAVE
01 42 00 00 00 1C 30 0A 0C 0B 01 02 03 04 05 06 07 08 09 0D 0E 0F 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D 1E 1F 20 21 22 23 24 25 26 27 28 29 2A 2B 2C 2D 2E 2F 30 A5 3C