Pricing/Info    Download   
MENU 
 Home Products About Support Contact

SmartGridware® Java Mini61850™ Client/Server SDK

Minimalist IEC61850 Software Development Kit

Product Overview

The SmartGridware® Mini61850™ Client/Server API is a simplified, 'minimalist' API and simulation suite which implements the IEC61850 protocol for both client and server role applications. It is well suited to:

  • simple simulation of IEC61850 Servers
  • simple simulation of IEC61850 clients
  • rapid prototyping of IEC61850 applications
  • implementing 61850 test applications
  • implementing simple 61850 servers
  • adding customization to 61850 simulators.
  • implementing simple client and server applications



Product Features

 

The Mini61850™ API 'wraps' the full-blown SmartGridware® IEC61850 Client/Server APIs in order to hide the complexity inherent in the object model, data types and service interface. The resulting interface has a small fraction of the number of classes/methods while maintaining much of the same functionality. While not all functionality is accessible through the minimalist API it is still sufficient for a most simple IEC61850 applications.

Server API Features

  • Built-in support for all functionality provided by the full IEC61850 Server SDK
  • Simple string (flag/option) based configuration interface
  • generic 'node-handle' based model access
  • simplified control model API
  • simple association control interface
  • simple data value callback interface
  • simple data change listener interface
  • support for many CDC behaviors and data simulation
  • ACSI data model interfaces
  • IEC61850-7-2 Model Service
  • uses the SmartGridware™ Java MMS Stack as the MMS provider

Client API Features

  • Built-in support for all functionality provided by the full IEC61850 Client SDK
  • Simple string (flag/option) based configuration interface
  • generic 'node-handle' based model access
  • simplified client control interface
  • simple association monitoring
  • simple data value callback interface
  • simple data change listener interface
  • simple generic client ACSI service interface
  • ACSI data model interfaces
  • IEC61850-7-2 Model Service
  • uses the SmartGridware™ Java MMS Stack as the MMS provider

Supported Standards

 

The functionality provided by the SmartGridware® IEC61850 Client SDK is implemented in compliance with the following standards (click to view):



IEC61850 Standards

  • IEC 61850-7-1: Principles and models
  • IEC 61850-7-2: Abstract Communication Service Interface (ACSI)
  • IEC 61850-7-3: Common Data Classes
  • IEC 61850-7-4: Logical Node Classes
  • IEC 61850-8-1: Service Mapping: ACSI Mappings to MMS & GOOSE
  • IEC 61850-6-1: Configuration Description Language (SCL)

IEC61850 Upper Layer Protocol Support

  • IEC61850-8-1 Client/Server Services (MMS) (6.2.1)
  • IEC61850-8-1 Client/Server A-Profile (6.2.2)
  • IEC61850-8-1 GOOSE/GSE A-Profile (6.2.2)
  • IEC61850-8-1 TCP/IP T-Profile (RFC1006) (6.2.3)
  • IEC61850-8-1 GOOSE over ISO/IEC 8802-3 (No link redundancy)

Manufacturing Message Specification (MMS) Standards

  • ISO 9506-1: Manufacturing Message Specification - Service Definitions
  • ISO 9506-2: Manufacturing Message Specification - Protocol Definitions

OSI Stack and Lower Layer Standards

  • RFC 1006: OSI over TCPIP (CMIP/OSI over TCP/IP)
  • ITU-T X.214 | ISO/IEC 8072: OSI - Transport Service Definition
  • ITU-T X.224 | ISO/IEC 8073: OSI - Transport Protocol Specification
  • ITU-T X.215 | ISO/IEC 8326: OSI - Session Service Definition
  • ITU-T X.225 | ISO/IEC 8327: OSI - Session Protocol Specification
  • ITU-T X.216 | ISO/IEC 8822: OSI - Presentation Service Definition
  • ITU-T X.226 | ISO/IEC 8823-1: OSI - Presentation Protocol Specification
  • ITU-T X.217 | ISO/IEC 8649:   ACSE Service
  • ITU-T X.227 | ISO/IEC 8650-1: ACSE Protocol
  • ITU-T X.680 | ISO/IEC 8824-1..4: Abstract Syntax Notation One (ASN.1)
  • ITU-T X.690 | ISO/IEC 8825-1: ASN.1 Encoding Rules (BER/DER/CER)

 

Client and Server API Examples

The following examples show how to configure and customize the SmartGridware® Java Mini61850™ Client/Server SDK (click to view):



