Home
Categories
Dictionary
Glossary
Download
Project Details
Changes Log
What Links Here
FAQ
License

UA configuration



There are three ways to define the UA configuration:
  • uaImpl and uaPath: used when there is only one UA hosted by the UA Application, coded in Java
  • script: used when there is only one scripted UA hosted by the UA Application, coded in a Groovy script
  • uaConfig: used when there are more than one UA hosted by the UA Application
The a661Config parameter is mandatory and used in all of these ways. It specifies the configuration properties of the ARINC 661 Server. See a661Config for more information.

Using the uaImpl and uaPath properties

The uaImpl and uaPath properties specify the jar file and the path of the class which implements the User Application:
  • The uaImpl property specifies the jar file
  • The uaPath property specifies the path of the UA. This class must be a subclass of org.da.uaappli.AbstractFunctionalUA[1]
    See also Developing a UA

Using the script property

The script property specify the path of the Groovy script which implements the User Application. See Developing a scripted UA for more information.

Using the uaConfig property

The uaConfig property specifies the jar files and the paths for the classes which implement the User Application.

Schema

The schema is: uaConfig.xsd. There are two types of elements under the root:
  • The "ua" element, for Java-coded User Applications
  • The "script" element, for scripted User Applications

Java User Applications

Main Article: UaConfig tutorial

Each ua element has the following properties:
  • url: the jar file
  • path: the path of the UA. This class must be a subclass of org.da.uaappli.AbstractFunctionalUA[1]
    See also Developing a UA
  • defaultSusbcribeService: the name of the default subscribed service for the UA
  • defaultProvideService: the name of the default provided service for the UA
  • connectionDelay: the delay to all the FunctionalUA.connected() method for the UA

Scripted User Applications


Each script element has the following properties:
  • url: the path of the groovy script
  • defaultSusbcribeService: the name of the default subscribed service for the UA
  • defaultProvideService: the name of the default provided service for the UA
  • connectionDelay: the delay to all the FunctionalUA.connected() method for the UA. See also connectionDelay property for more information

Subscriptions

The susbcribe children specify the Services on which the UA susbcribe to. The UA application will defer notifications from Services it receives only to the UAs which subscribe to these Services[2]
Note that several UAs can subscribe to the same Service
.

Subscriptions entry points

It is possible to specify a specific method which will be invoked for the notification rather than the default one. This is specified by the entryPoint children under the susbcribe element. For example:
      <script url="myScript.groovy">
         <subscribe service="published">
            <entryPoint method="customSubscribe" />
         </subscribe>
      </script>
      <ua url="../modules/uacas/uaCAS.jar">
         <subscribe service="published">
            <entryPoint method="customSubscribe" />
         </subscribe>
      </ua>

Cyclic methods

As it is the case for Java modules, it is possible to declare cyclic methods for the User Application. These methods will be called cyclically without invoking any Service.

For example:
      <uas>
         <ua url="../modules/pfd/EasyPFD.jar" path="org.da.easypfd.EasyPFD" defaultSubscribeService="scenario" >
            <susbcribe service="scenario" />
            <cyclicMethod method="myMethod" frequency="100ms" />
         </ua>
      </uas>
In this example, myMethod() method of the org.da.easypfd.EasyPFD class will be called every 100 ms.

Declared Layers

It is possible to declare a limited list of Layers which will be used in the Functional UA runtime API. The declaration is performed inside the layers node, in layer elements:
  • The appliID attribute is the appplication ID of the layer
  • The layerID attribute is the layer ID of the layer
  • The defaultLayer attribute is an optional boolean, which is equal to true if it will be used as the default layer for the runtime API

If there is no layer with a defaultLayer attribute set to true, then the last declared layer will be considered as the default layer. it means that if we only declare one layer, this will be the default layer.


It will be possible to use these Layers by their name.

Example

