OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef DEVICE_GENERIC_SENSOR_SENSOR_DATA_IIO_H_ | |
6 #define DEVICE_GENERIC_SENSOR_SENSOR_DATA_IIO_H_ | |
Mikhail
2016/10/14 13:59:04
looks like it's better to create 'iio' folder and
maksims (do not use this acc)
2016/10/17 06:06:59
It's already there. Haven't changed the string her
| |
7 | |
8 #include "device/generic_sensor/public/interfaces/sensor.mojom.h" | |
9 | |
10 namespace device { | |
11 | |
12 namespace { | |
13 | |
14 const char kBasePathSensorIio[] = FILE_PATH_LITERAL("/sys/bus/iio/devices"); | |
Mikhail
2016/10/14 13:59:04
Declaring them like this would cause copying in ev
maksims (do not use this acc)
2016/10/17 06:06:59
Done.
| |
15 | |
16 const size_t kMaxRows = 3; | |
17 | |
18 } // namespace | |
19 | |
20 struct SensorDataIio { | |
21 const char* base_path_sensor_iio = kBasePathSensorIio; | |
22 const char** sensor_file_names[kMaxRows]; | |
23 size_t sensor_file_names_cols; | |
24 size_t sensor_file_names_rows; | |
25 mojom::ReportingMode reporting_mode; | |
26 PlatformSensorConfiguration default_configuration; | |
27 }; | |
28 | |
29 bool CreateSensorData(mojom::SensorType type, SensorDataIio* data); | |
30 | |
31 } // namespace device | |
32 | |
33 #endif // DEVICE_GENERIC_SENSOR_SENSOR_DATA_IIO_H_ | |
OLD | NEW |