Sunteți pe pagina 1din 28

HIMA Training

RS485 HIBUS-Communication

Contents
1 2 3 4 Creating a project with 3 resources (example) ................................................ 2 Definition of bus and subscribers..................................................................... 3 Properties of the Resource................................................................................ 9 Assigning the variables for the communication............................................ 13 4.1 5 6 Notes regarding variable definition: .............................................................. 13

Compiling PES - Master ................................................................................... 19 Communication monitoring............................................................................. 24 6.1 6.2 Communication monitoring in master PES ................................................... 24 Communication monitoring in slave and master PES................................... 25

7 8

Hardware, hints, system limits ........................................................................ 27 Changes ............................................................................................................ 28

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 1/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

1 Creating a project with 3 resources (example)


Example: Configuration with 3 resources: PESxxx01 PESxxx02 PESxxx03 with Program-Instance Program_PES1 with Program-Instance Program_PES2 with Program-Instance Program_PES3

The programs are assigned as program-instances to the resources or type instance.

In example the defined bus (Type HIBUS) has two tasks: 1. Safety related communication (HIPRO-S) over master module F8621A 2. Programming bus for ELOP II communication.

Remark for practice: Depending on load it is recommended to split the networks in two independent systems.

Page 2/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

2 Definition of bus and subscribers

Step 1: Open context menu of the configuration and select properties

Step 2: Add a new bus.


Select the tab "Buses", button "Add" and define a name for the bus e. g. "NETWORK". Confirm with OK.

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 3/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 3:

Add the stations of the bus

Click on the button: "Add"

Step 4: Define the slaves


Select a resource out of existing list. BSN (bus station number) must be the same as set with the dip switches on the Central unit. Repeat this step for each resource!

Page 4/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 5: Add ELOP II PC


Select the bus name, click on the button "Edit"

In the window "Edit HIBUS bus name" : click on Add Type: select PADT (PC) Insert name for PC Define BSN, No. 31 for PC ! Confirm with OK.

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 5/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 6: Add PES-Master(s)


Click on Add Select the type "PES-Master" Insert name e. g. "Master" BSN of Master is automatically taken over from BSN of according central module. There is no special address setting on master module possible.

PES master parameters: CU: CM: Time master: Redundant Bus: master module located beside left central module means CU 1 master module located beside right central module means CU 2 position (in case of H51q 3 slots are available beside the central modules) time of master CU is distributed to slaves periodically Activates the second interface of F8621A to drive a redundant HIBUS Normally only the first bus is active. Second bus is tested periodically and hot standby (switch over automatically) For diagnostic use function block HK-AGM-3, see chapter 6.1 Standard timeout for response of slave is 25ms + STO STO = short time out (2ms for 57600bit/sec, 5ms for 9600bit/sec) The time, set by this parameter, is used as an additional time, especially for very slow systems e.g. modem connections. Additional time between master requests to create big additional pause times. Used e.g. for satellite communication.

Additional time delay:

Additional pause time

For further information see Help

Page 6/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training
Repeat step 6 to define a redundant master!

RS485 HIBUS-Communication

Redundant master must have the same name as the first master but defined in a different position (normally in the same PES beside CU 2, but not required).

(example with redundant master)

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 7/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 7: Check communication parameters


Recommendation for exercise: keep standard settings.

Page 8/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training 3 Properties of the Resource

RS485 HIBUS-Communication

Step 1: Select context menu of the resource, properties, PADT (PC):


Select bus out of existing bus list. Select PADT (PC) out of existing PADT list. Note: Do not insert own new names here!

Take entries with Apply and confirm with button "OK". Repeat Step 1 for each resource!

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 9/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 2: Edit cabinet layout, checking the interfaces of the central unit and/or F8621A.
In master PES insert the F8621A modules. (left is F8621, right is F8621x)

Double click to module: The properties of the central unit are shown It is recommended to "use bus settings". By this the parameters can be defined central for all resources belonging to a defined bus. HW-settings means, the baud rate set with the dip switches on the central unit is active. It is also possible to set the parameters manually (for special applications). The setting can be different for both interfaces (left/up SIO1, right/down SIO2)

Repeat Step 2 for each resource!

Page 10/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 3: Introduce the communication partner in the resource:


Select context menu of the resource, > properties, > HIPRO-S Select the resources, with which data shall be exchanged: Example: If you opened the properties of PES___01, you can select PES___02 and/or PES___03 as partners. Select the Master(s) responsible for organisation of the communication. Define the monitoring time: If there is no data exchange with the resource within the monitoring time, the values of the variables are reset if the setting "Reset imported variables" is marked. (Required for safety related communication)

Repeat Step 3 for each resource!

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 11/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training
Result for PES___01:

RS485 HIBUS-Communication

Result for PES___02:

Page 12/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

4 Assigning the variables for the communication


4.1 Notes regarding variable definition:

Each HIPRO-S variable is defined twice. In the sender as "Export to Resource" and in minimum one receiver as "Import from Resource". The variable name must be the same in all resources where the variable is defined. One variable can be transferred to several receivers. To ensure correct spelling it is recommended to define the variable one time at the sender and to copy it using "drag and drop" to the receiver (keep left mouse key pressed) Another possibility: using EXCEL to define the variables and import them afterwards. Example: AN02_PES01to PES02 will be created in PES01 and send to PES02 to read it there. So the variable must exist in both program instances. Open both program instances and copy it by "drag and drop":

