ac5479851b0044ee713ff59dc3035502e1e3d8f4
[platform/adaptation/emulator/emulator-plugin-accel-filter.git] / include / accel_sim_filter.h
1 /*
2  * emulator-plugin-accel-filter
3  *
4  * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
5  *
6  * Contact:
7  * SooYoung Ha <yoosah.ha@samsnung.com>
8  * Sungmin Ha <sungmin82.ha@samsung.com>
9  * 
10  * This library is free software; you can redistribute it and/or modify it under
11  * the terms of the GNU Lesser General Public License as published by the
12  * Free Software Foundation; either version 2.1 of the License, or (at your option)
13  * any later version.
14  * 
15  * This library is distributed in the hope that it will be useful, but WITHOUT ANY
16  * WARRANTY; without even the implied warranty of MERCHANTABILITY or
17  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
18  * License for more details.
19  *
20  * You should have received a copy of the GNU Lesser General Public License
21  * along with this library; if not, write to the Free Software Foundation, Inc., 51
22  * Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
23  *
24  */
25
26 class accel_sim_filter : public cfilter_module {
27 public:
28         accel_sim_filter();
29         virtual ~accel_sim_filter();
30
31         const char *name(void);
32         int version(void);
33         int id(void);
34
35         bool update_name(char *name);
36         bool update_version(int ver);
37         bool update_id(int id);
38
39         bool add_input(csensor_module *module);
40         cfilter_module *create_new(void);
41         void destroy(cfilter_module *module);
42
43         bool is_data_ready(bool wait = false);
44         long value(const char *port);
45         long value(int id);
46
47         bool start(void);
48         bool stop(void);
49
50         void reset(void);
51         int get_sensor_type(void);
52
53         long polling_interval(void);
54         bool update_polling_interval(unsigned long val);
55         
56         int get_property(unsigned int property_level , void *property_data);
57         int get_struct_value(unsigned int struct_type , void *struct_values);   
58         
59         int check_hw_node(void);
60 private:
61
62         csensor_module *m_sensor;
63         int m_id;
64         int m_version;
65         char *m_name;
66
67         long m_x;
68         long m_y;
69         long m_z;
70
71         unsigned long long m_fired_time;
72         unsigned long m_polling_interval;
73
74
75 };