Mini61850™ Server Initialization

  Mini61850Api api = new Mini61850Api();


   // -- 
   // -- Create a new server instance with the provided options... 
   // -- 
   Mini61850Server server = api.newServer("-scl:strict SGWDeviceA1.icd -xt MySim ;

   server.startServer();
         

Server API Association Example


   // -- Attach an association listener to handle new associations 
   // -- and association changes

   server.setAssocHandler(new AssocHandler()
   {
      // -- authenticate an incoming association request using authentication 
      // -- info if provided. throw an exception to deny an association request.
     public String authenticate(AssocHandle assoc, 
                                String auth_info) throws MiniServiceException
      {
         System.out.println("[authenticate]:"+assoc+",auth-info:"+auth_info);
         return null;
      }

      // -- invoked when an association state changes. 
      public void associationChanged(AssocHandle assoc)
      {
         System.out.println("[association]["+assoc.getStatus()+"]:"+assoc);
      }
   });

         

Server Control Handler

      // -- 
  // -- Set an Operation handler to process test/operate states on controls
  // -- 
  server.setOpHandler(new OpHandler()
  {
     // -- performTest is invoked for PARAMETER, INTERLOCKING, SYNCHRO tests. 
     // --
     public boolean performTest(Op op, Object ctl_val, 
                                OPTEST op_test) throws MiniControlException
     {
        System.out.println(op+"[perform-test]:"+op_test+"/ctl-val="+ctl_val);
        // -- May throw a MiniControlException for failed tests
        return false; // tell the API to also perform default tests
     }

     // -- performOperate is invoked to operate the control once all tests 
     // -- have passed. If the operate fails, the MiniControlException may 
     // -- be thrown to notify the failure for enhanced security operations. 
     public Object performOperate(Op op, Object ctl_val) 
                                  throws MiniControlException
  
     {
        System.out.println(op+"[perform-operate]OPERATE/ctl-val="+ctl_val);

        // -- perform actual output control here... 
        return ctl_val;
     }
     // -- Setting the control handler for multiple controls
  }, "ExGGIO1.AnOut1", "ExGGIO1.SPCS01");

         

Server API Model Access

   // -- Get a NodeHandle that represents the ExGGIO1 LN
   NodeHandle exggio1_handle = server.getNodeHandle("ExGGIO1");

   // -- print out ExGGIO1 structure
   System.out.println(exggio1_handle);

   // -- get and print the instMag value
   int current_mx_val = server.getNumber("ExGGIO1.AnIn1.instMag").intValue();
   System.out.println("ExGGIO1.AnIn1.instMag: " + current_mx_val);

   NodeHandle lln0_handle = server.getNodeHandle("SGWDeviceA1/LLN0");
   NodeHandle alm1_handle = server.getNodeHandle("ExGGIO1.Alm1");
   // -- iterate over Alm1's children and print out child value
   for (NodeHandle child : alm1_handle.getChildren())
   {
      System.out.println("  child[" + child.getName() + "] == " 
                          + child.getValueNotation());
   }
         

Mini61850™ Client Initialization

   Mini61850Api api = new Mini61850Api();

   // -- Create a new Client initialized from the provided ICD file. This will
   // -- populate the data structures in the local memory for API access. 
   // --    -scl <scl-filename> : The SCL filename
   // --    -retry <period>    : set the association retry period 
   Mini61850Client client =  api.newClient(
            "-scl SGWDeviceA1.icd -retry 5s -cli -a 'user#admin passwd#pass'");

         

Client GetNameList & GetData Values Example


   // -- Get list of all data names from the Server
   List<String> data_names = client.performGetDirectory(DIRTYPE.DATA);
   System.out.println("DATA: " + data_names);


   // -- perform a GetDataValues on all LNs in the Server
   // -- to refresh the values in the local model 
   client.performGet);

         

Client Association and RCB Reservations

   // -- Attach a listener to the client to receive changes in association status
   // -- The listener will be invoked immediately if the association is already up.
   client.setAssocListener(new AssocListener()
   {
      public void associationChanged(AssocHandle assoc)
      {
         if (assoc.getStatus() == ASSOC_STATUS.UP)
         {
            // -- refresh the local data and reserve RCB(s)
            try
            {
               // -- refresh ALL the local data mode through GetDataValues
               // -- requests again the server
               assoc.getClient().performGet();

               // -- reserve RCBs to get events. 
               String rcb = assoc.getClient().performReserveRCB(true,
                                               "ExGGIO1.IOValues");
            }
            catch (Exception ex)
            {
               System.out.println("Cannot refresh/reserve RCB: " + ex);
            }
         }
      }
   });

         

Client Change Listener

   // -- Attach a change listener to the client for the specified LD. 
   client.addChangeListener(new StringChangeListener()
   {
      // -- invoked for each leaf node change received from server
      public void valueChanged(NodeHandle reg_node,
                               NodeHandle chg_node,
                               String old_value,
                               String new_value)
      {
         System.out.println("[changed][" + chg_node.getReference()+"]: "
                 + old_value + " ==> " + new_value);
      }
   }, "SGWDeviceA1");
         

Client SetDataValues Example


   NodeHandle exggio1 = client.getNodeHandle("ExGGIO1");

   // -- set some values on the server
   Map<String, Object> set_result = exggio1.performSet(
           "AnOut1.minVal", 90,
           "AnOut1.maxVal", 1000,
           "AnOut1.stepSize", 80);

         

