<?xml version="1.0"?>
<!DOCTYPE schema [
]>
<schema xmlns="http://www.w3.org/2000/10/XMLSchema" targetNamespace="http://www.w3.org/namespace/" xmlns:t="http://www.w3.org/namespace/">

	<element name="DataType">
		<complexType>
			<sequence>
				<element ref="t:Identification" minOccurs="0" maxOccurs="1"/>
				<element ref="t:VersionInfo" maxOccurs="unbounded"/>
				<element ref="t:CompilerInfo" minOccurs="0" maxOccurs="1"/>
				<element ref="t:ASN1Tag" minOccurs="0" maxOccurs="1"/>
				<choice>
					<element ref="t:DirectlyDerivedType"/>
					<element ref="t:EnumeratedType"/>
					<element ref="t:SubrangeType"/>
					<element ref="t:ArrayType"/>
					<element ref="t:StructuredType"/>
				</choice>
			</sequence>
			<attribute name="Name" type="string" use="required"/>
			<attribute name="Comment" type="string" use="optional"/>
		</complexType>
	</element>

	<element name="Identification">
		<complexType>
			<attribute name="Standard" type="string" use="optional"/>
			<attribute name="Classification" type="string" use="optional"/>
			<attribute name="ApplicationDomain" type="string" use="optional"/>
			<attribute name="Function" type="string" use="optional"/>
			<attribute name="Type" type="string" use="optional"/>
			<attribute name="Description" type="string" use="optional"/><![CDATA[]]></complexType>
	</element>

	<element name="VersionInfo">
		<complexType>
			<attribute name="Organization" type="string" use="required"/>
			<attribute name="Version" type="string" use="required"/>
			<attribute name="Author" type="string" use="required"/>
			<attribute name="Date" type="string" use="required"/>
			<attribute name="Remarks" type="string" use="optional"/>
		</complexType>
	</element>

	<element name="ASN1Tag">
		<complexType>
			<attribute name="Class" use="optional">
				<simpleType>
					<restriction base="string">
						<enumeration value="UNIVERSAL"/>
						<enumeration value="APPLICATION"/>
						<enumeration value="CONTEXT"/>
						<enumeration value="PRIVATE"/>
					</restriction>
				</simpleType>
			</attribute>
			<attribute name="Number" type="string" use="required"/>
		</complexType>
	</element>

	<element name="CompilerInfo">
		<complexType>
			<sequence>
				<element ref="t:Compiler" minOccurs="0" maxOccurs="unbounded"/>
			</sequence>
			<attribute name="header" type="string" use="optional"/>
			<attribute name="classdef" type="string" use="optional"/>
		</complexType>
	</element>

	<element name="Compiler">
		<complexType>
			<attribute name="Language" use="required">
				<simpleType>
					<restriction base="string">
						<enumeration value="Java"/>
						<enumeration value="Cpp"/>
						<enumeration value="C"/>
						<enumeration value="Other"/>
					</restriction>
				</simpleType>
			</attribute>
			<attribute name="Vendor" type="string" use="required"/>
			<attribute name="Product" type="string" use="required"/>
			<attribute name="Version" type="string" use="required"/>
		</complexType>
	</element>

	<element name="DirectlyDerivedType">
		<complexType>
			<attribute name="BaseType" use="required">
				<simpleType>
					<restriction base="string">
						<enumeration value="BOOL"/>
						<enumeration value="SINT"/>
						<enumeration value="INT"/>
						<enumeration value="DINT"/>
						<enumeration value="LINT"/>
						<enumeration value="USINT"/>
						<enumeration value="UINT"/>
						<enumeration value="UDINT"/>
						<enumeration value="ULINT"/>
						<enumeration value="REAL"/>
						<enumeration value="LREAL"/>
						<enumeration value="TIME"/>
						<enumeration value="DATE"/>
						<enumeration value="TIME_OF_DAY"/>
						<enumeration value="TOD"/>
						<enumeration value="DATE_AND_TIME"/>
						<enumeration value="DT"/>
						<enumeration value="STRING"/>
						<enumeration value="BYTE"/>
						<enumeration value="WORD"/>
						<enumeration value="DWORD"/>
						<enumeration value="LWORD"/>
						<enumeration value="WSTRING"/>
					</restriction>
				</simpleType>
			</attribute>
			<attribute name="InitialValue" type="string" use="optional"/>
			<attribute name="Comment" type="string" use="optional"/>
		</complexType>
	</element>



	<element name="EnumeratedValue">
		<complexType>
			<attribute name="Name" type="string" use="required"/>
			<attribute name="Comment" type="string" use="optional"/>
		</complexType>
	</element>

	<element name="SubrangeType">
		<complexType>
			<sequence>
				<element ref="t:Subrange"/>
			</sequence>
			<attribute name="BaseType" use="required">
				<simpleType>
					<restriction base="string">
						<enumeration value="SINT"/>
						<enumeration value="INT"/>
						<enumeration value="DINT"/>
						<enumeration value="LINT"/>
						<enumeration value="USINT"/>
						<enumeration value="UINT"/>
						<enumeration value="UDINT"/>
						<enumeration value="ULINT"/>
					</restriction>
				</simpleType>
			</attribute>
			<attribute name="InitialValue" type="string" use="optional"/>
			<attribute name="Comment" type="string" use="optional"/>
		</complexType>
	</element>

	<element name="Subrange">
		<complexType>
			<attribute name="LowerLimit" type="string" use="required"/>
			<attribute name="UpperLimit" type="string" use="required"/>
		</complexType>
	</element>

	<element name="ArrayType">
		<complexType>
			<sequence>
				<element ref="t:Subrange" maxOccurs="unbounded"/>
			</sequence>
			<attribute name="BaseType" type="string" use="required"/>
			<attribute name="InitialValues" type="string" use="optional"/>
			<attribute name="Comment" type="string" use="optional"/>
		</complexType>
	</element>

	<element name="StructuredType">
		<complexType>
			<choice maxOccurs="unbounded">
				<element ref="t:VarDeclaration"/>
				<element ref="t:SubrangeVarDeclaration"/>
			</choice>
			<attribute name="Comment" type="string" use="optional"/>
		</complexType>
	</element>

	<element name="VarDeclaration">
		<complexType>
			<attribute name="Name" type="string" use="required"/>
			<attribute name="Type" type="string" use="required"/>
			<attribute name="ArraySize" type="string" use="optional"/>
			<attribute name="InitialValue" type="string" use="optional"/>
			<attribute name="Comment" type="string" use="optional"/>
		</complexType>
	</element>

	<element name="SubrangeVarDeclaration">
		<complexType>
			<sequence>
				<element ref="t:Subrange" maxOccurs="unbounded"/>
			</sequence>
			<attribute name="Name" type="string" use="required"/>
			<attribute name="Type" use="required">
				<simpleType>
					<restriction base="string">
						<enumeration value="SINT"/>
						<enumeration value="INT"/>
						<enumeration value="DINT"/>
						<enumeration value="LINT"/>
						<enumeration value="USINT"/>
						<enumeration value="UINT"/>
						<enumeration value="UDINT"/>
						<enumeration value="ULINT"/>
					</restriction>
				</simpleType>
			</attribute>
			<attribute name="InitialValue" type="string" use="optional"/>
			<attribute name="Comment" type="string" use="optional"/>
		</complexType>
	</element>
</schema>