IEC 62056-21 : Telegram structure

The LIAN 98 manual can and may not contain the complete IEC documentation, caused by legal position. Only all knowledge that is essential necessary for the LIAN 98 software operation is specified in parts in this manual. 


Detailed information to the protocol you will find in the IEC-Standard-Documentation
<IEC 62056-21:2002 - Electricity metering - Data exchange for meter reading - Part 21>.

 

Normal mode messages

 

Request message / Sign on :

Used from the master as sign on at the tariff device. The device address is optional..

 

 

Identification message :

Answer of the tariff device caused by the sign on of the master. The fields "sequence delimiter" and "mode identification " are part of the identification field and optional. 

 

 

Acknowledgement/ option select message :

A tariff device in protocol mode C or E waits after the transmission of the identification for the option selection 

 

 

Data message :

This message is normally used for the transmission of tariff data by the tariff device. Transmission starts immediately after the transmission of the identification. It is not used in the programming mode and in protocol mode E. 

 

 

Acknowledgement message :

 

Positive-acknowlege ( Acknowledge character ) "ACK" = 06 hexadecimal.

 

 

Acknowledgement message ( Repeat request ) :

 

Negative-acknowledge ( Repeat request character ) "NAK" = 15 hexadecimal.

 

 

 

 

Start character

Start character "/" = 2F hexadecimal.

End character

End character "!" = 21 hexadecimal.

Transmission request command

Transmission request command "?" = 3F hexadecimal.

Completion characters

Completion character appears always double.
"CR"  carriage return = 0D hexadecimal
"LF"  line feed          = 0A hexadecimal

Frame start character
( STX )

The frame start character  "STX" = 02 hexadecimal indicates the beginning of the calculation of the BCC. 

Frame end character
( ETX )

The frame end character "ETX" = 03 hexadecimal indicates the end of the calculation of the BCC. The ETX is included in the calculation. 

Block check character
( BCC )

The "Block check character" is the calculated length parity over the characters of the data message beginning immediately after the STX up to the included ETX .

Device address

The Device address is manufacturer-specific and may consist of maximum 32 characters. This field is optional. The characters can be digits "0...9", upper case letters and lower case letters "aA...zZ" and a space. 

Manufacturers identification

The Manufacturers identification consists of three upper case letters except the third letter, it can also be transmitted as a lower case letter. If the third letter is a lower case letter, that means that the tariff device has a minimum reaction time of 20ms instead of 200ms. If the device transmits only upper case letters it does not preclude that it does not support 20ms. 
( see <FLAG : Registered Manufacturers Identification Characters> )

Baudrate identification

The Baud rate identification is used for the baud rate changeover. The "request message", the "identification" and the "acknowledgement/option" are transmitted with an initial rate of 300 Bd ( not valid for protocol mode D ). The baud rate identification in the message is determined by the used protocol mode. 

Protocol mode A :
No baud rate changeover is provided for this mode. Each character is allowed, excepted are the characters "/", "!" and the character may not be specified as baud rate for protocol mode B or C. 

Protocol mode B with baud rate changeover :
In this mode the "acknowledgement/option" is not used.
A -   600 Bd
B -  1200 Bd
C -  2400 Bd
D -  4800 Bd
E -  9600 Bd
F - 19200 Bd
G, H and I are reserved.

Protocol mode C and E with baud rate changeover :
The "acknowledgement/option" is only used in this modes. 
0 -   300 Bd
1 -   600 Bd
2 -  1200 Bd
3 -  2400 Bd
4 -  4800 Bd
5 -  9600 Bd
6 - 19200 Bd
7, 8 and 9 are reseved.

Protocol mode D :
No baud rate changeover is provided for this mode. Data transmission is determined on 2400 Bd. The baud rate identification is always 3.

Identification

The identification is manufacturer-specific and may consist of maximum 16 characters. Each character is allowed, excepted are the characters "/", "!". The character "\" is only allowed as ESC character and only in connection with the two optional fields "sequence delimiter" and "mode identification.

Sequence delimiter

The sequence delimiter "\" = 5C hexadec is always followed by the mode identification character and occurs only with this character. This field is optional and part of the 16 characters long identification.