The definition of these variables must be done for all resources according to the steps 1-6 in this chapter.

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 13/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Example: Variable Var01_PES01toPES02 should be transmitted from PES___01 to PES___02.

Step 1 Export
Open program instance PES___01, > Variable declaration Right mouse button, > New

Step 2 Export
Enter variable name in PES___01 e.g. Var01_PES01toPES02, declaration "BOOL"

Page 14/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 3 Export
Open folder "HIPRO-N/_S" Mark other resource (PES___02)

Step 4 Export
Select with double-arrow Export to Resource

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 15/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 5 Import
Open program instance in PES___02 to define the corresponding Import: Create a new Variable in PES___02 with the same Name like in PES___01 used for Export or copy the variable from program instance PES___01 to program instance PES___02, refer to 4.1 (e.g. Var01_PES01toPES02)

Page 16/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 6 Import
Open folder "HIPRO-N/_S" Mark other resource

Step 7 Import
Select with double-arrow Import from Resource

Repeat steps 1 to 7 till all variables are defined. 03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 17/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 8 Start code generator for all resources


The code generator must be started for all modified resources! It is not possible to generate reloadable code!

Page 18/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Compiling PES - Master

Step 1 Edit PES-Master


Configuration, right mouse button > PES-Master

Step 2 Compiling PES-Master


Mark the PES-Master Button "Execute"

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 19/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Page 20/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 3 Cross-Reference
Then press button "Cross-Reference" With the cross-reference the defined communication variables can be checked. (button CrossReference in the PES-Master window. Example without errors:

You can see the variables which will be exchanged between the resources. If there is no error shown in the column Error, all variables are defined correctly. If there are any errors shown they must be eliminated before you can proceed to the next step! (example with only one master)

Example with errors:

The variables with indication "no source" or "no target" must be checked again in the program instances . The indication "different data blocks" will sometimes appear additional, can be ignored. In example the definition for Export in PES___01 is missing. (example with two masters)

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 21/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Please note: Window PES-Master CRF-Docu Configuration must be closed! Otherwise code generation in a resource is locked Reaction:

Step 4 Download of the resources


If there is no error in the Cross-Reference, each resource can be downloaded. Right mouse button on the resource, > Control panel > Download

Page 22/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Step 5 Download PES master(s)


Mark both masters and click Execute

Result:

If master is not loaded successfully check settings and wiring.

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 23/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training 6 Communication monitoring


6.1

RS485 HIBUS-Communication

Communication monitoring in master PES

Insert function block HK-AGM-3 in program instance of master PES:

For settings and diagnostic information see online help of HK-AGM-3.

Page 24/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

6.2

Communication monitoring in slave and master PES

Example: Logic for communication monitoring in PES___03:

The system variables "HIBUS.Resoucename.Receive counter" and "HIBUS.Resourcename.Fault" are created automatically during installing a HIPRO-S communication. The system variables must be assigned to normal variables to use them in logic. Please take care: Communication monitoring is only possible, if there is an installed "Import" from the other resources, means e.g. there must be an active data transmission from PES___02 (Export) to PES___03 (Import) to see "HIBUS.PES___02.Fault" as "FALSE" and a running "HIBUS.PES___02.Receive counter".

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 25/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

Advice: In example both system variables are used, in practice it is ok to use only "HIBUS.Resourcename.Fault"

Page 26/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training

RS485 HIBUS-Communication

7 Hardware, hints, system limits


Bus configuration, Hardware: Please refer to the H41q/H51q catalogue, especially data sheet of interface converter H7505. Here you will find all information about bus configuration, wiring, necessary components and cables. Especially take care about final resistors in H7506 modules!

Battery buffering for master program in F8621A: There is a special battery for buffering the master program: H51q: Two batteries on F7131 H41q: Two batteries on backplane of basic rack. Enable batteries with small switches S1 and S2 (must be in position 2, means On)

System limits: Number of variables for HIPRO-S: Max.505 Bytes from one resources to another one, means in one transmission. "Word" will be counted as two Bytes, 8 "Bool" will be counted as one Byte (round up). Data memory: Max.64KB can be used in a central module for safety related data exchange with HIPRO-S Note: "Word" will be counted as two Bytes, "Bool" will be counted as one Byte. Max.31 communication partners

Estimation of bus cycle time:

Basic values:
Base time per master: Writing safety related data, per task: Writing safety related data, per byte: 40ms 50ms 0,2ms

Example: Configuration with 2 redundant F8621A master modules and 3 slaves. In summary there are 6 write tasks and 10 Bytes for each. Bus cycle time = 2x40ms + 6x50ms + 6x10x0,2ms = 392ms

Estimation of data transmission time (Input => PES => BUS => PES => Output): worst case: 2x cycle time of sending PES + 2x bus cycle time + 2x cycle time of receiving PES statistic value: 1,5x cycle time of sending PES + 1,5x bus cycle time + 1,5x cycle time of receiving PES

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

ELOP II

Page 27/28

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.

HIMA Training 8 Changes


Rev.: Date/Name 05 08.09.2008/ML Text: little optical updates

RS485 HIBUS-Communication

For your notes:

Page 28/28

ELOP II

03-SA-HIBUS_RS485_e_Rev05_(0837).doc

by HIMA Paul Hildebrandt GmbH + Co KG. Any copy, even in extracts, are prohibited unless by permission from HIMA.