Hamilton EPHUM011 Programmer's Manual

pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 1 / 67
pH ARC Sensors
Modbus RTU
Programmers Manual
Firmware version:
EPHUM011
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 2 / 67
Important Notice
All rights reserved. No part of this document may be reproduced, stored in a retrieval system, or transmitted in any form without writtenpermission from HAMILTON Bonaduz AG.
The contents of this manual are subject to change without notice. Technical changesreserved. All efforts have been made to ensure the accuracy of the contents of this manual. However, should any
errors be detected, HAMILTON Bonaduz AG would greatly appreciate being informed of them. The above notwithstanding, HAMILTON Bonaduz AG can assume no responsibility for any errors in
this manual or their consequences. Copyright © 2010 HAMILTON Bonaduz AG, Switzerland.
Rev. Revision Date Author Change Description 01 22.04.2010 Ph. Arquint
R. Dietrich D. Schönfuss
Initial Version 01 for EPHUM011
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 3 / 67
Table of Content
1 MODBUS RTU GENERAL INFORMATION ............................................................................... 4
1.1 INTRODUCTION ..................................................................................................................... 4
2 PH ARC SENSOR COMMANDS IN MODBUS RTU................................................................... 5
2.1 GENERAL.............................................................................................................................5
2.2 OPERATOR LEVELS AND PASSWORDS ..................................................................................... 5
2.2.1 Reading / Setting Operator Level................................................................................. 5
2.2.2 Changing Passwords for Operator Level .....................................................................6
2.3 CONFIGURATION OF THE SERIAL RS485 INTERFACE ................................................................. 7
2.3.1 Device Address........................................................................................................... 7
2.3.2 Baud Rate................................................................................................................... 8
2.4 CONFIGURATION OF THE ANALOG INTERFACES......................................................................... 9
2.4.1 Available Analog Interfaces......................................................................................... 9
2.4.2 Available Analog Interface Modes ...............................................................................9
2.4.3 Description of the Analog Interfaces 1 and 2.............................................................. 10
2.4.4 Selection of an Analog Interface Mode...................................................................... 10
2.4.5 Configuration of the 4-20 mA Interface...................................................................... 11
2.4.6 Reading the InternallyMeasured Output Current....................................................... 17
2.5 MEASUREMENT................................................................................................................... 18
2.5.1 Definition of Measurement Channels and Physical Units ........................................... 18
2.5.2 Primary Measurement Channel 1 (pH) ...................................................................... 20
2.5.3 Primary Measurement Channel 6 (Temperature)....................................................... 22
2.5.4 Definition of the Measurement Status for PMC1 / PMC6............................................ 23
2.5.5 Secondary Measurement Channels 1-16................................................................... 24
2.6 CONFIGURATION OF THE MEASUREMENT ............................................................................... 26
2.6.1 Available Parameters................................................................................................ 26
2.6.2 PA9: Moving Average................................................................................................ 27
2.6.3 PA12: Moving Average R.......................................................................................... 30
2.7 CALIBRATION...................................................................................................................... 32
2.7.1 Available Calibration Points....................................................................................... 32
2.7.2 Definitions of Calibration Points................................................................................. 33
2.7.3 Calibration Procedure................................................................................................ 35
2.7.4 Reading the Calibration Status.................................................................................. 44
2.7.5 Currently active Calibration Parameters part 1........................................................... 48
2.7.6 Currently active Calibration Parameters part 2........................................................... 48
2.7.7 Currently active Calibration Parameters part 3........................................................... 49
2.7.8 Currently active Calibration Parameters part 4........................................................... 49
2.7.9 Special Commandsfor Calibration with VISICAL....................................................... 50
2.7.10 Calibration Standards................................................................................................ 51
2.8 SENSOR STATUS ................................................................................................................ 57
2.8.1 Temperature Ranges ................................................................................................ 57
2.8.2 Operating Hours and Counters.................................................................................. 58
2.8.3 Warnings .................................................................................................................. 59
2.8.4 Errors........................................................................................................................ 60
2.8.5 Reading Definition of SIP and CIP............................................................................. 62
2.8.6 Reading the Sensor’s Quality Indicator...................................................................... 63
2.9 SENSOR IDENTIFICATION AND INFORMATION........................................................................... 64
2.9.1 General Information .................................................................................................. 64
2.9.2 Sensor Identification.................................................................................................. 64
2.9.3 Free User Memory Space ......................................................................................... 65
2.10 SYSTEM COMMANDS ........................................................................................................... 66
2.10.1 Recall Sensor’s Factory Settings............................................................................... 66
3 ABBREVIATIONS.................................................................................................................... 66
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 4 / 67
1 Modbus RTU general information
1.1 Introduction
This document describes in detail the pH ARC Sensors Modbus RTU interface. It is addressed to software programmers.
The general information about Modbus command structures and its implementation in the HAMILTON ARC Sensor family is described in detail in Chapter 1 of the
VISIFERM DO Modbus RTU Programmers Manual”(p/n 624179/01). If you need this general information about Modbus programming, then please consult p/n 624179/01. In the present manual, only the specific command structure for the pH ARC Sensors is described. It is
valid for the firmware version:
EPHUM011 Please check the software version by reading register 1032. This present definition of the command structure is an additional document to the Operating
Instructions of the specific pH ARC Sensors. Before reading this manual, the operating instructions of the sensors should be read and understood.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 5 / 67
2 pH ARC Sensor Commands in Modbus RTU
2.1 General
In order to communicate with a pH ARC Sensor over Modbus RTU protocol a Modbus master terminal application software is needed. The Modbus RTU is an open standard and a number of free and commercial application toolkits are available.
This manual contains examples and illustrations from WinTECH Modbus Master ActiveX Control tool: WinTECH (www.win-tech.com) “Modbus Master OCX for Visual Basic”. The Modbus Organisation (www.modbus.org/tech.php) provides other links to a wide variety of Modbus terminal softwares.
In the present manual the addressing of the Modbus registers starts at 1. But the Modbusmaster protocol operates with register addresses starting at 0. Usually, the Modbus master software translates the addressing. Thus, the register address of 2090 will be translated by the Modbus master software to 2089 which is sent to the sensor (Modbus slave).
Attention: When configuring and calibrating the sensor, please limit write operations to a reasonable number. More than 100’000 write operations will physically damage the memory of the sensor. Furthermore, for the Free User Memory Space (see chapter 2.9.3), the write operations are limited to 10’000.
2.2 Operator levels and Passwords
2.2.1 Reading / Setting Operator Level
A pH ARC Sensor can be operated in three different operator levels. Each operator level allows a defined access to a specific set of commands.
Abbreviation Description Code (hex) Password (decimal) U User (lowest level) 0x03 0 A Administrator 0x0C 18111978 S Specialist 0x30 16021966
Figure 2.2.1.1: Definition of operator level and default passwords At each power up or processor reset, the operator level falls back to the default level U. The active operator level can be read and written in register 4288.
Start register
Number of registers
Reg1 / Reg2 Reg3 / Reg4 Modbus
function code
Read access
Write access
4288 4 Operator Level Password 3, 4, 16 U/A/S U/A/S
Figure 2.2.1.2: Definition of register 4288.
Command: Active operator level
Modbus address: 4288 Length: 4 Type: 3
Read Parameter: Operator level Password Format: hex decimal Value:
0x03 0
Figure 2.2.1.3: Example to read the active operator level (function code 3, start register address 4288,
number of registers 4): The active operator level is 0x03 (User). The sensor does not report the password. The value 0 is returned instead.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 6 / 67
Command: Operator level
Modbus address: 4288 Length: 4 Type: 3
Read Parameter: Operator level Password Format: Hex decimal Value:
0x30 0
Figure 2.2.1.4: Example to read the active operator level: the active level is 0x30 (Specialist). The
sensor does not report the password. The value 0 is returned instead.
Command: Operator level
Modbus address: 4288 Length: 4 Type: 16
Write Parameter: Operator level Password Format: Hex decimal Value:
0x03 0
Figure 2.2.1.5: Example to set the operator level to 0x03 (User). The password 0 has to be sent.
Command: Operator level
Modbus address: 4288 Length: 4 Type: 16
Write Parameter: Operator level Password Format: Hex decimal Value:
0x0C 18111978
Figure 2.2.1.6: Example to set the active operator level to 0xC (Administrator). The correct password
has to be sent.
Command: Operator level
Modbus address: 4288 Length: 4 Type: 16
Write Parameter: Operator level Password Format: Hex decimal Value:
0x0B 18111978
Figure 2.2.1.7: Example for a Modbus error. If the level or the password is not correct, (Operator level =
0x0B), the sensor answers with a Modbus error message “Slave device exception response (see chapter 1.6).
2.2.2 Changing Passwords for Operator Level
The passwordsfor accessing the operator levels A and S can be modified by S (Specialist) only. U (User) and A (Administrator) have no right to change any password. The new password will remain stored after power down.
Start register
Number of registers
Reg1 / Reg2 Reg3 / Reg4 Modbus
function code
Read access
Write access
4292 4 Level New password 16 None S
Figure 2.2.2.1: Definition of register 4292.
Command: Password
Modbus address: 4292 Length: 4 Type: 16
Write Parameter: Operator level Pass number Format: Hex Decimal Value:
0x30 12345678
Figure 2.2.2.2: Example to set the Password of operator level S (code 0x30) to 12345678.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 7 / 67
2.3 Configuration of the serial RS485 Interface
Factory settings of the RS485: Parity is none, 1 start bit, 8 data bits, 2 stop bits (in total: 11 bits).
2.3.1 Device Address
2.3.1.1 Reading and Writing the Device Address
The sensor specific device address can be read and written in register 4096.
Start
register
Number of registers
Reg1 / Reg2 Modbus
function code
Read access
Write access
4096 2 device address 3, 4, 16 U/A/S S
Figure 2.3.1.1.1: Definition of register 4096.
Command: Com address
Modbus address: 4096 Length: 2 Type: 3
Read Parameter: Modbus address Format: Decimal Value:
1
Figure 2.3.1.1.2: Example to read the device address. The device address can be set by S (Specialist), default value is 1.
Command: Com address
Modbus address: 4096 Length: 2 Type: 16
Write Parameter: Modbus address Format: Decimal Value:
3
Figure 2.3.1.1.3: Example to set the device address to 3.
2.3.1.2 Reading the Device Address Limits
The device address limits can be read in register 4098.
Start register
Number of registers
Reg1 / Reg2 Reg3 / Reg4 Modbus
function code
Read access
Write access
4098 4 Min. device
address
Max. device address
3, 4 U/A/S none
Figure 2.3.1.2.1: Definition of register 4098.
Command: Com address limits
Modbus address: 4098 Length: 4 Type: 3
Read Parameter: Min value Max value Format: Decimal Decimal Value:
1 32
Figure 2.3.1.2.2: Example to read the device address limits: Min = 1, Max = 32.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 8 / 67
2.3.2 Baud Rate
2.3.2.1 Reading and Writing the Baud Rate
The baud rate can be read and written in register 4102.
Start register
Number of registers
Reg1 / Reg2 Modbus
function code
Read access
Write access
4102 2 Baud rate code
(definition see below)
3, 4, 16 U/A/S S Figure 2.3.2.1.1: Definition of register 4102. The code for the baud rate is defined as follows:
Baud rate 4800 9600 19200 38400 57600 115200 Code 2 3 4 5 6 7
Figure 2.3.2.1.2: Code for the baud rates.
Command: Com baud rate
Modbus address: 4102 Length: 2 Type: 3
Read Parameter: Baud rate code Format: Decimal Value:
4
Figure 2.3.2.1.3: Example to read the baud rate code, 4 corresponds 19200 baud. The baud rate can be set by S (Specialist), default is 19200.
Command: Com baud rate
Modbus address: 4102 Length: 2 Type: 16
Write Parameter: Baud rate code Format: Decimal Value:
5
Figure 2.3.2.1.4: Example to set the baud rate to 38400 baud with code 5.
2.3.2.2 Reading the Baud Rate Limits
The baud rate limits can be read in register 4104.
Start register
Number of registers
Reg1 / Reg2 Reg3 / Reg4 Modbus
function code
Read access
Write access
4104 4 Min. Baud rate
code
Max. Baud rate code
3, 4 U/A/S none
Figure 2.3.2.2.1: Definition of register 4104.
Command: Com baud limits
Modbus address: 4104 Length: 4 Type: 3
Read Parameter: Min Baud rate code Max Baud rate code Format: Decimal Decimal Value:
2 7
Figure 2.3.2.2.2: Example to read the baud rate code limits: Min = 2, Max = 7 (see Figure 2.3.2.1.2).
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 9 / 67
2.4 Configuration of the Analog Interfaces
2.4.1 Available Analog Interfaces
A pH ARC Sensor has two individual physical analog interfaces that have identical functionalities, but can be configured independently from each other.
Analog Output Interface 1 (AO1)Analog Output Interface 2 (AO2)
The number of analog interfaces is defined in register 4320.
Start register
Number of registers
Reg1 / Reg2 Modbus
function code
Read access
Write access
4320 2 Available analog interfaces 3, 4 U/A/S none
Figure 2.4.1.1: Definition of register 4320.
Command: Avail analog interfaces
Modbus address: 4320 Length: 2 Type: 3
Read
Parameter: Available analog
interfaces Format: Hex Value:
0x03
Figure 2.4.1.2: Example to read the available analog interfaces. The answer is “0x03”meaning that
there exists an Analog Interface 1 (AO1) and an Analog Interface 2 (AO2).
2.4.2 Available Analog Interface Modes
With register 4322, the available analog interface modes for AO1 and AO2 are defined
Start register
Number of registers
Reg1 / Reg2
Reg3 / Reg4
Reg5 / Reg6
Reg7 / Reg8
Modbus function code
Read access
Write access
4322 8 Available
Analog Interface Modes for AO1
Available Analog Interface Modes for AO2
reserved reserved 3,4 U/A/S none
Figure 2.4.2.1: Definition of register 4322. It defines the analog interface modes available for AO1 and
AO2. The analog interface modes are described in Figure 2.4.2.2.
Code (Hex)
Analog Interface Mode
Description
0x00 4-20 mA inactive Analog interface deactivated 0x01 4-20 mA fixed Set to a constant output value for current loop testing 0x02 4-20 mA linear Linear output of measurement (PMC1 / 6) 0x04 4-20 mA bilinear Bilinear output of measurement (PMC1 / 6)
Figure 2.4.2.2: Definition of the analog interface modes, valid for both AO1 and AO2.
Command: Analog Interface Modes
Modbus address: 4322 Length: 8 Type: 3
Read
Parameter: Available Analog
Interface Modes for
AO1
Available Analog Interface Modes for AO2
reserved reserved
Format: Hex Hex Hex Hex Value:
0x07 0x07 0x0 0x0
Figure 2.4.2.3: Example to read register 4322: all modes defined in figure 2.4.2.2 are available for both
AO1 and AO2.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 10 / 67
2.4.3 Description of the Analog Interfaces 1 and 2
Register 4352 / 4480 contain the descriptions of AO1 / AO2 as plain text ASCII:
Start register
Number of registers
Reg1 Reg8 16 ASCII characters
Modbus function code
Read access
Write
access 4352 8 Description of AO1 3, 4 U/A/S none 4480 8 Description of AO2 3, 4 U/A/S none
Figure 2.4.2.1: Definition of register 4352 and 4480
Command: Current interface text
Modbus address: 4352 Length: 8 Type: 3
Read Parameter: Text Format: Character Value:
mA interface #1
Figure 2.4.2.2: Example to read the description of AO1. The text is mA interface #1”. Accordingly,
AO1 is physically configured as a 4-20 mA current output.
Command: Current interface text
Modbus address: 4480 Length: 8 Type: 3
Read Parameter: Text Format: Character Value:
mA interface #2
Figure 2.4.2.3: Example to read the description of AO2. The text is mA interface #2”. Accordingly,
AO2 is physically configured as a 4-20 mA current output.
Attention:
pH ARC Sensors do not have an ECS (in contrast to VISIFERM DO)!Data structure: register address offset between AO1 and AO2 is always 128.
2.4.4 Selection of an Analog Interface Mode
The analog interface mode of AO1 / AO2 is selected by programming the analog interface mode in register 4360 / 4488.
Start register
Number of registers
Reg1 / Reg2 Modbus
function code
Read access
Write
access 4360 2 Active analog interface mode for AO1 3, 4, 16 U/A/S S 4488 2 Active analog interfacemode for AO2 3, 4, 16 U/A/S S
Figure 2.4.4.1: Definition of register 4360 / 4488. Only one bit can be set.
Command: Active interface mode
Modbus address: 4360 Length: 2 Type: 16
Write Parameter: Mode Format: Hex Value:
0x02
Figure 2.4.4.2: Example to set the analog interface mode of AO1 to 0x02 (4-20 mA linear output).
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 11 / 67
2.4.5 Configuration of the 4-20 mA Interface
Note: The configuration of AO1 / AO2 is only effective if register 4360 / 4488 (active analog interface mode) is set to the value 0x01, 0x02 or 0x04.
2.4.5.1 Reading the Available Primary Measurement Channels to be Mapped to the Analog Output
Start register
Number of registers
Reg1 / Reg2 Modbus
function code
Read access
Write access
4362 2 Available Primary Measurement Channels
for AO1
3, 4 U/A/S none
4490 2 Available Primary Measurement Channels
for AO2
3, 4 U/A/S none Figure 2.4.5.1.1: Definition of register 4362 / 4490. For the definition of the Primary Measurement Channels (PMC), see chapter 2.5.
Code (Hex)
Primary Measurement Channel (PMC)
0x01 PMC1 (pH)
not available
0x20 PMC6 (temperature)
Figure 2.4.5.1.2: Code for selection of the primary measurement channel.
Command: Available PMC AO1
Modbus address: 4362 Length: 2 Type: 3
Read Parameter: Available PMC 20 mA Format: hex Value:
0x21
Figure 2.4.5.1.3: Example to read the available Primary Measurement Channels (PMC) for AO1. The
hexadecimal value of “0x21”defines that PMC1 (pH) or PMC6 (temperature) can be mapped to AO1. Register 4490 contains the same value “0x21”. Accordingly, PMC1 or PMC6 can be mapped to AO2 as well.
2.4.5.2 Selecting the Primary Measurement Channel to be Mapped to the Analog Interface
Start register
Number of registers
Reg1 / Reg2 Modbus
function code
Read access
Write
access 4364 2 Selected PMC for AO1 3, 4, 16 U/A/S S 4492 2 Selected PMC for AO2 3, 4, 16 U/A/S S
Figure 2.4.5.2.1: Definition of register 4364 / 4492. Only one bit can be set.
Command: Active PMC AO1
Modbus address: 4364 Length: 2 Type: 3
Read Parameter: Current PMC 20mA Format: hex Value:
0x01
Figure 2.4.5.2.2: Example to read the current primary measurement channel mapped to AO1, defined
in register 4364. The value “0x01”is returned, saying that PMC1 is mapped to AO1 (factory setting).
The factory setting for register 4492 is “0x20”, mapping PMC6 to AO2.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 12 / 67
2.4.5.3 Reading the Minimum and Maximum Possible Physical Output Current
Start register
Number of registers
Reg1 / Reg2 Reg3 / Reg4 Modbus
function code
Read access
Write access
4366 4 Min physical
output current for AO1 [mA]
Max physical output current for AO1 [mA]
3, 4 U/A/S none
4494 4 Min physical
output current for AO2 [mA]
Max physical output current for AO2 [mA]
3, 4 U/A/S none
Figure 2.4.5.3.1: Definition of register 4366 / 4494
Command: Limits AO1
Modbus address: 4366 Length: 4 Type: 3
Read Parameter: Min limit [mA] Max limit [mA] Format: Float Float Value:
3.5 22
Figure 2.4.5.3.2: Example to read the min and max output current of AO1. Min is fixed to 3.5 and Max
is fixed to 22 mA (Currents above 20 and below 4 mA indicate erroneous measurements or errors). The same values are stored in register 4494 for AO2.
2.4.5.4 Reading the Minimum, Maximum and Mid Current for Measurement Value Output
Start register
Number of registers
Reg1 / Reg2 Reg3 / Reg4 Reg5 / Reg6 Modbus
function code
Read access
Write access
4370 6 Min output for
measurement value for AO1 [mA]
Max output for measurement values for AO1 [mA]
Mid output (bilinear) for measurement values for AO1 [mA]
3, 4 U/A/S none
4498 6 Min output for
measurement value for AO2 [mA]
Max output for measurement values for AO2 [mA]
Mid output (bilinear) for measurement values for AO2 [mA]
3, 4 U/A/S none
Figure 2.4.5.4.1: Definition of register 4370 / 4498
Command: MinMaxMid current AO1
Modbus address: 4370 Length: 6 Type: 3
Read Parameter: Min current [mA] Max current [mA] Mid current [mA] Format: Float Float Float Value:
4 20 12
Figure 2.4.5.4.2: Example to read the min, max and mid output current for measurement values for
AO1. They are fixed to 4, 20 and 12 mA.
The same values are stored in register 4498 for AO2.
Note: Mid current must always be defined. However, in linear output mode, the mid current value has no physical meaning and will not affect the 4-20 mA output.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 13 / 67
2.4.5.5 Reading the Selected Physical Unit for Analog Interface
Start register
Number of registers
Reg1 / Reg2 Modbus
function code
Read access
Write access
4376 2 Selected physical unit of AO1
(see chapter 2.5.1)
3, 4 U/A/S none
4504 2 Selected physical unit of AO2
(see chapter 2.5.1)
3, 4 U/A/S none
Figure 2.4.5.5.1: Definition of register 4376 / 4504.
Command: Avail unit AO1
Modbus address: 4376 Length: 2 Type: 3
Read Parameter: Available unit Format: Hex Value:
0x001000
Figure 2.4.5.5.2: Example to read the selected unit of the selected PMC of AO1. The value returned is
0x001000”, accordingly, the unit is pH. The physical unit for PMC is defined in Reg. 2090 or 2410 and applies automatically for 4-20 mA output.
2.4.5.6 Defining the Measurement Values for 4, 12 and 20 mA Output
Start register
Number of registers
Reg1 / Reg2 Reg3 / Reg4 Reg5 / Reg6 Modbus
function code
Read access
Write access
4378 6 Measurement
value at Min Output Current (4 mA) for AO1
Measurement value at Max Output Current (20 mA) for AO1
Measurement value at Mid Output Current (12 mA) for AO1
3, 4, 16 U/A/S S
4506 6 Measurement
value at Min Output Current (4 mA) for AO2
Measurement value at Max Output Current (20 mA) for AO2
Measurement value at Mid Output Current (12 mA) for AO2
3, 4, 16 U/A/S S
Figure 2.4.5.6.1: Definition of register 4378 / 4506.
Command: MinMaxMid value AO1
Modbus address: 4378 Length: 6 Type: 16
Write Parameter: Min value Max value Mid value Format: Float Float Float Value:
3 10 7
Figure 2.4.5.6.2: Example to set the min value to 3 (for 4 mA), the max value to 10 (for 20 mA) and the
mid value to 7 (for 12 mA). The corresponding physical unit can be read in register 4376 / 4504 and in 2090 / 2410.
Note: Mid current must always be defined. However, in linear output mode, the mid current value has no physical meaning and will not affect the 4-20 mA output.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 14 / 67
pH ARC sensor: 4-20mA inte rface - linear
-15
-10
-5
0
5
10
15
20
25
30
35
0 4 8 12 16 20 24
Curr ent [mA]
temperature [°C]
1
2
3
4
5
6
7
8
9
10
11
pH
Temp [°C] pH
Figure 2.4.5.6.3: Example of linear 4-20 mA output characteristics for pH or temperature.
Current pH Temperature 4 mA 2 -10 °C 20 mA 9 +30 °C
pH ARC sensor: 4-20mA interface - biline ar
-15
-10
-5
0
5
10
15
20
25
30
35
0 4 8 12 16 20 24
Current [mA]
temperature [°C]
1
2
3
4
5
6
7
8
9
10
11
pH
Temp [°C] pH
Figure 2.4.5.6.4: Example of bilinear 4-20 mA output characteristics for pH or temperature.
Current pH Temperature 4 mA 2 -10 °C 12 mA 9 +20 °C 20 mA 10 +30 °C
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 15 / 67
Attention: When assigning measurement values to 4-20 mA analog output by using register 4378 / 4506, you need to consider the following:
The PMC you have mapped to AO1 / AO2 (register 4364 / 4492)The physical unit currently in use for the selected PMC (register 2090 for PMC1 (pH) and
register 2410 for PMC6 (temperature). Therefore, when the operator redefines one of the register 4364 / 4492, 2090 / 2410, the definitions of the register 4378 / 4506 should be reviewed. If not, the current output at the 4-20 mA interfaces may be wrong.
Note: The physical unit of the analog output correspondsalways to the unit that is set for the selected PMC (register 2090 for PMC1 or register 2410 for PMC6). Accordingly, not only the pH value is selectable at the 4-20 mA interface, but also mV values, degrees centigrade or Kelvin.
Example: Register 4364 is set to 1 (PMC1 is mapped to AO1). Register 2090 is set to 0x1000 (the unit “pH”is assigned to PMC1). Register 4378 is set to 2 and 10 (4 mA = pH 2, 20 mA = pH 10). The sensor reads currently pH 4, the output at the 4-20 mA is accordingly 8 mA. The operator now re-assigns register 2090 to the value of 0x200000 (unit = mV), but does not modify all other registers. The sensor is still at pH 4 and reads now +170 mV. At the analog output, as 20 mA is programmed to a value of 10 by register 4378, the current will go to the maximum value of 20 mA. This will generate an interface warning “4-20 mA current set point not met”.
2.4.5.7 Defining a Constant Current Output for Testing
Note: For constant current output, the AO1 / AO2 must be set to analog interface mode 0x01:
Start register
Number of registers
Reg1 / Reg2 Modbus
function code
Read access
Write access
4384 2 Constant current output value for
AO1 [mA]
3, 4, 16 U/A/S S
4512 2 Constant current output value for
AO2 [mA]
3, 4, 16 U/A/S S
Figure 2.4.5.7.1: Definition of register 4384 / 4512.
Command: Fixed value AO1
Modbus address: 4384 Length: 2 Type: 3
Read Parameter: Fixed value [mA] Format: Float Value:
10
Figure 2.4.5.7.2: Example to read the constant current output in mode 0x01 for AO1. It is set to 10 mA.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 16 / 67
2.4.5.8 Defining the Error and Warning Output of the 4-20 mA Interface
Errors and warnings can be mapped to the AO1 / AO2.
Start register
Number of registers
Reg1 / Reg2
Reg3 / Reg4
Reg5 / Reg6
Reg7 / Reg8
Modbus function code
Read access
Write access
4386 8 Code of
warnings and errors (see Figure
2.4.4.8.2) for AO1
Current in case of warning [mA] for AO1
Current in case of error [mA] for AO1
Current in case of T exceed [mA] for AO1
3, 4, 16 U/A/S S
4514 8 Code of
warnings and errors (see Figure
2.4.4.8.2) for AO2
Current in case of warning [mA] for AO2
Current in case of error [mA] for AO2
Current in case of T exceed [mA] for AO2
3, 4, 16 U/A/S S
Figure 2.4.5.8.1: Definition of register 4386 / 4514.
Bit # Code (hex) Behaviour of the 4-20 mA interface in case of errors and warnings 0 (LSB) 0x000001 Error continuous output
not available
16 0x010000 Warning continuous output
not available
Figure 2.4.5.8.2: Code for the 4-20 mA interface in case of errors and warnings. If the corresponding bits for the errors and warnings are not set (=0x00), the respective options are
inactive. The default settings are:
Code 0x01current in case of warnings: 3.5 mAcurrent in case of errors: 3.5 mAcurrent in case of temperature exceed: 3.5 mA
Command: ErrorWarnings AO1
Modbus address: 4386 Length: 8 Type: 3
Read
Parameter: Warning code Current in case of
warning [mA]
Current in case of error [mA]
Current in case of temperature exceed
[mA] Format: Hex Float Float Float Value:
0x010001 3.5 3.5 3.5
Figure 2.4.5.8.4: Example: Read the settings for AO1 in case of warnings and errors. Warning code
0x010001 corresponds to the continuous output current in case of warning (0x010000) and continuous output current in case of error (0x01) of 3.5 mA. The output current in case of temperature exceed is 3.5 mA.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 17 / 67
2.4.6 Reading the Internally Measured Output Current
Reg. 4414 / 4542 provides internal parameters of AO1 / AO2:
the setpoint to which the current is regulated in a closed loop controlthe electrical current the sensor is measuring to feed the closed loop control
These values are helpful in order to compare against the externally measured electrical current.
Start register
Number of registers
Reg1 / Reg2 Reg3 / Reg4 Modbus
function code
Read access
Write access
4414 4 Set point
[mA] AO1
Internally measured [mA] AO1
3, 4 U/A/S none
4542 4 Set point
[mA] AO2
Internally measured [mA] AO2
3, 4 U/A/S none
Figure 2.4.6.1: Definition of register 4414 / 4542.
Command: Internal values AO1
Modbus address: 4414 Length: 4 Type: 3
Read
Parameter: Set point
[mA]
Internally measured
[mA] Format: Float Float Value:
9.99186 9.99742
Figure 2.4.6.2: Example to read the internal values of AO1, depending on the analog interface mode.
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 18 / 67
2.5 Measurement
2.5.1 Definition of Measurement Channels and Physical Units
The pH ARC Sensor Modbus register structure allows the definition of 6 individual Primary Measurement Channels (PMC), and 16 individual Secondary Measurement Channels (SMC).
Bit # Hex code Description Definition
0 (LSB) 0x000001 PMC1 pH
1 0x000002 PMC2 not available
not available
4 0x000010 PMC5 not available
5 0x000020 PMC6 Temperature 6 0x000040 SMC1 R glass 7 0x000080 SMC2 R reference 8 0x000100 SMC3 R auxiliary 9 0x000200 SMC4 E pH vs. ref 10 0x000400 SMC5 E SG vs. ref 11 0x000800 SMC6 E aux vs. ref 12 0x001000 SMC7 E reference 13 0x002000 SMC8 pH act 14 0x004000 SMC9 T act
15 0x008000 SMC10 not available
21 (MSB) 0x200000 SMC16 not available
Figure 2.5.1.1: full list of PMC1 to 6 and SMC1 to 16. In Register 2048, the available PMC and SMC are defined for a specific pH ARC Sensors and a
specific operator level.
Start register
Number of registers
Reg1 / Reg2 Modbus
function code
Read access
Write access
2048 2 Available measurement channels
PMC and SMC (bitwise set)
3, 4 U/A/S none
Figure 2.5.1.2: Definition of register 2048.
Command: Avail. PMC and SMC
Modbus address: 2048 Length: 2 Type: 3
Read
Parameter: Avail. PMC and
SMC Format: Hex Value: 0x06E1
Figure 2.5.1.3: Example to read Reg. 2048 for Polilyte Plus ARC.
In case of operator A/U, the value 0x06E1 is returned. In other words the following PMC and SMC are available to A/U: PMC1 / PMC6 / SMC1 / SMC2 / SMC4 / SMC5 In case of operator S, the value 0x066E1 is returned. In other words the following PMC and SMC are available to S: PMC1/ PMC6 / SMC1 / SMC2 / SMC4 / SMC5 / SMC8 / SMC9
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 19 / 67
The pH ARC Sensor register structure uses the followingphysical units used for Primary or Secondary Measurement Channels.
Bit # Hex code Physical unit Start register. (8 ASCII characters, length 4 registers,
Type 3, read for U/A/S) 0 (LSB) 0x00000001 none 1920 1 0x00000002 K 1924 2 0x00000004 °C 1928 3 0x00000008 °F 1932 4 0x00000010 %-vol 1936 5 0x00000020 %-sat 1940 6 0x00000040 ug/l ppb 1944 7 0x00000080 mg/l ppm 1948 8 0x00000100 g/l 1952 9 0x00000200 uS/cm 1956 10 0x00000400 mS/cm 1960 11 0x00000800 1/cm 1964 12 0x00001000 pH 1968 13 0x00002000 mV/pH 1972 14 0x00004000 kOhm 1976 15 0x00008000 MOhm 1980 16 0x00010000 pA 1984 17 0x00020000 nA 1988 18 0x00040000 uA 1992 19 0x00080000 mA 1996 20 0x00100000 uV 2000 21 0x00200000 mV 2004 22 0x00400000 V 2008 23 0x00800000 mbar 2012 24 0x01000000 Pa 2016 25 0x02000000 Ohm 2020 26 0x04000000 %/°C 2024 27 0x08000000 ° 2028 28 0x10000000 not used 2032 29 0x20000000 not used 2036 30 0x40000000 not used 2040 31 (MSB) 0x80000000 SPECIAL 2044
Figure 2.5.1.4: Definition of physical units used for PMC and SMC.
Command: Unit text
Modbus address: 1968 Length: 4 Type: 3
Read Parameter: Text Format: Character Value:
pH
Figure 2.5.1.5: Example to read the physical unit in plain text ASCII in register 1968
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 20 / 67
2.5.2 Primary Measurement Channel 1 (pH)
2.5.2.1 Description of PMC1
In register 2080, a plain text ASCII description of PMC1 is given.
Start register
Number of registers
Reg1 Reg8 16 ASCII characters
Modbus function code
Read access
Write access
2080 8 Description of PMC1 3, 4 U/A/S none
Figure 2.5.2.1.1: Definition of register 2080.
Command: PMC 1 text
Modbus address: 2080 Length: 8 Type: 3
Read Parameter: Text Format: Character Value:
pH
Figure 2.5.2.1.2: Example to read the description. It is “pH”.
2.5.2.2 Selecting the Physical Unit for PMC1
In register 2088, the available physical units for this channel are defined.
Start register
Number of registers
Reg1 / Reg2 (bitwise defined)
Modbus function code
Read access
Write access
2088 2 Available physical units of PMC1 3, 4 U/A/S none
Figure 2.5.2.2.1: Definition of register 2088.
Command: PMC1 available units
Modbus address: 2088 Length: 2 Type: 3
Read Parameter: Units Format: Hex Value:
0x201000
Figure 2.5.2.2.2: Example to read the available physical units of PMC1: pH (0x001000) + mV
(0x200000), total 0x201000.
In register 2090, the active physical unit for this channel can be selected, by choosing one of the physical units that are defined in register 2088.
Start register
Number of registers
Reg1 / Reg2 (bitwise defined)
Modbus function code
Read access
Write access
2090 2 Selected active physical unit for the
PMC1
16 none S
Figure 2.5.2.2.3: Definition of register 2090. Only one bit can be set.
Command: PMC1 set unit
Modbus address: 2090 Length: 2 Type: 16
Write Parameter: Unit Format: Hex Value:
0x1000
Figure 2.5.2.2.4: Example to set the physical unit of PMC1 to pH (0x1000).
Attention: Changing the physical unit has also an influence on the output of AO1 / AO2, as the same physical unit is active for the analog outputs. All limits of the 4-20 mA analog output have to be redefined after changing the physical unit!
pH ARC Sensors Modbus RTU Programmer’s Manual (EPHUM011)
624300/01 page 21 / 67
2.5.2.3 Reading the measurement value of PMC1
Register 2090 is also used to read the measurement values of PMC1.
Start reg.
Num­ber of reg.
Reg1 / Reg2
Reg3 / Reg4
Reg5 / Reg6
Reg7 / Reg8
Reg9 / Reg10
Modbus function code
Read access
Write access
2090 10 Selected
physical unit
Measure
-ment value of PMC1
(1)
Measure
-ment status
(2)
Min allowed value
(1)
Max allowed value
(1)
3, 4 U/A/S none
Figure 2.5.2.3.1: Definition of register 2090. Measurement value of PMC1.
(1)
Value is always in the physical unit defined in register 2090.
(2)
Definition of the status see chapter 2.5.4. All bits set to zero means: no problem.
Command: PMC1 read
Modbus address: 2090 Length: 10 Type: 3
Read Parameter: Unit Value Status Min limit Max limit Format: Hex Float Hex Float Float Value:
0x1000 4.02503 0x00 0 14
Figure 2.5.2.3.2: Example to read register 2090. Physical unit is set to pH (0x1000), PMC1 is pH
4.02503, Status is 0x00, Min allowed value is pH 0, Max allowed value is pH 14.
Command: PMC1 read
Modbus address: 2090 Length: 10 Type: 3
Read Parameter: Unit Value Status Min limit Max limit Format: Hex Float Hex Float Float Value:
0x200000 175.9922 0x00 0 954.6541
Figure 2.5.2.3.3: Example to read register 2090. Physical unit is set to mV (0x200000), PMC1 is
175.9922 mV, Status is 0x00, Min allowed value is -414.0028 mV, Max allowedvalue is
414.0028 mV.
For the definition of the measurement status see chapter 2.5.4.
Attention: You cannot read selectively the registers 3 and 4 for the measurement value only. You have to read the entire length of the command (10 registers) and extract the desired information.
Loading...
+ 46 hidden pages