Mode identification character
( W )

Die Mode identification character defines the protocol mode E. The field is optional and part of the 16 characters long identification.

0 and 1 are reserved
2 - binary mode ( HDLC )
3 up to 9 are reserved

Protocol control character

The protocol control character is used in protocol mode C and E. 

0 - normal protocol procedure
1 - secondary protocol procedure
2 - HDLC protocol procedure
3 up to 9 are reserved

Mode control character

The mode control character is used in protocol mode C and E.

0 - read data
1 - programming end
2 - binary mode ( HDLC )
3 up to 5 and A up to Z is reserved for later use. 
6 up to 9 for manufacturer-specific use

 

Data block :

The data block contains the tariff values and is part of the data block. Each printable character is allowed, CR and LF included, excluded are the character "/", "!". A data block consists of a range of data lines, completed always with CR/LF. A data line contains one or more data sets. A data set describes the tariff value with address, value and unit. 

 

 

Data line :

A data line consists of maximum 78 characters and is completed with CR/LF. It consists of one or more data sets. A data set describes the tariff value with address, value and unit. The number of data lines is not limited. 

 

 

Data set :

Each data line consists of one or more data sets and is completed with CR/LF. A data set describes the tariff value with address, value and unit. Additional several boundary characters are included. 

 

 

Address,
Identification number

The address i.e identification may have a maximum size of 16 characters. Each character is allowed, excepted the characters "(", ")", "/" and "!".

Front boundary character

Front boundary character " ( " = 28 hexadecimal.

Value

The value may have a maximum size of  32 characters. Each character is allowed, excepted are the characters "(", " * ", ")", "/" and "!". The dot should be used instead of a comma for values with decimal hyphen. The hyphen is counted in the number of characters. 

Separator character

Separator character " * " = 2A hexadecimal. The character can be left out if no unit exists. 

Unit

The unit may have a maximum size of 16 characters. Each character is allowed, excepted the characters "(", ")", "/" and "!". 

Rear boundary character

Rear boundary character " ) " = 29 hexadecimal.

 

Programming mode

 

Programming command message :

It is used for programming and block data transmission 

 

 

Programming command message using optional partial blocks :

It is used for programming and block data transmission of long messages in protocol mode C.

 

 

Data message ( programming mode ) :

It is used for block data transmission. 

 

 

Data message ( programming mode ) using optional partial blocks :

Used for block data transmission of long messages in program mode C. 

 

 

Error message ( programming mode ) :

Used for block data transmission of errors. 

 

 

Break message ( programming mode ) :

 

 

 

 

 

Frame start character
( STX )

The Frame start character "STX" = 02 hexadecimal, indicates the beginning of the calculation of the BCC.

Frame end character
( ETX )

The Frame end character "ETX" = 03 hexadecimal, indicates the end of the calculation of the BCC. The ETX is included in the calculation. 

Start of Header
( SOH )

The "Start of header" character "SOH" = 01 hexadecimal, indicates the beginning of the calculation of the BCC.

End character in a partial block
( EOT )

The "End of text" character "EOT" = 04 hexadecimal.

Block check character
( BCC )

The "Block check character" is the calculated length parity over the characters of the data message beginning immediately after the STX up to the included ETX .

Command message identifier

Command message identifier :

P - Password command
W -Write command 
R - Read command 
E - Execute command
B - Exit command ( break ) 
Other characters are reserved for later use.

Command type identifier

The Command type identifier defines the variant of the command. 

Password command :
0 - data is operand for secure algorithm
1 - data is operand for comparison with internally held password
2 - data is result of secure algorithm ( manufacturer specific )
3 up to 9 is reserved for later use.

Write command :
0 - reserved for later use.
1 - write ASCII-coded data
2 - formatted communication coding method write ( optional )
3 - write ASCII-coded data with partial block ( optional )
4 - formatted communication coding method write with partial block (optional)
5 - write/ delete ASCII-coded data ( Load profil, Logbook, .. )
6 up to 9 is reserved for later use..

