Schneider Electric LUFP9 user manual Numparam

Page 90

9. Appendix C: Practical Example (RSLogix 500)

The various data used by this sub-program are shown in the following table:

Address

Symbol

Description

B3.0/0

RD_RUNNING

Reading a parameter on all TeSys U motor starters: In progress

 

 

Reading a parameter on all TeSys U motor starters: Reading is correct (OK) or

B3.0/1

RD_OK_KO

incorrect (KO) for a motor starter (if the response has arrived or when timeout

 

 

T4:0 is triggered)

B3:0/5

————

The “trigger byte” of the query has been updated: Yes (1) / No (0)

 

 

Reading a parameter on the TeSys U motor starters: Counter. When the value

C5:0

CPT_RD_TESYS_U

of this counter reaches 9, the process of reading a parameter on all of the

 

 

TeSys U motor starters is halted.

 

 

Result of reading a parameter: Slave (16#01 to 16#08) as MSB. The value of

I:1.10

CR_RDPAR_XXX_SLAVE

this field is compared to that of the corresponding field in the query frame. The

 

 

LSB of this input word is not used.

 

 

Result of reading a parameter: Function (always 16#03) as LSB (the value of

I:1.11

CR_RDPAR_FCT_BYTES

this field is compared to that of the corresponding field in the query frame) +

 

 

number of bytes read (16#02) as MSB (value masked and checked).

 

 

Result of reading a parameter: Value of the parameter read (MSB and LSB

I:1.12

CR_RDPAR_VALUE

are swapped). This value is placed in array N7:[N7:2], then its MSB and its

LSB are swapped there in order to restore the correct value of the read

 

 

 

 

parameter.

N7:1

NUMPARAM

User command: Number of the read parameter.

N7:2

RD_INDEX

Index in the array of results for the reading of a TeSys U parameter. Value = 4

to 11 (motor starters nos. 1 to 8).

 

 

N7:3

ADDRESS

Address of the Modbus slave for which one of the parameters is currently

being read. Value = 1 to 8.

 

 

 

 

Array of results used for the reading of a TeSys U parameter (motor starters

N7:[N7:2]

— [ RD_INDEX ]

nos. 1 to 8). Elements N7:4 to N7:11 (see N7:2). Value = –1 in case of error

 

 

(response timeout triggered).

N7:36

————

Local counter that corresponds to the “trigger byte” of the read request.

N9:0

VAR_TEMP_1

Temporary scratch variable used to carry out intermediate evaluations.

O:1.10

RDPAR_SLAVE_FCT

Request for the reading of a parameter: Slave (from 16#01 to 16#08) as LSB

+ function (always 16#03) as MSB.

 

 

O:1.11

RDPAR_ADRPAR

Request for the reading of a parameter: Address of the parameter (copied

from N7:1, but with MSB and LSB swapped).

 

 

 

 

Request for the reading of a parameter: Number of parameters to be read

O:1.12

RDPAR_NBPARS

(always 16#0001, but with the MSB and LSB swapped, that is to say

 

 

16#0100).

T4:0

TIMEOUT_RD_PARAM

Timer for the timeout of the parameter reading command (3 seconds)

The example includes a personalized screen for monitoring the data, called “CDM 1 - RD_PAR”, in order to simplify the use of this example. The content of this screen is shown below:

Address

Symbol

Display

N7:1

NUMPARAM

Decimal

 

 

 

B3:0/0

RD_RUNNING

Binary

B3:0/1

RD_OK_KO

Binary

N7:2

RD_INDEX

Decimal

N7:3

ADDRESS

Decimal

N7:4

RDPAR1

Decimal

N7:5

RDPAR2

Decimal

N7:6

RDPAR3

Decimal

N7:7

RDPAR4

Decimal

N7:8

RDPAR5

Decimal

N7:9

RDPAR6

Decimal

Address

Symbol

Display

N7:10

RDPAR7

Decimal

N7:11

RDPAR8

Decimal

O:1.10

RDPAR_SLAVE_FCT

Hexadecimal

O:1.11

RDPAR_ADRPAR

Decimal

O:1.12

RDPAR_NBPARS

Hexadecimal

I:1.10

CR_RDPAR_XXX_SLAVE

Hexadecimal

I:1.11

CR_RDPAR_FCT_BYTES

Hexadecimal

I:1.12

CR_RDPAR_VALUE

Hexadecimal

I:1.16

TRIGGER_IN_RD_WR

Hexadecimal

O:1.16

TRIGGER_OUT_RD_WR

Hexadecimal

N7:36

————

Hexadecimal

B3:0/5

————

Binary

90

Image 90
Contents LUFP9 Page LUFP9 Page Table of contents Introduction Introduction to the user guideIntroduction to the LUFP9 Gateway TerminologyAltistart Notational Conventions Additional DocumentationDownstream network no.3 Modbus ModbusModbus VW33-A48 Downstream network no.1Principle Used to Configure and Operate the LUFP9 Gateway ABC Configurator Modbus networkRSLogix LUFP9 gatewayRSNetWorx DeviceNet NetworkConfiguration Modbus RTU Hardware Implementation of the LUFP9 GatewayOn Receipt Powering the gateway Mounting the Gateway on a DIN RailMounting the gateway Dismounting the gateway Connecting the Gateway to the Modbus Network Examples of Modbus connection topologiesLUFP9 gateway TSXCSA00 Pin outsWiring recommendations for the Modbus network 120 ΩHubs, drops, taps, and line terminations Cables Connecting the LUFP9 gateway to the DeviceNet networkWire colour PinConfiguring DeviceNet Communication Features Selector Switches DeviceNet speed 3 4 5 6 7Selector DeviceNet Switches Address 3 4 5 6 7 Speed Address Mac IDEncoding the Gateway Address Signalling System Architecture Software Implementation of the GatewayIntroduction DeviceNet Master PLC SLC500 DeviceNet upstream networkConfiguring the Motor Starters Modbus cycle timeManaging degraded modes Configuring the Gateway in RsNetWorx Installing the Gateway Description FileSelecting and adding the master PLC’s DeviceNet scanner Selecting and Adding the Gateway to the DeviceNet Network Editing gateway parametersSoftware Implementation of the Gateway Configuring the DeviceNet Scanner I1.1 Configuring Inputs from the GatewayService PLC input Description I1.2O1.1 Configuring Outputs Intended for the GatewayService PLC output Description O1.2Description of Services Assigned to Gateway Inputs/Outputs Output Value Meaning MSB + LSBInput Value Meaning MSB + LSB Transferring the DeviceNet Scanner Configuration Developing a DeviceNet ApplicationSummary Gateway Initialization and DiagnosticsFull Management Control/Status Byte field Sub-chapterFbhssend New DeviceNet master command word Fbdu Modbus exchange startupBits Description ED Error data item associated with the Modbus network Bits Description Abchssend New gateway diagnostic11EC Error code associated with the Modbus network Gateway Status WordDescription of the error Diagnostic only DeviceNet Master Command Word Simplified Operation Configuring the Gateway Connecting the Gateway to the Configuration PCMale RJ45 LUFP9 Configuration Female RJ45RS-232 link protocol PC COM Male 9 point SUB-DInstalling AbcConf Importing the Gateway ConfigurationTransferring a Configuration to the Gateway Monitoring the Content of the Gateway’s MemoryConfiguring the Gateway Procedure for deleting a Modbus slave Deleting a Modbus SlaveAdding a new type of Modbus slave Copying a previously configured Modbus slaveAdding a Modbus Slave Keyboard shortcut CtrlImporting/exporting a Modbus slave configuration Changing the Periodic Data Exchanged With a Modbus Slave Replacing a Periodic Input Data ElementReplacing an Output Periodic Data Element Increasing the Amount of Periodic Input Data Configuring the Gateway Configuring the Gateway I1.19 I1.17I1.18 I1.20Configuring the Gateway Configuring the Gateway Configuring the Gateway O1.17 O1.18Deleting Aperiodic Parameter Data Configuring the Gateway Changing a Modbus slave Configuration Changing the Name of a Modbus SlaveChanging the Address of a Modbus Slave With TeSys U Motor Starters Adding and Setting Up a Modbus CommandName of the Modbus command Modbus query Modbus responseWith a Generic Modbus Slave Configuring the Gateway DeviceNet Configuring the Query Configuration Description ElementConfiguring the Gateway Default communication mode. The query is transmitted Configuring the Response Configuring the Content of the Query Frame Field Size Description FrameField SizeFrame Mode. The default value, CRC, should not be changed Configuring the Content of the Response FrameAdding a Special Modbus Command Modbus Commands Based on Standard CommandsModbus Commands which Can Be Completely Changed by the User Configuring the General Characteristics of the Gateway Fieldbus elementABC Element Sub-Network Element Configuring the Gateway Adding a Broadcaster Node Appendix a Technical Characteristics Communication CharacteristicsEnvironment Inputs Input data areaOutput data area OutputsGeneral data General data area16#10 Appendix B Default ConfigurationConfiguring Modbus exchanges 16#06Content of the Gateway’s Dpram Memory Input Data Memory Area16#0200 Appendix C Practical Example RSLogix Main Program LAD 2 MAINLUFP9 Address Symbol Description ScanvalidationCmdreset Module Address Symbol DisplayAppendix C Practical Example RSLogix Numparam Appendix C Practical Example RSLogix Wrrunning Address Symbol Display Reserves relating to the RSLogix 500 exampleList of the Gateway’s DeviceNet Objects Appendix D DeviceNet ObjectsIntroduction to the Gateway’s DeviceNet Objects Class Required Instances InterfacesGraphical Representation of the Gateway’s DeviceNet Objects Identity Object class 16#01Services of instance 16#01 of class 16#01 Attributes of instance 16#01 of class 16#01Message Router Object class 16#02 DeviceNet Object class 16#03Services in class 16#04 Assembly Objects Class 16#04Services of instance 16#01 of class 16#03 Revision index of the Assembly Object classAttributes of instance 16#64 of class 16#04 Modbus Inputs Services of instances 16#64 and 16#96 of class 16#04Connection Object Class 16#05 Attributes of instance 16#96 of class 16#04 Modbus OutputsServices in class 16#05 Attributes of class 16#0516#83 Initial comm. characteristicsWatchdog timeout action Produced connection IDAccess Name Type Value 16#01 Get StateType Value Get / Set Produced connection path16# 20 04 24 64 30 Type Value 16#07 Get / Set Produced connection size Type Value 16#04 Get / Set Produced connection ID #0 xxAttributes of instances 16#01 to 16#04 of class 16#05 Services in class 16#2BAcknowledge Handler Object class 16#2B Attributes of class 16#2BServices of instance 16#01 of class 16#2B Type Value 16#06 Get Data with ack path list sizeData with ack path list 10.10. I/O Data Input Mapping Object Class 16#A0 Services in class 16#A0Services of instance 16#01 of class 16#A0 Attributes of class 16#A010.11. I/O Data Output Mapping Object Class 16#A1 Services in class 16#A1Services of instance 16#01 of class 16#A1 Attributes of class 16#A1Attributes of class 16#AA Diagnostic Object Class 16#AAServices in class 16#AA Attributes of instance 16#01 of class 16#AADeviceNet module status Access Name Need Type Value 16#09 Get LED statusModule type Changed data fieldServices of instance 16#01 of class 16#AA Appendix E Modbus Commands Read Holding Registers Command 16#03 Preset Single Register command 16#06Frame Field Value or properties Preset Multiple Registers Command 16#10 Modbus Protocol Exception ResponsesCode Name Description of the exception Exception Page User’s manual V1.0 2003-03