Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

AttributeDescriptionExpected valuesMandatory
namethis identifies the protocol stackiec104client, iec104server, tase2client, tase2server, 61850client, 61850server, etc...Yes
versionversion number of the configuration file2 digits x.y => x = major change, y = minor changeYes
redundancy_groupsarray of redundancy groups
Yes
redundancy_groups.connectionsarray of connections of a given redundancy group
Yes
redundancy_groups.connections.srv_ipIP address to remote IEC 104 serverIP addressYes
redundancy_groups.connections.portport number to remote IEC 104 serverdefault = 2404No
redundancy_groups.connections.connestablish connection at startupTRUE, FALSE, default = TRUENo
redundancy_groups.connections.startstart data transfer at startupTRUE, FALSE, default = TRUEFALSENo
redundancy_groups.k_valueMaximum number of outstanding (unacknowledged) APDU's at a given timedefault = 12, range : 1 to 32767No
redundancy_groups.w_valueAcknowledge the reception latest after this number of APDU'sdefault = 8, range : 1 to 32767No
redundancy_groups.t0_timeouttime out of connection establishmentdefault = 30 seconds, range : 1 to 255No
redundancy_groups.t1_timeouttime out for send or test APDU'sdefault = 15 seconds, range : 1 to 255No
redundancy_groups.t2_timeouttime out for acknowledges in case of no data messages (t2 < t1)default = 10 seconds, range : 1 to 255No
redundancy_groups.t3_timeouttime out for sending test framesdefault = 20 seconds, range : 1 to 172800No
redundancy_groups.rg_namethis identifies the redundancy group
Yes
redundancy_groups.tlsactivation of TLS (see tls configuration chapter for details)TRUE, FALSE, default = FALSENo
orig_addrOriginator Addressdefault = 0No
ca_asdu_sizesize of "Common Address of ASDU"default = 2 (byte), enum: 1 or 2No
ioaddr_sizesize of 'Information Object Address'default = 3 (byte), enum: 1, 2 or 3No
startupasdu_timetime to wait for startup completiondefault = 180 (seconds)Nosize

maximum

asdu_size

maximum ASDU size in transmission direction, if set to "0" => maximum possible value is automatically used.

default = 0 (byte), range : 0 to 255No
gi_timetime to wait for General Interrogation (GI) completion (time between each consecutive step of the GI fail handling process)default = 0 60 (seconds), minimum: 1No
gi_cyclesend General Interrogation (GI) cyclically for the specified period of time, if 0  => DEACTIVATEDdefault = 0 (seconds), if 0  => DEACTIVATED minimum: 0No
gi_all_casend a separate GI request to every CA; otherwise a broadcast GI request is usedTRUE, FALSE, default =  FALSETRUENo
gi_repeat_countrepeat GI for this number of times in case it is incompletedefault = 2No
disc_qualinformation object quality in case of interrupted connectionIV = Invalid, NT = Not Topical, default = NTNo
send_iv_timetime delay before infos are sent as invalid (0 = deactivated)default = 0No
tsivspecifies what to do with a time stamp marked as 'invalid'

remove, process, default = remove

remove: the time stamp will be removed from the information object

process: the time stamp will be processed on regular basis and additionally marked as 'not synchronized'

No
utc_timeUTC timezone (=TRUE) or local timezone (=FALSE) for time conversionTRUE, FALSE, default = TRUENo
cmd_wttaguse commands with time tag (=TRUE) or without time tag (=FALSE)TRUE, FALSE, default = FALSENo
cmd_parallelmaximum number of commands to be executed at in parallel (0 = unlimited)default = 0No
exec_cycl_testexecute cyclical test requests (C_TS_NA_1/C_TS_TA_1) in monitoring direction (=TRUE) or not (=FALSE)TRUE, FALSE, default = FALSENo
reverseallow transmission of information objects in reverse direction (=TRUE) or only in standard direction (=FALSE)TRUE, FALSE, default = FALSENo
time_syncperform time synchronizationdefault = 0 (seconds), if 0  => DEACTIVATEDNo

Configuration JSON structure

utc_timeUTC timezone (=TRUE) or local timezone (=FALSE) for time conversionTRUE, FALSE, default = TRUENo
cmd_parallelmaximum number of commands to be executed in parallel (0 = unlimited)default = 0No
cmd_exec_timeoutmaximum time to wait for command execution (ACT-CON/ACT-TERM) before the command is considered faileddefault = 1000 (milliseconds), minimum: 1No
reverseallow transmission of information objects in reverse direction (=TRUE) or only in standard direction (=FALSE)TRUE, FALSE, default = FALSENo
time_syncperform time synchronization cyclically for the specified period of time, if 0  => DEACTIVATEDdefault = 0 (seconds), minimum: 0No
south_monitoringconnection loss and gi failure handling feature
Yes
south_monitoring.asset

