Driver
Driver
Driver
User Guide
July 2015
Copyright
The information in this document is subject to change without prior notice and does not
represent a commitment on the part of AFCON Control and Automation Ltd., AFCON
Software and Electronics Division.
No part of this document may be used or reproduced in any manner whatsoever without
written permission from AFCON Control and Automation Ltd., AFCON Software and
Electronics Division.
The software described in this document is furnished under a license agreement or a nondisclosure agreement.
The software may be used or copied only in accordance with the terms of the agreement.
It is against the law to copy this software on any other medium for any purpose other than
the purchaser's personal use.
Copyright 2015 AFCON Control and Automation Ltd., AFCON Software and Electronics
Division.
All rights reserved.
Pulse logos are registered trademarks of AFCON Control and Automation Ltd., AFCON
Software and Electronics Division.
Windows is a registered trademark of Microsoft Corporation in the United States and other
countries.
Table of Contents
Copyright....................................................................................................... 2
Introduction ...................................................................................................... 4
Requirements ................................................................................................. 5
Hardware .................................................................................................. 5
Software ................................................................................................... 5
Computer Resources .................................................................................. 5
Installation ........................................................................................................ 6
File Paths ....................................................................................................... 9
Hardware..................................................................................................... 10
Linking to a Single PLC in an RS232 Network ............................................... 10
Linking to a Network of PLCs for an RS-485 or RS-422 Network ..................... 10
Network Cable Wiring ............................................................................... 11
Network Requirements for Ethernet ............................................................ 11
Linking to a Network of PLCs for an SM85 or SA85 Network ........................... 12
Linking to a Modem .................................................................................. 12
Packet Data Connections ........................................................................... 13
Modbus Plus Connections .......................................................................... 13
Communication Setup.................................................................................... 14
Assigning the Modbus Driver to a Port......................................................... 14
Defining Multiple P-CIM Ports for a Single PLC ................................................... 15
Configuring Driver Parameters ........................................................................ 16
Scheduling Parameters ............................................................................. 17
Instructions for RS-232............................................................................. 18
Instructions for Ethernet and Packet Data.................................................... 20
Instructions for Modbus Plus ...................................................................... 23
Instructions for Modem ............................................................................. 25
Defining Advanced Parameters................................................................... 29
Defining Polling Configurations................................................................... 29
Basic Information ............................................................................................ 31
Bit Representation................................................................................... 31
CollapseWrite .......................................................................................... 31
ReflectWrite ............................................................................................ 31
Rounding ................................................................................................ 32
Referencing Driver Data in Pulse ..................................................................... 32
Address Syntax........................................................................................ 32
Syntax Table ........................................................................................... 32
Direct Access Syntax ..................................................................................... 37
Conversions ................................................................................................. 38
Conversion Links...................................................................................... 39
$Variables............................................................................................... 42
Troubleshooting - Alarm Handler Messages ..................................................... 46
Error Codes .................................................................................................. 47
Appendix A - Specifications ............................................................................. 48
Supported Protocols ................................................................................. 48
Supported Serial Parameters ..................................................................... 48
Ethernet Supported Parameters ................................................................. 48
MBPlus Supported Parameters ................................................................... 49
Packet Data Supported Parameters............................................................. 49
Appendix B - Checking Communication............................................................ 50
Using Data Scope to Check Communication Status ............................................ 50
Using the Alarm Summary to Monitor Communication Status .............................. 51
Monitoring Communication Event Messages ...................................................... 52
Using the Drivers Server to Check Communication Status................................... 52
Appendix C - Known Issues ............................................................................ 53
Introduction
This document discusses the Modbus driver, how it is installed, referenced and configured
in Pulse to read and write values to and from addresses in runtime. The Modbus driver and
its runtime parameters are defined in the P-CIM Configurator dialog box and can run in
either normal or emulation mode.
The Modbus driver, during runtime, runs in the background continually, communicating
with PLCs, and providing access to PLC data by continuously polling Pulse addresses. Data
is written to the PLC on operator or application demand after the constant transaction is
completed.
Alarm and event messages are displayed in the Alarm Explorer and/or Alarm Handler
module.
The Modbus driver supports cellular communications when Packet Data settings are defined
in the Communication Settings dialog box.
The Modbus driver supports Pulse Hot Redundancy Mode.
The following formats are supported by the Modbus driver:
ASCII
RTU
TCP/IP
MBPLUS protocol variants
Packet data
The Modbus driver communicates with these PLC models:
The number of digits shows the syntax used in the P-CIM Configurator.
The driver communicates through COM 1 and COM 255 ports, or, the PCs Ethernet
adapter port.
Requirements
Hardware
Modems for connecting to networks.
For an Ethernet network: Communication card.
For an MBPLUS network: Pulse communicates by one or two SA85 or SM85 network
adapters installed in an IBM-PC (or compatible) platform running Pulse.
NOTE
For modem networks: no extra hardware is needed for connecting to a single PLC
by an RS232 connection through COM1 or COM2.
Software
Windows XP, Windows 2003 Server
Pulse 1.10 or higher
For Ethernet network: fixed IP address
For a Modbus Plus Network: Modicon device driver
NOTE
For MBPlus networks: check that SA85 or SM85 are installed correctly.
Computer Resources
The driver needs roughly 5 MB of disk space.
Installation
The Modbus driver can only be installed after Afcon Pulse is installed on a computer. Below
are instructions for installing the Modbus driver from the Pulse DVD. The driver can also be
downloaded from the AFCON Web site (www.afcon-inc.com). Click the Products link, and
then click Drivers 32 bit to locate and download the relevant driver zip file to your
computer. Additionally, the Install Driver option in the Communications Setup dialog box
enables assigning an installed driver to a Pulse project. From all of these entry points, the
Driver Setup Wizard will execute the installation.
Installing the Modbus driver from the Afcon DVD
NOTE:When installing drivers, make sure that Pulse is shut down.
1
Insert the AFCON DVD into the DVD drive on your computer. Wait for it to open on
your screen.
Select Pulse, select Communication Drivers and then Open to open the
Communication Drivers dialog box.
Click Next. Select a project or install the driver into multiple projects using the
standard Windows selection key combinations (<Shift>+click, <Ctrl>+click, <Ctrl>+A
[for all]).
Click Next. Review the summary information. You may expand the driver table to see
which files the driver setup will install and their destination folder.
Click Install. The Install Progress page shows you the progress and status of the
driver installation. When the Current Task and Setup Status bars display 100%, the
installation is done.
As an option, you can generate, store, and print installation reports:
Report All
Report Errors
Click Next. If successful, the wizard notifies that the driver was successfully installed.
If you want to install another driver, click Install Another Driver to start the process
again. Otherwise, click Finish to close the wizard.
Start Pulse
Server
The Pulse Server starts up after you click Finish. After the
Server completes startup, the Driver Setup wizard closes.
File Paths
The files associated with this driver and files common to all drivers in the system are listed
below in their default locations:
File
Path
Notes
MODBUS.EXE
C:\AFCON\Pulse\projectname
\Communication folder
MODBUSDR.DLL
C:\AFCON\Pulse\projectname
\Communication folder
Runtime driver
MODBUS.INI
C:\AFCON\Pulse\projectname
\Communication folder
DrvrPort.INI
C:\AFCON\Pulse\projectname
\Communication folder
MODBUS.HLP
C:\AFCON\Pulse\projectname
\Communication folder
MBPTRANS.DLL
C:\AFCON\Pulse\projectname
\Communication folder
NOTE
Hardware
This chapter displays the physical connections between a PC and the PLCs with which it
communicates.
NOTE
PC AT 9 pin
PLC 9 pin
PC AT 9 pin
PLC 25 pin
NC 1
SHLD
CD
1 SHLD
RX 2
RX
RX
2 TX
TX 3
TX
TX
3 RX
DTR 4
DTR
DTR
4 RTS
GND 5
GND
GND
5 CTS
DSR 6
DSR
DSR
6 DSR
RTS 7
RTS
RTS
7 GND
CTS 8
CTS
CTS
8 CD
NC
20 DTR
P-CIM
RS485/RS232
PLC
RS232/RS485
RS485/RS232
PLC
RS485/RS232
PLC
10
PC AT 9 PIN
J478/S978
25 PIN
SHLD 1
1 SHLD
RX
2 TX
TX
3 RX
DTR
4 RTS
GND
5 CTS
DSR
6 DSR
RTS
7 GND
CTS
8 NC
NC
20 DTR
NO CPU
NO CPU
HUB
Interface adapter
installed 3COM
P-CIM
11
P-CIM
PLC
PLC
PLC
Linking to a Modem
The diagram below shows linking to a modem.
P-CIM
Modem
Line
Telephone
Service
PLC
Modem
PLC
Modem
Line
Line
12
Line
Modem
P-CIM
PLC
Line
Modem
PLC
Line
Modem
12?
12?
4
9
3
8
2
7
Terminator
4
9
-------Network--------
3
8
2
7
1
6
4
9
3
8
2
7
1
6
Terminator
13
Communication Setup
Assigning the Modbus Driver to a Port
In Project Communication Setup you assign logical Pulse ports to the driver (see below,
To assign a port to the driver) and then select the physical COM ports and configure the
appropriate communication parameters for those ports.You can setup or change the
communication settings while Pulse is running or not running. However, the new settings
will take effect only after Pulse is restarted.
To assign a port to the driver
1
To assign a new port to a driver, click the New button; to edit an already assigned
port, select the appropriate port in the Assigned ports box and click the Edit button.
The Port Properties dialog box is displayed.
To assign a new port, type a number between 1-255 in the Port Name box. For an
already assigned port, the port number is displayed.
14
Description
Port Name
Driver Name
This list holds the names of all the drivers installed in the current
project. A driver can be used any number of times.
Bit numbering
system
This field defines the read bit access used. For example, if Octal is
used, the digits 8, 9 are not available. It is recommended to leave
the setting at its default of 10 decimal.
Lowest bit
number
Select 1 from the drop-down list to define the bit numbering for this
driver as 1-16.
When 0 is selected, the bit numbering for this driver is 0-15.
Emulation
Mode
Click OK.
The Port Properties dialog box is closed. The assigned port, the name of the new driver
and the mode all appear in the Assigned ports box in the Project Communication Setup
dialog box. The port allocation is recorded in the DRVRPORT.INI file.
15
16
Scheduling Parameters
Use the information in this table to complete the Scheduling parameters for all network
types.
Field
Description
P-CIM port
Polling Configuration
Simulate I/O
Timeout
The defined amount of time the driver waits for a valid reply
from the PLC, and retries the transaction twice if a reply is not
received or is garbled.
The default value is 1-second, ranging from 0.5 to 50 seconds.
Max Retries
Min Reconnect
17
In the Network Type field, select RS232 from the drop-down list to display the
Transport Parameters RS232 dialog box.
Field
Description
COM Port
Baud Rate
Data Bits
Parity
Stop Bits
Shows the number of bits in each byte signaling the end of the byte.
COM Mode
RTU
ASCII
Station
Parameters
18
To display the Station Parameters RS232 dialog box, click the Station
Parameters button in either the P-CIM Configurator for Modbus Driver or the
Transport Parameters dialog boxes.
Click the Add button to open the Add New Stations dialog box.
Field
Description
PLC Number
Min. Address
Length __
Digits
Show
Advanced
Parameters
Select the number and PLC Type using information from the above table.
Click OK to save these definitions and to return to the Station Parameters dialog box.
Secondary Transport
Select the Use Secondary Transport option to enable the use of a secondary
communications channel (i.e, port, secondary server) in a Redundancy configuration.
19
In the Network Type field, select Ethernet or Packet Data from the drop-down list
to display the Transport Parameters Ethernet or Transport Parameters
Packet Data dialog box.
Field
Description
Default Remote
Port
Transport Protocol
Multi Sockets
Use Ping
Support
Unsolicited
Messages
Station Parameters
20
Description
Number
Min. Address
Length
Sets the minimal address length. To match the minimal length defined,
a leading 0 is added to every address that is below the threshold. An
address that is equal to or higher than the defined threshold, is not
changed.
IP Address
Port
Index
Click the Add button to open the Add New Stations dialog box.
21
Field
Description
PLC Number
IP Address
Port
Index
Min. Address
Length
Show
Advanced
Parameters
Secondary Transport
Select the Use Secondary Transport option to enable the use of a secondary
communications channel (i.e, port, secondary server) in a Redundancy configuration.
22
In the Network Type field, select MBPlus from the drop-down list to display the
Transport Parameters MBPlus dialog box.
Field
Description
LAN number
Data Paths
Station
Parameters
23
Click the Add button to open the Add New Stations dialog box.
Field
Description
PLC Number
Min. Address
Length __ Digits
Route
Redundant Route
Sets the redundant PLC route. Use this option as a backup in case
the driver is unable to connect to the primary PLC.
Show Advanced
Parameters
Complete this dialog box using the information from the above table.
Click OK to save these definitions and to return to the Station Parameters dialog
box.
Secondary Transport
Select the Use Secondary Transport option to enable the use of a secondary
communications channel (i.e, port, secondary server) in a Redundancy configuration.
24
In the Transport dialog box click the Modem Parameters button to open the Modem
Parameters dialog box.
Field
Description
Initialization
String
Default Phone
Number
The phone number used when a PLC does not have a specified
phone number.
Dial Using
Phone
Parameters
Redial
Parameters
This area defines the modem settings used for redialling to the PLC
when communication is not successful.
25
Redial After
__ Minutes
Max Retries
Auto-Answer
Enable
PLC ID
Parameters
Number of
Rings
Scheduling
Ignore Delay
After Modem
Connection
Connect Every
__ Minutes
Every
Connection
26
In the Modems dialog box Auto Answer field, check the Enable checkbox.
The PLC ID Parameters button option is enabled.
Click the PLC ID Parameters button to display the PLC ID Parameters dialog box.
Click the Add button to open the Add PLC ID String dialog box.
Scroll to the relevant PLC number and then type in the string in the ID String field.
Click OK to return to the PLC ID Parameters dialog box. Complete this dialog box using
the information below:
Field
Description
Hang-up After
Getting PLC ID
String
Outgoing calls
Incoming calls
When checked, the driver hangs up after receiving the call and calls
back using the port configured for outgoing calls.
PLC ID string
waiting time
The waiting time (in seconds) for receiving information (range 1 - 15,
default is 1).
27
Click the Phone Parameters button in the Modem Parameters dialog box to display
the Phones Parameters dialog box.
Click the Add button to open the Add Phone dialog box, where the association
between the Modem and PLC is defined.
In the Phone Number field type in the phone number that is associated with a PLC.
Click OK to confirm and to return to the Phone Parameters dialog box where the
associated PLC and phone numbers are listed.
28
In the P-CIM Configurator for Modbus Driver dialog box, click the Polling
Configuration button to open the program.
29
Click the Add button to open the Add Polling Block dialog box.
Field
Description
Always OnScan
PLC
Start Address
Quantity
Scan time
Fill the Add Polling Block dialog box using the information above.
Click OK.
The definitions are displayed in the Polling Configuration dialog box.
30
Basic Information
Bit Representation
In the application the driver enables access to a specific reference bit. This bit is regarded
as a digital point. Bits can be referenced in the decimal range. Pulse bit numbering
convention for a data reference is:
CollapseWrite
This MODBUS.INI file setting enables sequential writing to a reference. By default,
CollapseWrite=0 (sequential writing) is enabled.
Disabling sequential writing to a reference
Open the Pulse INI File Editor and change the default setting to CollapseWrite=1.
The driver switches automatically to CollapseWrite=1.
The Alarm Summary displays a message if more than 4096 write addresses are in the
queue. This setting can be changed in the MODBUS.INI file, section: ['Port'], token:
MaxWrite Queue.
ReflectWrite
When the token ReflectWrite=1,(by default) token is defined, the driver returns an
updated value immediately after a successful read operation.
Disabling/refreshing data after a write action
Open the INI File Editor and make the following change: MODBUS.INI.Set
ReflectWrite=0.
31
Rounding
The MODBUS.INI file setting enables automatic rounding off a decimal value when inserting
a value to a reference. By default, Rounding=1 (rounding off enabled).
Disabling automatic rounding off
Open the Pulse INI File Editor and change the default setting 1 to Rounding=0. This enables
truncation of any decimal value inserted to a reference.
Address Syntax
PLC data handled by the driver is accessed by the Pulse Kernel and the drivers server by
a callback and a DDE link in the following format:
Server, Topic, Item
Server
PFWDRVR or DBSR
Topic
PCIM
Item
Station
Address
Syntax Table
Table 1: Driver Syntax
Modicon Syntax
Application
Syntax
Read,
Write
Type
Value Range
4-Digit
Note
1
Output
0001 - 0999
R/W
bit
0-1
Input
1001 - 1999
bit
0-1
Input Register
3001 - 3999
register
0-65535
F3001 - F3998
32 bits
IEEE
Floating
Point
L3001 - L3998
32 bits
Unsigned
Long
0-4294967295
32
T3001 - T3998
Time
Format
0D0H0M0S0M
s49D17H2M47S
295Ms
S3001 - S3999
16 bits
Signed
Integer
-32768 +32767
D3001 - D3996
64 bits
Floating
Point
SL3001 - SL3998
32 bits
Signed
Long
-2147483648 +2147483647
Holding Register
4001 - 4999
R/W
register
0-65535
Holding Register
- Float
F4001 - F4998
R/W
float num.
Holding Register
- Long
L4001 - L4998
R/W
long num.
0-4294967295
Holding Register
- Time
T4001 - T4998
R/W
string
0D0H0M0S0M
s49D17H2M47S
295Ms
Holding Register
- Sign
S4001 - S4999
R/W
16 bits
Signed
Integer
-32768 +32767
Holding Register
- Double
D4001 - D4996
R/W
64 bits
Floating
Point
Holding Register
- Signed Long
SL4001 - SL4998
R/W
32 bits
Signed
Long
-2147483648 +2147483647
Holding Register
- Write Only
W4001 - W4999
Event Status
EV0 EV191
bit
0-1
Alarm Status
AL0 AL191
bit
0-1
Output
00001 - 09999
R/W
bit
0-1
Input
10001 - 19999
bit
0-1
Input Register
30001 - 39999
register
0-65535
5-Digit
33
F30001 - F39998
32 bits
IEEE
Floating
Point
L30001 - L39998
32 bits
Unsigned
Long
0-4294967295
T30001 - T39998
Time
Format
0D0H0M0S0M
s49D17H2M47S
295Ms
S30001 S39999
16 bits
Signed
Integer
1:1:5400500
D30001 D39996
64 bits
Floating
Point
SL30001 SL39998
32 bits
Signed
Long
1:1:5400500
Holding Register
40001 - 49999
R/W
register
0-65535
Holding Register
- Float
F40001 - F49998
R/W
float num.
Holding Register
- Long
L40001 - L49998
R/W
long num.
0-4294967295
Holding Register
- Time
T40001 - T49999
R/W
string
0D0H0M0S0M
s49D17H2M47S
295Ms
Holding Register
- Sign
S40001 S49999
R/W
16 bits
Signed
Integer
1:1:5400500
Holding Register
- Double
D40001 D49996
R/W
64 bits
Floating
Point
Holding Register
- Signed Long
SL40001 SL49998
R/W
32 bits
Signed
Long
1:1:5400500
Holding Register
- Write Only
W40001 W46536
Event Status
EV0 EV191
bit
0-1
Alarm Status
AL0 AL191
bit
0-1
34
000001 - 065535
R/W
bit
0-1
Input
100001 - 165535
bit
0-1
Input Register
300001 - 365535
register
0-65535
F300001 F365535
32 bits
IEEE
Floating
Point
L300001 L365535
32 bits
Unsigned
Long
0-4294967295
T300001 T365535
Time
Format
0D0H0M0S0M
s49D17H2M47S
295Ms
S300001 S365536
16 bits
Signed
Integer
-32768 +32767
D300001 D365533
64 bits
Floating
Point
SL300001 SL365535
32 bits
Signed
Long
-2147483648 +2147483647
Holding Register
400001 - 465536
R/W
register
0-65535
Holding Register
- Float
F400001 465535
R/W
float num.
Holding Register
- Long
L400001
L465535
R/W
long num.
0-4294967295
Holding Register
- Time
T400001 T465535
R/W
string
0D0H0M0S0M
s49D17H2M47S
295Ms
Holding Register
- Sign
S400001 S465536
R/W
16 bits
Signed
Integer
-32768 +32767
Holding Register
- Double
D400001 D465533
R/W
64 bits
Floating
Point
Holding Register
- Signed Long
SL400001 SL465535
R/W
32 bits
Signed
Long
Holding Register
- Write Only
W400001 W465536
-2147483648 +2147483647
35
600000 - 699999
R/W
register
0-65535
Extended
Memory - Float
F600000 F699998
R/W
float num.
Extended
Memory - Long
L600000
L699998
R/W
long. num.
0-4294967295
Extended
Memory - Time
T600000 T699998
R/W
Time
Format
0D0H0M0S0M
s49D17H2M47S
295Ms
Extended
Memory - Sign
S600000 S699999
R/W
16 bits
Signed
Integer
-32768 +32767
Extended
Memory Double
D600000 D699996
R/W
64 bits
Floating
Point
Extended
Memory - Signed
Long
SL600000 SL699999
R/W
32 bits
Signed
Long
-2147483648 +2147483647
Extended
Memory - Write
Only
W600000 SL699998
Event Status
EV0 EV191
bit
0-1
Alarm Status
AL0 AL191
bit
0-1
NOTE
1
36
NOTE
Some applications (for example, Microsoft Excel) require an identifier with special
characters enclosed in single quotes.
and
Server: DBSR
Or:
Link: DBSR|PCIM!3:2:40004
and
Link: DBSR|PCIM!3:2:40004:12
37
Conversions
The driver supports algorithms that convert the data received by the driver from the PLC
into different format and/or different scaling. The algorithms operate bidirectionally.
Conversions can be used in the Pulse database, together with the fields Conversion, Low
scale and High scale for specific block types. Driver conversions can also be accessed at
runtime with the DBSR, PFWDRVR and Modbus server. The syntax is described below:
Server|Topic!Item,Conv
where Conv is one of the driver supported conversions
For example:
The DDE specification for conversion DIV10 of the address 40004 is:
Link: DBSR|PCIM!3:2:40004,DIV(10)
The DDE specification for conversion LIN1 of the address 40004 is:
Link: DBSR|PCIM!3:2:40004,LIN1(Low, High)
NOTE
address,LIN(Slow,Shigh,Clow,Chigh)
Slow: Server side low point
Shigh: Server side high point
Clow: Client side low point
Chigh: Client side high point
38
Conversion Links
The LIN, LIN1, LIN2, LIN3, LIN4, LIN5, LIN6, LIN7, LIN8, LINM linear conversions map
predefined ranges of raw data into engineering units defined as low scale to high scale
ranges of an Analog Value or Analog Pointer block. The raw data is interpreted as a nonnegative binary syntax.
The linear conversion algorithms listed below have the following abbreviations:
R = Raw value
L = Low scale
E = Engineering Units value
H = High scale
Table 2:
Conv.
Raw Range
NONE
Default, no
conversion
LIN
0 - 4095
E=(R/4095)*(H-L)+L
R=4095*(E-L)/(H-L)
LIN1
0 - 1023
E=(R/1023)*(H-L)+L
R=1023*(E-L)/(H-L)
LIN2
0 - 999
E=(R/999)*(H-L)+L
R=999*(E-L)/(H-L)
LIN3
0 - 9999
E=(R/9999)*(H-L)+L
R=9999*(E-L)/(H-L)
LIN4
1000 - 4096
E=[(R-1000)/3096]*(HL)+L
R=3096*(E-L)/(HL)+1000
LIN5
4096 - 8191
E=[(R-4096)/4095]*(HL)+L
R=4095*(E-L)/(HL)+4096
LIN6
0001 - 8191
E=[(R-1)/8190]*(HL)+L
R=8190*(E-L)/(H-L)+1
-32768 - 32767
E=[(R+32768)/65535]*
(H-L)+L
R=65535*(E-L)/(H-L)32768
LIN8
0 - 65535
E=(R/65535)*(H-L)+L
R=65535*(E-L)/(H-L)
LINM
0 - 32000
E=(R/32000)*(H-L)+L
R=32000*(E-L)/(H-L)
M10
Multiplies the raw data by 10 and divides the value written to the controller
by 10.
M100
Multiplies the raw data by 100 and divides the value written to the
controller by 100
M1K
Multiplies the raw data by 1000 and divides the value written to the
controller by 1000
D10
Divides the raw data by 10 and multiplies the value written to the controller
by 10
D100
Divides the raw data by 100 and multiplies the value written to the
controller by 100
LIN7
39
Conversion
Returns
ValueOK
OK/BAD
BCD(n)
n=no. of bits
DIV(n.m)
n.m=float no.
for n=0, m=0 returns
the raw value
MUL(n.m)
n.m=float no.
LIN(eng_Lo,
eng_Hi,
raw_Lo,
raw_Hi)
The conversion
performs a clamping
operation
Byte(n)
n=1 or 2
Note
40
Nib(n)
n=1 to 4
Use the generic conversions together with the driver address to create blocks with
the Database Explorer. To prevent unpredictable results, set the conversion field
to NONE in the block.
41
$Variables
$Variables can be used to modify and read driver parameters at runtime. In a project
$Variables can be used instead of a direct address.
For example in 1:1:$port the address part of the item port":"station":"address, is
replaced by the $Variable. The following table displays driver supported $Variables. The INI
column indicates when the $variable has an INI file.
$Variable
Description
Type
R/W
INI
$PortRounding
Rounding
R/W
$PortDebugMode
$PortEmulation
$PortFailures
$PortReadAfterWrite
R/W
$PortReconnectTimeMin
R/W
$PortRetries
$PortRetriesMax
R/W
$PortScanTimeDefault
R/W
R/W
$PortSpyFileSize
R/W
$PortSpyFileSizeTotal
R/W
$PortSpyMode
R/W
$PortTimeOut
Port timeout
R/W
$PortWriteCollapse
Collapse write
R/W
$PortWriteQueueMax
R/W
R/W
$PortSpyASCII
$PortWriteReflect
42
$Variable
Description
Type
R/W
INI
$PortTransportSec
$PortTransportTest
Time
R/W
$PortRetriesPrim
$PortRetriesSec
$Variable
Description
Type
R/W
INI
$StationAdvised
R/W
$StationFailures
R/W
$StationRetries
$StationRetriesLast
$PortTransport
$PortTransport
RetAuto
$PortFailuresPrim
$PortFailuresSec
$Station Variables
$StationReconnect
TimeMin
43
$Variable
Description
Type
R/W
INI
R/W
$StationRetriesLast
Prim
$StationRetries
Prim
$StationFailures
Prim
$StationRetries
LastSec
$StationTransport
$StationRetriesSec
$StationFailuresSec
44
$Modem Variables
$Variable
Description
Typ
e
R/W
INI
$PortModemConnect
Interval
R/W
$PortModemConnect
IntervalUnit
R/W
$PortModemConnect
Perm
R/W
$PortModemDialin
$PortModemDialin
IDWait
R/W
R/W
R/W
R/W
$PortModemDialout
RestoreTime
R/W
$PortModemUsed
If a modem is used
$StationModem
Connected
R/W
$StationModem
ConnectedTime
R/W
R/W
$PortModemDialin
Mode
$PortModemDialin
Rings
$PortModemDialout
Attempts
$PortModemDialout
AttemptsMax
$PortModemDialout
Interval
$StationModem
ConnectReverse
$StationModem
DialoutNextTime
45
This message appears during startup and displays the driver name,
networking type and operation mode.
Time (HH:MM:SS) MODBUS Driver Ethernet/RS232/MBPLUS)
Port n, successfully loaded Time (HH:MM:SS) MODBUS Driver,
Port n, successfully loaded in Emulation mode!
Check that the Modbus driver started up, and in the defined mode.
Failure
Reconnection
Command
Read
Driver
PLC
This message can be displayed when scanning addresses that are not
defined in the PLC.
Time (HH:MM:SS) Modbus Driver, Port n, PLC m, Address x
OK!
Open the Add New Stations dialog box and in the Memory
Configuration field define the addresses that will not be scanned.
46
Failed to Open
Error Codes
The following error codes are used in the Alarm Summary:
Code
Description
01
The function code received in the query is not an enabled action for the slave.
When a Poll Program Complete command is issued, this code indicates that
no program function preceded it.
02
The data address received in the query is not an enabled address for the
slave.
03
A value contained in the query data field is not an enabled value for the slave.
04
05
The slave has accepted the request and is processing it. This will take a long
time. The response is returned to prevent a timeout error from occurring in
the master. The master can next issue a Poll Program Complete message to
determine if processing is completed.
06
07
The slave cannot perform the program function received in the query. This
code is returned for an unsuccessful programming request using function
code 13 or 14 decimal. The master should request diagnostic or error
information from the slave.
08
The slave tried to read extended memory, but detected a parity error in the
memory. The master can retry the request, however the slave may require
maintenance.
47
Appendix A - Specifications
Supported Protocols
Protocol Variants
Data types
No of
Programmable
Controllers
Scan Time
0 - 255 seconds
Timeout
0.5 - 50 seconds
PC Ports
COM1 to COM255
Baud Rates
Data Bits
7, 8
Stop Bits
1, 1.5, 2
Parity
Default Remote
Port
Support
Unsolicited
Messages
48
LAN No
0, 1
Data Paths
1-8
Host IP Address
Default Remote
Port
Support
Unsolicited
Messages
49
Appendix B - Checking
Communication
It is important to check that communications through the driver between Pulse server and
the PLCs are constantly normal during project development and runtime. Therefore, always
check that communications are working properly when you start to develop your project.
In the Name box, enter the string specifying the data value to check, or use immediate
alias. This string is usually composed of a PLC source, port, and an item or alias.
In the Value box, enter the value and click OK. To enter an alias, enclose between
ampersands (&alias&). The result will appear in the Status column after the Pulse
Server responds.
50
In the AFCON Pulse Program Group, open the Runtime folder and click Alarm
Handler. From the Alarm Summarys File menu, click Show Daily Log.
Scroll to the top to view all the system messages in the list.
During Pulse startup, the Alarm Summary is refreshed.
51
In the List of Loaded Drivers, check if the name of the driver is displayed in the
Assigned Ports list.
52
PQR Description
6060
53