diff options
Diffstat (limited to 'hal/sensors/2.1/config/sensor_hal_configuration.xsd')
-rw-r--r-- | hal/sensors/2.1/config/sensor_hal_configuration.xsd | 80 |
1 files changed, 80 insertions, 0 deletions
diff --git a/hal/sensors/2.1/config/sensor_hal_configuration.xsd b/hal/sensors/2.1/config/sensor_hal_configuration.xsd new file mode 100644 index 0000000..a55eaf0 --- /dev/null +++ b/hal/sensors/2.1/config/sensor_hal_configuration.xsd @@ -0,0 +1,80 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- Copyright (C) 2020 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> +<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema"> + <xs:complexType name="axisType"> + <xs:attribute name="map" type="xs:positiveInteger" use="required"/> + <xs:attribute name="negate" type="xs:boolean" use="required"/> + </xs:complexType> + <xs:complexType name="orientation"> + <xs:sequence> + <xs:element name="x" type="axisType"/> + <xs:element name="y" type="axisType"/> + <xs:element name="z" type="axisType"/> + </xs:sequence> + <xs:attribute name="rotate" type="xs:boolean" use="required"/> + </xs:complexType> + <xs:complexType name="location"> + <xs:sequence> + <xs:element name="x" type="xs:decimal"/> + <xs:element name="y" type="xs:decimal"/> + <xs:element name="z" type="xs:decimal"/> + </xs:sequence> + </xs:complexType> + <xs:complexType name="configuration"> + <xs:sequence> + <xs:element name="orientation" type="orientation" /> + <xs:element name="location" type="location" /> + </xs:sequence> + </xs:complexType> + <!-- attribute type describes the sensor type. Possible values are the Enum + values of SensorType specified in hardware/interfaces/sensors/2.1/types.hal + (which inherits most of its values from SensorType in + hardware/interfaces/sensors/1.0/types.hal) + --> + <xs:complexType name="sensor"> + <xs:sequence> + <xs:element name="configuration" type="configuration"/> + </xs:sequence> + <xs:attribute name="name" type="xs:string" use="required"/> + <xs:attribute name="type" type="xs:positiveInteger" use="required"/> + </xs:complexType> + <xs:complexType name="sensors"> + <xs:sequence> + <xs:element name="sensor" type="sensor" maxOccurs="unbounded"/> + </xs:sequence> + </xs:complexType> + <xs:complexType name="modules"> + <xs:sequence> + <xs:element name="module" maxOccurs="unbounded"> + <xs:complexType> + <xs:sequence> + <xs:element name="sensors" type="sensors"/> + </xs:sequence> + <xs:attribute name="halName" type="xs:string" use="required"/> + <xs:attribute name="halVersion" type="xs:float" use="required"/> + </xs:complexType> + </xs:element> + </xs:sequence> + </xs:complexType> + <xs:element name="sensorHalConfiguration"> + <xs:complexType> + <xs:sequence> + <xs:element name="modules" type="modules"/> + </xs:sequence> + <xs:attribute type="xs:float" name="version" use="required"/> + </xs:complexType> + </xs:element> +</xs:schema> |