asset name used to send the connection and gi status information to the north

default = "CONSTAT-1"No
south_monitoring.cnx_loss_status_idid name (label) in the exchanged data conf of the connexion loss datapoint to be senddefault = "CONN_LOST"

NB: Parameter marked in italic are not yet implemented.

Configuration JSON structure

Code Block
languagepy
{
   "protocol_stack":{
      "name":"iec104client",
      "version":"1.0",
      "transport_layer":{
         "redundancy_groups":[
            {
               "connections":[
                  {
                     "srv_ip":"192.168.0.10",
                     "port":2404,
                     "conn":true,
                     "start":true
                  },
                  {
                     "srv_ip":"192.168.0.11",
                     "port":2404,
   
Code Block
languagejs
{
   "protocol_stack":{
      "name":"iec104client",
      "version":"1.0",
      "transport_layer":{
         "redundancy_groups":[
         "conn":true,
      {
               "connectionsstart":[false
                  {}
               ],
         "srv_ip":"192.168.0.10      "rg_name":"red-group-1",
               "tls":false,
               "portk_value":240412,
               "w_value":8,
       "conn":true,
        "t0_timeout":10,
               "startt1_timeout":true15,
                  }"t2_timeout":10,
                  {"t3_timeout":20
            },
         "srv_ip":"192.168.0.11",
   {
                  "portconnections":2404,[
                     "conn":true,{
                     "start":false
     srv_ip":"192.168.0.12",
             }
         "port":2404,
      ],
               "rg_nameconn":"red-group-1"false,
               "tls":false,
               "k_valuestart":12,false
               "w_value":8,
     },
          "t0_timeout":10,
        {
       "t1_timeout":15,
               "t2srv_timeoutip":10"192.168.0.13",
                     "t3_timeoutport":202404,
               },
      "conn":false,
      {
               "connectionsstart":[false
                  {}
               ],
               "srvrg_ipname":"192.168.0.12red-group-2",
               "tls":false,
         "port":2404,
      "k_value":12,
               "connw_value":false8,
                     "startt0_timeout":false10,
                  }"t1_timeout":15,
                  {
    "t2_timeout":10,
                 "srv_ip":"192.168.0.13",t3_timeout":20
            }
         "port":2404,]
      },
      "application_layer":{
         "connorig_addr":false0,
            "ca_asdu_size":2,
         "startioaddr_size":false3,
         "asdu_size":0,
         "gi_time":60,
   }
      "gi_cycle":0,
         ]"gi_all_ca":true,
               "rgcmd_nameparallel":"red-group-2"0,
               "tlscmd_exec_timeout":false1000,
         "time_sync":0
      "k_value":12},
      "south_monitoring":{
         "w_valueasset":8"CONSTAT-1",
               "t0_timeout":10,cnx_loss_status_id":"CONN_LOST"
               "t1_timeout":15,
               "t2_timeout":10,
               "t3_timeout":20
            }
         ]
      },
      "application_layer":{
         "orig_addr":0,
         "ca_asdu_size":2,
         "ioaddr_size":3,
         "startup_time":180,
         "asdu_size":0,
         "gi_time":60,
         "gi_cycle":false,
         "gi_all_ca":false,
         "gi_repeat_count":2,
         "disc_qual":"NT",
         "send_iv_time":0,
         "tsiv":"REMOVE",
         "utc_time":false,
         "comm_wttag":false,
         "comm_parallel":0,
         "exec_cycl_test":false,
         "startup_state":true,
         "reverse":false,
         "time_sync":false
      }
   }
}

IEC 104 datapoint representation

This is the Datapoint representation of an IEC 104 ASDU.

}
   }
}

IEC 104 datapoint representation

This is the Datapoint representation of an IEC 104 ASDU.

AttributeDescriptionExpected valuesMandatory
do_type

Yes
do_ca

Yes
do_oa

Yes
do_cot
See Cause of TransmissionYes
do_test
[0..1] (default = 0, test data object = 1)Yes
do_negative

Yes
do_ioa

Yes
do_value

SPI : [0..1]

DPI : [0..3] (M_DP)

VTI : [-64..63]

BSI : [0..232-1]

NOR : [-1..1-2-15]

AJU : [-215..215-1]