Data Value Accessors

   // -- Use the NodeHandle API to get some values and print them out. 

   NodeHandle lln0 = client.getNodeHandle("LLN0");

   String beh = lln0.getString("Beh.stVal");
   int beh_int = lln0.getNumber("Beh.stVal").intValue();

   String health = lln0.getString("Health.stVal");
   int health_int = lln0.getNumber("Health.stVal").intValue();

   System.out.println("\nLLN0.Beh:   "+beh+"("+beh_int+")\n");
   System.out.println("\nLLN0.Health:"+health+"("+health_int+")\n");

         

Client Operate Control

   try
   {
      // -- operate the AnOut1 control to change the mxVal
      exggio1.performOperate("AnOut1", 100,
                              OPFLAG.INTERLOCKING, OPFLAG.SYNCHRO);
   }
   catch (MiniException ex)
   {
      System.out.println("ERROR: " + ex);
   }
         

Data Simulation Functions SCL Configuration

  <DOI name="CntRs1">
    <Private type="MySim">
       <!-- To enable simulation use option '-xt MySim' -->
       <SvXt:CounterSim ref="actVal" maxVal="1000" 
                        minVal="0" inc="1" sample="5/m" 
                        updateTime="true" inhibitChange="false" />
    </Private>
    <DAI name="frPd">
       <Val>5000</Val>
       </DAI>
       <DAI name="frRs">
       <Val>false</Val>
    </DAI>
  </DOI>

  <DOI name="AnIn1">
     <Private type="MySim">
        <!-- To enable simulation use option '-xt MySim' -->
        <SvXt:FunctionSim ref="instMag" maxVal="100" minVal="0" 
                          freq="1/m" sample="0" function="sine" 
                          updateTime="false" inhibitChange="true" />
        </Private>
         

Client Command Tool Interface


   alias [{alias-name}] | alias add {alias} {cmd} {args}* | alias del {alias}

   assoc (-auth {auth-info-regex} |-abort|-release|-accept|-reject|-noauth
   | -inhibit | -allow

   get  {object-ref}+   : perform a GetDataValues operation

   getnamelist [LD|DA|DS|LOG]   : perform a GetNameList operation

   help {command-name}

   info  [{ied-label}]   : print detailed info about the IED logging

   list {type} {regex}* : list elements. {type}= client|ld|ln|fc|vdo|da|ds|rcb

   listen (-r[egister]  {node-ref}* ) | -i[nhibit] | -a[llow] | -u[nregister]

   operate [-sbo|-sbow|-cancel] [options] {ctl-do} {ctl-value}:operate a control

   print   {data-name}+   : print out the specified data

   quit  : exit the application .

   rcb (-reserve {args} *) |  (-unreserve {rcb-name})

   set [{da-name} {da-value}]+ : one or more DA values.

   status

   usage {command-name}

   verbose  [true|false]   : change verbose output status

   - history operations -

   ! | h[istory]     : print command history

   !!                : exec last command

   !{cmd#}           : exec command # {cmd#}

   !{cmd#}  {alias}  : create an alias for command # {cmd#}

         

Simulator Command Line Interface

available commands:
            
   alias [{alias-name}]  |  alias add {alias} {cmd} {args}*  
                   |  alias del {alias} 
            
   assoc (-auth {auth-info-regex} | -abort | -release | -accept 
        | -reject | -noauth | -inhibit | -allow 
            
   control [OPTIONS] {control-DO}  :  configure a control
           
   help {command-name}

   info  [{ied-label}]   : print detailed info about the IED logging

   list {type} {regex}* : list. {type}= server|ld|ln|fc|vdo|da|ds|rcb|
   
   listen (-r[egister]  {ref}* ) | -i[nhibit] | -a[llow] | -u[nregister]

   print   {data-name}+   : print out the specified data

   quit  : exit the application .

   set [{da-name} {da-value}]+ : one or more DA values.

   status

   usage {command-name}

   verbose  [true|false]   : change verbose output status
            
   - history operations - 
            
   ! | h[istory]     : print command history
   
   !!                : exec last command

   !{cmd#}           : exec command # {cmd#}

   !{cmd#}  {alias}  : create an alias for command # {cmd#}
         

Platform Requirements

 

Java Platform Requirements:

The Core SmartGridware® Java IEC61850 software requires the following Java Development Kit in order to develop applications:

In order to install or upgrade your installed JDK version, please visit the Oracle Java Developers page at:


GOOSE and Sampled Value Requirements:

GOOSE and/or Sampled Value components are supported for Windows, Linux and MacOS with the following requirements :

Windows GOOSE/SV Requirements

MacOSX/Linux GOOSE/SV Requirements

Operating System Requirements:

The core Client API will work on any operating system which supports the Java versions listed in the Java Platform Requirements section above. Some of the operating systems commonly used with SmartGridware™ products are:

  • Microsoft Windows (95,98,XP,NT,2000,7,8)
  • Linux (Redhat, etc)
  • Hewlett Packard HP-UX
  • Sun Solaris (SPARC & x86)
  • IBM AIX
  • Apple MacOS X

Note that for GOOSE and Sampled Value support, only Windows, MacOSX and Linux are supported and require the use of the PCAP library as detailed above

Hardware Requirements:

Minimum Hardware
  • Physical memory (RAM): 256MB
  • Disk space: 30MB (distribution package size)