1c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong/* 2c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * Copyright (C) 2017 The Android Open Source Project 3c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * 4c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * Licensed under the Apache License, Version 2.0 (the "License"); 5c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * you may not use this file except in compliance with the License. 6c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * You may obtain a copy of the License at 7c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * 8c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * http://www.apache.org/licenses/LICENSE-2.0 9c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * 10c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * Unless required by applicable law or agreed to in writing, software 11c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * distributed under the License is distributed on an "AS IS" BASIS, 12c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * See the License for the specific language governing permissions and 14c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong * limitations under the License. 15c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong */ 16c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong 17c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong#ifndef ANDROID_FRAMEWORKS_SENSORSERVICE_V1_0_UTILS_H 18c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong#define ANDROID_FRAMEWORKS_SENSORSERVICE_V1_0_UTILS_H 19c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong 20c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong#include <android/frameworks/sensorservice/1.0/types.h> 21c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong#include <android/hardware/sensors/1.0/types.h> 22c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong#include <hidl/HidlSupport.h> 23c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong#include <sensor/Sensor.h> 24c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hongnamespace android { 25c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hongnamespace frameworks { 26c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hongnamespace sensorservice { 27c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hongnamespace V1_0 { 28c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hongnamespace implementation { 29c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong 30c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong::android::hardware::sensors::V1_0::SensorInfo convertSensor(const ::android::Sensor &src); 31c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan HongResult convertResult(status_t status); 32c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong 3395c7a0636763c0861d46425709befe90a3919c04Yifan Hong::android::hardware::sensors::V1_0::Event convertEvent(const ::ASensorEvent &event); 3495c7a0636763c0861d46425709befe90a3919c04Yifan Hong 35c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong} // namespace implementation 36c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong} // namespace V1_0 37c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong} // namespace sensorservice 38c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong} // namespace frameworks 39c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong} // namespace android 40c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong 41c34f57fed0ad09c6d7361a39580da20b466d46d1Yifan Hong#endif // ANDROID_FRAMEWORKS_SENSORSERVICE_V1_0_UTILS_H 42