For example, if you have the following Definition File:
      <a661_df name="Default" library_version="0" supp_version="6">
         <model>
            <prop name="ApplicationId" value="1" />
         </model>
         <a661_layer name="TheLayer1" >
            <model>
               <prop name="LayerId" value="1" />
               <prop name="ContextNumber" value="0" />
               <prop name="Height" value="3000" />
               <prop name="Width" value="8000" />
            </model>
            <a661_widget name="label" type="A661_LABEL">
               <model>
                  <prop name="WidgetIdent" value="2" />
                  <prop name="Anonymous" value="A661_FALSE" />
                  <prop name="Visible" value="A661_TRUE" />
                  <prop name="PosX" value="5106" />
                  <prop name="PosY" value="1138" />
                  <prop name="SizeX" value="2741" />
                  <prop name="SizeY" value="1000" />
                  <prop name="RotationAngle" value="0.0" />
                  <prop name="StyleSet" value="0" />
                  <prop name="MaxStringLength" value="20" />
                  <prop name="MotionAllowed" value="A661_TRUE" />
                  <prop name="Font" value="F3" />
                  <prop name="ColorIndex" value="white" />
                  <prop name="Alignment" value="A661_CENTER" />
                  <prop name="LabelString" value="0" />
               </model>
            </a661_widget>
         </a661_layer>
         <a661_layer name="TheLayer2" >
            <model>
               <prop name="LayerId" value="2" />
               <prop name="ContextNumber" value="0" />
               <prop name="Height" value="3000" />
               <prop name="Width" value="8000" />
            </model>
            <a661_widget name="label" type="A661_LABEL">
               <model>
                  <prop name="WidgetIdent" value="2" />
                  <prop name="Anonymous" value="A661_FALSE" />
                  <prop name="Visible" value="A661_TRUE" />
                  <prop name="PosX" value="5106" />
                  <prop name="PosY" value="1138" />
                  <prop name="SizeX" value="2741" />
                  <prop name="SizeY" value="1000" />
                  <prop name="RotationAngle" value="0.0" />
                  <prop name="StyleSet" value="0" />
                  <prop name="MaxStringLength" value="20" />
                  <prop name="MotionAllowed" value="A661_TRUE" />
                  <prop name="Font" value="F3" />
                  <prop name="ColorIndex" value="white" />
                  <prop name="Alignment" value="A661_CENTER" />
                  <prop name="LabelString" value="0" />
               </model>
            </a661_widget>
         </a661_layer>         
      </a661_df>
In the following example, we have two declared Layers, and the second will be used as the default Layer:
      <uas>
         <ua url="MyUA.jar" path="my.uaappli.UA1" defaultSubscribeService="published"> 
            <layers>
               <layer appliID="1" layerID="1" />
            </layers>
            <subscribe service="published" >
               <entryPoint method="subscribe" />
            </subscribe>
         </ua>
         <ua url="MyUA.jar" path="my.uaappli.UA2" defaultSubscribeService="published"> 
            <layers>
               <layer appliID="1" layerID="2" defaultLayer="true" />
            </layers>
            <subscribe service="published" >
               <entryPoint method="subscribe" />
            </subscribe>
         </ua>         
      </uas>
In that case the Functional UA runtime API will only be configured for:
  • The Layer of AppliID 1 and LayerID 1, with the name "TheLayer1"
  • The Layer of AppliID 1 and LayerID 2, with the name "TheLayer2", declared as the default Layer

Example

      <uas>
         <ua url="../modules/pfd/EasyPFD.jar" path="org.da.easypfd.EasyPFD" defaultSubscribeService="scenario" >
            <susbcribe service="scenario" />
         </ua>
      </uas>

Notes

  1. ^ [1] [2] See also Developing a UA
  2. ^ Note that several UAs can subscribe to the same Service

See also


Categories: builtin-applis | uaappli

Copyright 2017-2020 Dassault Aviation. All Rights Reserved. Documentation and source under the LGPL v3 licence