Read command :
0 - reserved for future use
1 - read ASCII coded data
2 - formatted communication coding method read ( optional )
3 - read ASCII coded data with partial block ( optional )
4 -  formatted communication coding method read with partial block (optional)
5 - read ASCII coded data ( Load profil, Logbook, .. )
6 - read ASCII coded data with partial block ( Load profil, Logbook, .. )
7 up to 9 is reserved for later use

Execute command :
0 - 1 reserved for later use
2 - Formatted communication coding method execute ( optional )
3 up to 9 is reserved for later use 

Break command :
0 - complete sign off
1 - complete sign off for battery operated devices using the fast wake up
     method
2 up to 9 is reserved for later use 

 

Data set ( Programming mode ) :

Each data set contains a tariff value described with address, value and unit. Additional different boundary characters are included. 

 

 

Address,
Identification number

The address ie identification may have a maximum size of 16 characters. Each character is allowed, excepted the characters "(", ")", "/" and "!".

Front boundary character

Front boundary character " ( " = 28 hexadecimal.

Value

The value may have a maximum size of 32 characters. In protocol mode C however  the value can have a maximum size of 128 characters. Each character is allowed, excepted are the characters "(", " * ", ")", "/" und "!". The dot should be used instead of a comma for values with decimal hyphen. The hyphen is counted in the number of characters.

Separator character

Separator character " * " = 2A hexadecimal. The character can be left out if no unit exists.

Unit

The unit may have a maximum size of 16 characters. Each character is allowed, excepted the characters "(", ")", "/" and "!". 

Rear boundary character

Rear boundary character " ) " = 29 hexadecimal.

 

Identification of data sets ( address/ identification number )

 

For a clear identification of the values ( active power, reactive power, ... ) the "Object Identification System" ( OBIS ) is used.

Detailed informationen to the OBIS numbering systematization you will find in the IEC Standard Documentation
<IEC 62056-61 : Electricity metering - Data exchange for meter reading – Part 61 : Object identification system ( OBIS )>

and ( only in German language available ) in the

<VDEW-Lastenheft "Elektronische Lastgangzähler">
Version 2.1.2 / 07. 11. 2003

OBIS has replaced the draft standard EDIS ( DIN 43863-3:1997 EDIS - Energie Data Identification System ) and defines the usual identifiction numbers for metering systems and data transmissions.

A OBIS code consists of six value groups which are described in the following section with A... F and characterizes the data value.

 

 

The value of group C indicates the direction of the energy flow.

The tariffs are indicated by sequential numbers. If the value is tariff independent the data are transmitted with tariff code number "1". For values that are registered in several tariff numbers the tariff counter is indicated by the tariff code number "0". The tariff number 0 is also used for not tariff-distinguished load profiles.

The value group F ( pre-value identifier ) is only used for the transmission of pre-values.

 

Systematics for electric energy

Value group   Meaning Number characters
A Medium
0
1
2
3
4
5
6
7
8
9
 
Abstract objects
Electricity
.
.
Heating costs
Cooling energy
Heat
Gas
Water ( cold )
Warm water
1
Separator - 2DH 1
B Channel
1
 
In electricity, the channel is irrelevant and is set normally to "1".
1 or 2
Separator : 3AH 1
C Measuring type
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14

21
22
23
24
25
26
27
28
29
30
31
32
33

41
42
43
44
45
46
47
48
49
50
51
52
53

61
62
63
64
65
66
67
68
69
70
71
72
73

94

special characters

C
F
L
P
 
general purpose objects
Σ Li active power + ( import )
Σ Li active power - ( export )
Σ Li reactive power +
Σ Li reactive power -
Σ Li reactive power Q I
Σ Li reactive power Q II
Σ Li reactive power Q III
Σ Li reactive power Q IV
Σ Li apparent power +
Σ Li apparent power -
 
 
power factor
frequency

L1 active power +
L1 active power -
L1 reactive power +
L1 reactive power -
L1 reactive power Q I
L1 reactive power Q II
L1 reactive power Q III
L1 reactive power Q IV
L1 apparent power +
L1 apparent power -
L1 phase A current
L1 phase A voltage
L1 power factor

