<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XMLSpy v2006 rel. 3 U (http://www.altova.com) by Eugene Song (NIST) -->
<xs:schema xmlns:stml="http://localhost/1451HTTPAPI" xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://localhost/1451HTTPAPI" elementFormDefault="qualified" attributeFormDefault="unqualified">
	<xs:include schemaLocation="SmartTransducerDataModel.xsd"/>
	<xs:include schemaLocation="TextTEDS.xsd"/>
	<xs:element name="CommandTEDS" type="stml:CommandTEDSType" substitutionGroup="stml:TextTEDS">
		<xs:annotation>
			<xs:documentation>1451 Smart Sensor CommandTEDS schema</xs:documentation>
		</xs:annotation>
	</xs:element>
	<xs:complexType name="CommandTEDSDataBlockType">
		<xs:sequence>
			<xs:element name="Name" type="stml:_String"/>
			<xs:element name="CmdClass" type="stml:UInt8"/>
			<xs:element name="CmdFunction" type="stml:UInt8"/>
			<xs:element name="Scope" type="stml:_String"/>
			<xs:element name="arg" minOccurs="0" maxOccurs="16535">
				<xs:annotation>
					<xs:documentation>Each arg element is one element in the argumentArray that will be sent as part of the command.</xs:documentation>
				</xs:annotation>
				<xs:complexType>
					<xs:choice>
						<xs:element name="TagValuePair" minOccurs="0" maxOccurs="unbounded">
							<xs:complexType mixed="true">
								<xs:choice>
									<xs:element name="Int8Value" type="stml:Int8" minOccurs="0"/>
									<xs:element name="UInt8Value" type="stml:UInt8" minOccurs="0"/>
									<xs:element name="Int16Value" type="stml:Int16" minOccurs="0"/>
									<xs:element name="UInt16Value" type="stml:UInt16" minOccurs="0"/>
									<xs:element name="Int32Value" type="stml:Int32" minOccurs="0"/>
									<xs:element name="UInt32Value" type="stml:UInt32" minOccurs="0"/>
									<xs:element name="floatValue" type="stml:Float32" minOccurs="0"/>
									<xs:element name="doubleValue" type="stml:Float64" minOccurs="0"/>
									<xs:element name="timeValue" minOccurs="0">
										<xs:complexType>
											<xs:simpleContent>
												<xs:extension base="xs:dateTime"/>
											</xs:simpleContent>
										</xs:complexType>
									</xs:element>
									<xs:element name="booleanValue" type="stml:_Boolean" minOccurs="0"/>
									<xs:element name="StringArg" type="stml:_String" minOccurs="0"/>
								</xs:choice>
								<xs:attribute name="Tag" type="xs:string" use="required"/>
							</xs:complexType>
						</xs:element>
						<xs:element name="listOfValues" minOccurs="0" maxOccurs="unbounded">
							<xs:complexType>
								<xs:choice>
									<xs:element name="int8ArrayValue" type="stml:Int8Array" minOccurs="0"/>
									<xs:element name="uInt8ArrayValue" type="stml:UInt8Array" minOccurs="0"/>
									<xs:element name="int16ArrayValue" type="stml:Int16Array" minOccurs="0"/>
									<xs:element name="uInt16ArrayValue" type="stml:UInt16Array" minOccurs="0"/>
									<xs:element name="int32ArrayValue" type="stml:Int32Array" minOccurs="0"/>
									<xs:element name="uInt32ArrayValue" type="stml:UInt32Array" minOccurs="0"/>
									<xs:element name="float32ArrayValue" type="stml:Float32Array" minOccurs="0"/>
									<xs:element name="float64ArrayValue" type="stml:Float64Array" minOccurs="0"/>
									<xs:element name="stringArrayValue" type="stml:StringArray" minOccurs="0"/>
									<xs:element name="octetArrayValue" type="stml:OctetArray" minOccurs="0"/>
									<xs:element name="booleanArrayValue" type="stml:BooleanArray" minOccurs="0"/>
									<xs:element name="timeInstanceArrayValue" type="stml:TimeInstanceArrayType" minOccurs="0"/>
									<xs:element name="timeDurationArrayValue" type="stml:TimeDurationArrayType" minOccurs="0"/>
								</xs:choice>
								<xs:attribute name="Tag" type="xs:string" use="required"/>
							</xs:complexType>
						</xs:element>
						<xs:element name="rangeOfValues" minOccurs="0">
							<xs:complexType mixed="true">
								<xs:choice>
									<xs:element name="Int8Step" type="stml:Int8" minOccurs="0"/>
									<xs:element name="UInt8Step" type="stml:UInt8" minOccurs="0"/>
									<xs:element name="Int16Step" type="stml:Int16" minOccurs="0"/>
									<xs:element name="UInt16Step" type="stml:UInt16" minOccurs="0"/>
									<xs:element name="Int32Step" type="stml:Int32" minOccurs="0"/>
									<xs:element name="UInt32Step" type="stml:UInt32" minOccurs="0"/>
									<xs:element name="floatStep" type="stml:Float32" minOccurs="0"/>
									<xs:element name="doubleStep" type="stml:Float64" minOccurs="0"/>
									<xs:element name="timeStep" type="xs:dateTime" minOccurs="0"/>
									<xs:element name="logical" type="stml:_Boolean" minOccurs="0"/>
								</xs:choice>
								<xs:attribute name="Tag" type="xs:string" use="required"/>
							</xs:complexType>
						</xs:element>
					</xs:choice>
					<xs:attribute name="argName" type="xs:string" use="required"/>
					<xs:attribute name="argNumber" type="xs:unsignedByte" use="required"/>
					<xs:attribute name="dataModel" type="stml:DataModelTypes" use="required"/>
					<xs:attribute name="desc" type="xs:string"/>
				</xs:complexType>
			</xs:element>
			<xs:element name="reply" minOccurs="0" maxOccurs="65535">
				<xs:annotation>
					<xs:documentation>Each reply element is one element in the argumentArray that will be returned as part of the reply to the command. The attribute replyArgOffset gives the number of octets from the beginning of the reply message to the first octet in this argument.</xs:documentation>
				</xs:annotation>
				<xs:complexType>
					<xs:annotation>
						<xs:documentation>This field provides an offset in octets from the beginning of the reply message to the first octet of this value.</xs:documentation>
					</xs:annotation>
					<xs:choice>
						<xs:annotation>
							<xs:documentation>This field provides an array of octets. The exact structure and meaning of the elements of this array is defined in the desc attribute or by reference to another document.</xs:documentation>
						</xs:annotation>
						<xs:element name="timeValue" type="xs:dateTime"/>
						<xs:element name="BitMappedOctet">
							<xs:annotation>
								<xs:documentation>The mask allows a bit or bits to be selected from the reply argument. This can be repeated as many times as required by specifying the same replyArgOffset repeatedly. A one in a bit position in the mask selects the bit and a zero rejects that bit.</xs:documentation>
							</xs:annotation>
							<xs:complexType>
								<xs:simpleContent>
									<xs:extension base="xs:unsignedByte">
										<xs:attribute name="Mask" type="stml:UInt8" use="required"/>
									</xs:extension>
								</xs:simpleContent>
							</xs:complexType>
						</xs:element>
						<xs:element name="Int8Value" type="stml:Int8"/>
						<xs:element name="UInt8Value" type="stml:UInt8"/>
						<xs:element name="Int16Value" type="stml:Int16"/>
						<xs:element name="UInt16Value" type="stml:UInt16"/>
						<xs:element name="Int32Value" type="stml:Int32"/>
						<xs:element name="UInt32Value" type="stml:UInt32"/>
						<xs:element name="floatValue" type="stml:Float32"/>
						<xs:element name="doubleValue" type="stml:Float64"/>
						<xs:element name="textValue" type="stml:_String"/>
						<xs:element name="octetArrayValue" type="stml:OctetArray"/>
						<xs:element name="logicalValue" type="stml:_Boolean"/>
					</xs:choice>
					<xs:attribute name="replyArgName" type="xs:string" use="required"/>
					<xs:attribute name="replyArgOffset" type="xs:unsignedInt" use="required"/>
					<xs:attribute name="desc" type="xs:string"/>
				</xs:complexType>
			</xs:element>
		</xs:sequence>
	</xs:complexType>
	<xs:complexType name="ArgType">
		<xs:sequence>
			<xs:element name="DataModel">
				<xs:complexType>
					<xs:sequence>
						<xs:element name="Type" type="xs:short"/>
						<xs:element name="Length" type="xs:short" default="1"/>
						<xs:element name="Value" type="stml:UInt8"/>
					</xs:sequence>
				</xs:complexType>
			</xs:element>
			<xs:element name="description">
				<xs:complexType>
					<xs:sequence>
						<xs:element name="Type" type="xs:short"/>
						<xs:element name="Length" type="xs:short"/>
						<xs:element name="Value" type="stml:_String"/>
					</xs:sequence>
				</xs:complexType>
			</xs:element>
		</xs:sequence>
	</xs:complexType>
	<xs:complexType name="CommandTEDSType">
		<xs:complexContent>
			<xs:extension base="stml:TextTEDSType">
				<xs:sequence>
					<xs:element name="XMLText" type="stml:CommandTEDSDataBlockType"/>
					<xs:element name="XMLSum" type="stml:UInt16"/>
				</xs:sequence>
			</xs:extension>
		</xs:complexContent>
	</xs:complexType>
	<xs:simpleType name="DataModelType">
		<xs:restriction base="xs:string">
			<xs:enumeration value="Int8"/>
			<xs:enumeration value="UInt8"/>
			<xs:enumeration value="Int8Array"/>
			<xs:enumeration value="UInt8Array"/>
			<xs:enumeration value="Int16"/>
			<xs:enumeration value="UInt16"/>
			<xs:enumeration value="Int16Array"/>
			<xs:enumeration value="UInt16Array"/>
			<xs:enumeration value="Int32"/>
			<xs:enumeration value="UInt32"/>
			<xs:enumeration value="Int32Array"/>
			<xs:enumeration value="UInt32Array"/>
			<xs:enumeration value="Float32"/>
			<xs:enumeration value="Float32Array"/>
			<xs:enumeration value="Float64"/>
			<xs:enumeration value="Float64Array"/>
			<xs:enumeration value="_String"/>
			<xs:enumeration value="StringArray"/>
			<xs:enumeration value="_Octet"/>
			<xs:enumeration value="OctetArray"/>
			<xs:enumeration value="_Boolean"/>
			<xs:enumeration value="BooleanArray"/>
			<xs:enumeration value="TimeInstance"/>
			<xs:enumeration value="TimeInstanceArray"/>
			<xs:enumeration value="TimeDuration"/>
			<xs:enumeration value="TimeDurationArray"/>
		</xs:restriction>
	</xs:simpleType>
</xs:schema>
