6. Configuring the Gateway

Field in the

Size in the

Description

frame

frame

 

Preset Data

2 bytes

Data Location: Address, in the gateway’s output data memory (16#0202 to

 

or more for a

16#03FF), of the item of data to be transmitted in the “Preset Data” field for the

 

block of data

query’s frame.

 

 

N.B. The “Data location” field is used for each frame that allows you to

 

 

exchange some data between the Modbus slaves and the DeviceNet master.

 

 

In this case it designates the starting address of the block of data to be

 

 

transmitted.

 

 

N.B. As far as possible, ensure that the data is located at even addresses in

 

 

order to align the Modbus data (in 16-bit format) on the O:1.x outputs of the

 

 

DeviceNet scanner.

 

 

E.g. The value to be assigned to the ATS48’s CMD register should be placed

 

 

in the gateway’s output data memory area. We will be using the first free

 

 

location starting at an even address, that is to say the one located at 16#0220,

 

 

with the gateway’s default configuration.

 

 

 

 

 

Data length: Length of the block of output data, in the gateway’s memory,

 

 

whose values must be transmitted in the “Preset Data” field of the query’s

 

 

frame. It is expressed in number of bytes.

 

 

N.B. The “Data length” field is always used together with the “Data location”

 

 

field, described above.

 

 

E.g. Since the “Preset Single Register” command is used to write the value of a

 

 

single register (16-bit), the value of the “Data length” field must be set to 2.

 

 

See the documentation for each Modbus slave to find out the maximum

 

 

amount of 8-bit data which can be placed in “Data” type fields in queries and

 

 

responses for this slave. With the ATS48, for instance, it is limited to 30 16-bit

 

 

words.

 

 

Byte swap: Specifies whether the output data bytes to be transmitted to the

 

 

Modbus slave must be swapped before being placed in the Modbus frame or

 

 

not. The three possible values are as follows:

-No swapping ....... Default configuration. The data is sent in the same order as they appear in the gateway’s memory.

-Swap 2 bytes ...... The bytes to be transmitted are swapped two by two. This is the case which must be used by default, because for an item of 16-bit data, the most significant byte is placed first in the Modbus frame, whereas it is always written into the gateway’s memory by a DeviceNet master with the least significant byte first.

-Swap 4 bytes ...... The bytes to be transmitted are swapped four by four. This is rarely used, as it only relates to 32-bit data. The principle is similar to that of the previous case, “Swap 2 bytes”.

E.g. We will be using the “Swap 2 bytes” value, because the two bytes of the value to be written into the ATS48’s CMD register, as transmitted by the SLC500 PLC, are placed into the gateway’s memory in least significant / most significant order.

71

Page 71
Image 71
Schneider Electric LUFP9 user manual Field, Size, Frame