L2 active power +
L2 active power -
L2 reactive power +
L2 reactive power -
L2 reactive power Q I
L2 reactive power Q II
L2 reactive power Q III
L2 reactive power Q IV
L2 apparent power +
L2 apparent power -
L2 phase B current
L2 phase B voltage
L2 power factor

L3 active power +
L3 active power -
L3 reactive power +
L3 reactive power -
L3 reactive power Q I
L3 reactive power Q II
L3 reactive power Q III
L3 reactive power Q IV
L3 apparent power +
L3 apparent power -
L3 phase C current
L3 phase C voltage
L3 power factor

country specific OBIS codes for different countries



Serviceangaben
Error messages
List objects
Data profiles, Load profile P.01/ P.02, Logbook P.98/ P.99
1 or 2
Separator . 2EH 1
D Measuring variable
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16

21
22
23
24
25
26
27
28
29

55

58

special characters

F
 
 
cumulative minimum 1
cumulative maximum 1
minimum 1
average value 1 current measuring period
average value 1 last measuring period
maximum 1
instantaneous value
energy
Zeitintegral 2
Zeitintegral 3
cumulative minimum 2
cumulative maximum 2
minimum 2
average value 2 current measuring period
average value 2 last measuring period
maximum 2

cumulative minimum 3
cumulative maximum 3
minimum 3
average value 3 current measuring period
average value 3 last measuring period
maximum 3
 
 
energy feed

Prüfmittelwert

Prüf-Zeitintegral



Error message
1 or 2
Separator . 2EH 1
E Tariff rates
0
1
2
3
4
5
6
7
8
9
 
total
tariff 1
tariff 2
tariff 3
tariff 4
tariff 5
tariff 6
tariff 7
tariff 8
tariff 9
1
Separator * 2AH 1
F Billing periods ( Historical values ) 00... 99 1 or 2

 

General purpose objects ( Measuring type = 0 )

 

OBIS code ( C.D.E*F ) Function Number characters
0.0.0 Meter number 8
0.0.1 ( Identity number 1 ) 8
0.0.2 ( Identity number 2 ) 8
0.0.3 ( Identity number 3 ) 8
0.1.0 Billing period counter 2
0.1.2*xx Timestamp of the billing period "xx" ( YYMMDDhhmm ) 10
0.2.0 Firmware version 8
0.2.1*xx Parameter set number 8
0.2.2 Schaltuhren program number 8
0.8.6*xx Billing period "xx" duration ( day )  
0.9.0 Anzahl Tage seit letzter Rückstellung  
0.9.1 Meter time ( hhmmss ) 6
0.9.2 Meter date ( YYMMDD ) 6
0.9.5 Day of week 1

 

Country specific OBIS codes

Vereinbarungen im OBIS erlauben die Definition von landesspezifischen OBIS-Kennzahlen. Die Festlegung dieses Kennzahlenbereichs erfolgt über die Wertgruppen "C" und "D", wobei "C" den festen Wert 94 und "D" zur landesspezifischen Unterscheidung eine Landeskennzahl in Anlehnung an die Telefonvorwahl des Landes enthält. Die Werte für die Wertgruppen "E" und "F" können nun länderweise frei belegt werden. Die Werte für "A" und "B" haben weiterhin die per OBIS vorgegebene Bedeutung.

A - B : 94 . 49 . E * F

C = 94 : country specific OBIS code
D = 49 : country code for Germany

 

 

Systematics for thermic energy

Value group   Meaning Number characters
A Medium electricity, gas, water, heat, ... 1
B Channel d = differentation,       1 = vorläufiger, 2 = endgültiger Wert
p = processing status,  0 = not used
2
C Measuring type load profile, energy value 1 or 2
D Measuring variable Energiemenge ( absolut ), Bezugs-, Lieferichtung 1 or 2
E Tariff Grundvereinbarung 1
F Historical values 00... 99 1 or 2

 

 

 


MAYR Software

Wuerzburger Ring 39,  D 91056 Erlangen

Manual LIAN 98


LIAN 98 Protocol Router, Simulator and Analyzer
© Copyright 2001, 2006, 2011 by Werner Mayr. All Rights reserved.