XTCE 1.3 RTF Avatar
  1. OMG Issue

XTCE13 — Inconsistent time unit data types

  • Key: XTCE13-39
  • Status: closed  
  • Source: Northrop Grumman ( Mr. Joseph Vlietstra)
  • Summary:

    XTCE v1.2 added "unit" attribute to TimeAssocationType and added a specialized data type (TimeAssociationUnitType) that is inconsistent with the existing data type (TimeUnitsType)

  • Reported: XTCE 1.2 — Fri, 22 Feb 2019 21:51 GMT
  • Disposition: Resolved — XTCE 1.3
  • Disposition Summary:

    aligned time attributes

    Improve the alignment of common values between the TimeUnitsType, TimeAlarmRangesType, TimeAssociationType, and TimeAssociationUnitType. This should include enhancing the documentation.

    First, update the attribute "timeUnits" in the "TimeAlarmRangesType" to match the similar attribute in the complex type "EncodingType". This causes the documentation to match.

    Original definition of the attribute "timeUnits" in "TimeAlarmRangesType":

    <complexType name="TimeAlarmRangesType">
    <complexContent>
    <extension base="xtce:AlarmRangesType">
    <attribute name="timeUnits" type="xtce:TimeUnitsType" default="seconds"/>
    </extension>
    </complexContent>
    </complexType>

    Updated "TimeAlarmRangesType":

    <complexType name="TimeAlarmRangesType">
    <complexContent>
    <extension base="xtce:AlarmRangesType">
    <attribute name="timeUnits" type="xtce:TimeUnitsType" default="seconds">
    <annotation>
    <documentation xml:lang="en">Time units, with the default being in seconds.</documentation>
    </annotation>
    </attribute>
    </extension>
    </complexContent>
    </complexType>

    Next enhance the documentation for the simple type "TimeUnitsType" and add additional frequently used enumerations for user convenience.

    The original definition:

    <simpleType name="TimeUnitsType">
    <annotation>
    <documentation xml:lang="en">base time units. days, months, years have obvoius ambiguity and should be avoided</documentation>
    </annotation>
    <restriction base="string">
    <enumeration value="seconds"/>
    <enumeration value="picoSeconds"/>
    <enumeration value="days"/>
    <enumeration value="months"/>
    <enumeration value="years"/>
    </restriction>
    </simpleType>

    Replace "TimeUnitsType" with this updated definition:

    <simpleType name="TimeUnitsType">
    <annotation>
    <documentation xml:lang="en">Base time unit of measure. It is best practice to avoid days, months, and years due to ambiguity involving leap seconds and leap days. If these are used, the system should document how the leaps are handled.</documentation>
    </annotation>
    <restriction base="string">
    <enumeration value="seconds"/>
    <enumeration value="milliseconds"/>
    <enumeration value="microseconds"/>
    <enumeration value="nanoseconds"/>
    <enumeration value="picoseconds"/>
    <enumeration value="minutes"/>
    <enumeration value="hours"/>
    <enumeration value="days"/>
    <enumeration value="months"/>
    <enumeration value="years"/>
    </restriction>
    </simpleType>

    To be consistent with the "TimeUnitsType", update the "TimeAssociationUnitType" to match.

    Original definition of "TimeAssociationUnitType":

    <simpleType name="TimeAssociationUnitType">
    <annotation>
    <documentation>Time units the time association decimal value is in.</documentation>
    </annotation>
    <restriction base="string">
    <enumeration value="si_nanosecond"/>
    <enumeration value="si_microsecond"/>
    <enumeration value="si_millsecond"/>
    <enumeration value="si_second"/>
    <enumeration value="minute"/>
    <enumeration value="day"/>
    <enumeration value="julianYear"/>
    </restriction>
    </simpleType>

    Modified definition of "TimeAssociationUnitType":

    <simpleType name="TimeAssociationUnitType">
    <annotation>
    <documentation>Time units the time association decimal value is in.</documentation>
    </annotation>
    <restriction base="string">
    <enumeration value="seconds"/>
    <enumeration value="milliseconds"/>
    <enumeration value="microseconds"/>
    <enumeration value="nanoseconds"/>
    <enumeration value="picoseconds"/>
    <enumeration value="minutes"/>
    <enumeration value="hours"/>
    <enumeration value="days"/>
    <enumeration value="months"/>
    <enumeration value="years"/>
    </restriction>
    </simpleType>

    It is then necessary to correct the "TimeAssociationType" to reflect the updates.

    Original definition of "TimeAssociationType":

    <complexType name="TimeAssociationType">
    <annotation>
    <documentation xml:lang="en">Describes a time association consisting of an instance of an absolute time parameter (parameterRef) and this entry. Because telemetry parameter instances are oftentimes "time-tagged" with a timing signal either provided on the ground or on the space system. This data element allows one to specify which of possibly many AbsoluteTimeParameters to use to "time-tag" parameter instances with. See AbsoluteTimeParameterType.</documentation>
    </annotation>
    <complexContent>
    <extension base="xtce:ParameterInstanceRefType">
    <attribute name="interpolateTime" type="boolean" default="true">
    <annotation>
    <documentation xml:lang="en">If true, then the current value of the AbsoluteTime will be projected to current time. In other words, if the value of the AbsoluteTime parameter was set 10 seconds ago, then 10 seconds will be added to its value before associating this time with the parameter.</documentation>
    </annotation>
    </attribute>
    <attribute name="offset" type="double">
    <annotation>
    <documentation xml:lang="en">The offset is used to supply a relative time offset from the time association and to this parameter</documentation>
    </annotation>
    </attribute>
    <attribute name="unit" type="xtce:TimeAssociationUnitType" default="si_second">
    <annotation>
    <documentation xml:lang="en">Specify the units the offset is in, the default is si_second.</documentation>
    </annotation>
    </attribute>
    </extension>
    </complexContent>
    </complexType>

    Replace with the modified definition of "TimeAssociationType":

    <complexType name="TimeAssociationType">
    <annotation>
    <documentation xml:lang="en">Describes a time association consisting of an instance of an absolute time parameter (parameterRef) and this entry. Because telemetry parameter instances are oftentimes "time-tagged" with a timing signal either provided on the ground or on the space system. This data element allows one to specify which of possibly many AbsoluteTimeParameters to use to "time-tag" parameter instances with. See AbsoluteTimeParameterType.</documentation>
    </annotation>
    <complexContent>
    <extension base="xtce:ParameterInstanceRefType">
    <attribute name="interpolateTime" type="boolean" default="true">
    <annotation>
    <documentation xml:lang="en">If true, then the current value of the AbsoluteTime will be projected to current time. In other words, if the value of the AbsoluteTime parameter was set 10 seconds ago, then 10 seconds will be added to its value before associating this time with the parameter.</documentation>
    </annotation>
    </attribute>
    <attribute name="offset" type="double">
    <annotation>
    <documentation xml:lang="en">The offset is used to supply a relative time offset from the time association and to this parameter</documentation>
    </annotation>
    </attribute>
    <attribute name="unit" type="xtce:TimeAssociationUnitType" default="seconds">
    <annotation>
    <documentation xml:lang="en">Specify the units the offset is in, the default is seconds.</documentation>
    </annotation>
    </attribute>
    </extension>
    </complexContent>
    </complexType>

  • Updated: Tue, 1 Jul 2025 15:05 GMT