Difference between revisions of "Extensions.DiagDataBrowsing.ComChannelCategory"

From emotive
Jump to navigation Jump to search
 
(3 intermediate revisions by one other user not shown)
Line 27: Line 27:
  
 
==Literal==
 
==Literal==
The syntax for [[Literals| Literals for complex data types]] should be used, where the '''member value''' is one of the values in the list.
+
The syntax for [[Literals| Literals for complex data types]] will be used, where the '''member value''' is one of the values in the list.
  
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
@ComChannelCategory:{BASE_VARIANT|FUNCTIONAL_GROUP|PROTOCOL}
+
@ComChannelCategory:BASE_VARIANT|FUNCTIONAL_GROUP|PROTOCOL
 
</syntaxhighlight>
 
</syntaxhighlight>
  
Line 40: Line 40:
 
==Sample==
 
==Sample==
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
DiagDataBrowsingPlus.McdDataType McdDataTypeVariable1 = @McdDataType:ASCIISTRING;
+
DiagDataBrowsing.ComChannelCategory ComChannelCategoryVariable = @ComChannelCategory:BASE_VARIANT;
 
</syntaxhighlight>
 
</syntaxhighlight>

Latest revision as of 10:34, 12 September 2019

Classification

Name ComChannelCategory
Short Description The category of a communication channel
Class Simple Data Type
Base Data Type SimpleType
Default Value BASE_VARIANT
Provide a Literal Yes
SpecifiedBy ISO 13209-3
Standard Compliant Yes

Description

ComChannelCategory is an enumeration type describing the category of a ComChannel.

The list of allowed enumeration values is defined as follows:

Value Literal Description
BASE_VARIANT @ComChannelCategory:BASE_VARIANT A ComChannel of this category references a base variant that is the common denominator of a set of ECU variants.
FUNCTIONAL_GROUP @ComChannelCategory:FUNCTIONAL_GROUP A ComChannel of this category references a functional group of ECUs, i.e. a set of ECUs that share the same functional address.
PROTOCOL @ComChannelCategory:PROTOCOL A ComChannel of this category references a protocol-level communication link, i.e. it contains a set of diagnostic services that are commonto all ECUs implementing a specific procotol.

Order Relation

ComChannelCategory values may occur as operands of comparisons. For this case, the following order relation is defined. Started with the lowest value BASE_VARIANT = 0:

BASE_VARIANT < FUNCTIONAL_GROUP < PROTOCOL

Literal

The syntax for Literals for complex data types will be used, where the member value is one of the values in the list.

@ComChannelCategory:BASE_VARIANT|FUNCTIONAL_GROUP|PROTOCOL

Core Conversion

The following table shows the rules for conversion to another data type:

Conversion Result Sample
ToBoolean Undefined (should not be used)
ToInteger Returns the index of the value in the ComChannelCategory enumeration (smallest index is 0) Integer val = ToInteger(@ComChannelCategory:BASE_VARIANT); // Returns 0
ToFloat Undefined (should not be used)
ToString Returns the name of the enumeration value String s = ToString(@ComChannelCategory:BASE_VARIANT); // Returns "BASE_VARIANT"
ToByteField Undefined (should not be used)

Sample

DiagDataBrowsing.ComChannelCategory ComChannelCategoryVariable = @ComChannelCategory:BASE_VARIANT;