FLO : IEE 32 bits

ST : [0..216-1]

BCR : [-231..231-1]

ES : [0..3]

SPE : [0..63]

OCI : [0..15]

No
do_quality_ivInvalid

[0..1] (Valid = 0, Invalid = 1)

No
do_quality_blBlocked [0..1] (not blocked = 0, blocked = 1)No
do_quality_ovOverflow [0..1] (normal = 0, overflow = 1)No
do_quality_sbSubstituted [0..1] (not substituted = 0, substituted = 1)No
do_quality_ntNon topical [0..1] (topical = 0, not topical = 1)No
do_ts

No
do_ts_iv

No
do_ts_su

No
do_ts_sub

No


Code Block
languagepy
Code Block
languagejs
{
    "data_object":{
       "do_type":"M_SP_TB_1",
       "do_ca":18325,
       "do_oa":0,
       "do_cot":3,
       "do_test":false,
       "do_negative":false,
       "do_ioa":6468178,
       "do_value":1,
       "do_quality_iv":true,
       "do_quality_bl":false,
       "do_quality_ov":false,
       "do_quality_sb":false,
       "do_quality_nt":false,
       "do_ts":1653484330239,
       "do_ts_iv":true,
       "do_ts_su":false,
       "do_ts_sub":false
    }
 }

...

M_ME_TC
Type IDType ID with timetagAlternative format type id
M_SP_NA_1M_SP_TA_1,M_SP_TB_1M_PS_NA_1
M_DP_NA_1M_DP_TA_1,M_DP_TB_1M_EP_TA_1,M_EP_TD_1
M_ST_NA_1M_ST_TA_1,M_ST_TB_TB_1
M_BO_NA_1M_BO_TA_1,M_BO_TB_1
M_ME_NA_1M_ME_TA_1,M_ME_TD_1M_ME_ND_1
M_BOME_NANB_1M_BOME_TATB_1,M_BOME_TBTE_1
M_ME_NANC_1M_ME_TATC_1,M_ME_TDTF_1
M_MEIT_NDNA_1M_MEIT_NBTA_1,M_MEIT_TB_1,M_ME_TE_1M_ME_NC_1

Example:  any transmitted ASDU with type id M_SP_* type id is considered as valid if the exchange data configuration of a given datapoint specifies one the type id: M_SP_NA_1, M_SP_TA_1, M_

...

SP_

...

TB_1

...

and M_

...

PS_NA_1

...

Path exploration

In redundant network configuration or generally in cases where several communication paths exist between one client and one server, the path checking exploration mechanism allows the client to try all the paths one by one without making any difference between them. The client uses the first available path. On disconnection this procedure starts again from the beginning.

TLS configuration

The CS 104 standard can also be used with TLS to realize secure and authenticated connections.

Parameters are needed to set up the TLS secured connection:

AttributeDescriptionExpected valuesMandatory
private_keyclient private keyvalid private keyYES
own_certclient certificatevalid certificateYES
ca_certsallows to specify the ca certificates if not included in the owner certificatelist of valid certificatesNO
remote_certsallows to specify the server certificates, so if specified, only these certificates are acceptedlist of valid certificatesNO

Fledge's certificate store allows certificates to be stored and used by the south plugins.

Code Block
languagepy
{
   "private_key":"iec104_client.key",
   "own_cert":"iec104_client.cer",
   "ca_certs":[
      {
         "cert_file":"iec104_ca.cer"
      },
      {
         "cert_file":"iec104_ca2.cer"
      }
   ],
   "remote_certs":[
      {
         "cert_file":"iec104_server.cer"
      }
   ]

Example:  any transmitted ASDU with type id M_SP_* type id is considered as valid if the exchange data configuration of a given datapoint specifies one the type id: M_SP_NA_1, M_SP_TA_1, M_SP_TB_1 and M_PS_NA_1

Path exploration

...

In redundant network configuration or generally in cases where several communication paths exist between one client and one server, the path checking exploration mechanism allows the client to try all the paths one by one without making any difference between them. The client uses the first available path. On disconnection this procedure starts again from the beginning.

TLS configuration

The CS 104 standard can also be used with TLS to realize secure and authenticated connections.

3 parameters are needed to set up the TLS secured connection:

  • private key file
  • server certificate
  • root certificate (CA)

Fledge's certificate store allows certificates to be stored and used by the south plugins.

Code Block
languagejs
{
  "tls_conf:": {
    "private_key": "server-key.pem",
    "server_cert": "server.cer",
    "ca_cert": "root.cer"
  }
}