diff options
-rw-r--r-- | debian/changelog | 6 | ||||
-rw-r--r-- | debian/control | 2 | ||||
-rw-r--r-- | packaging/sf-plugin-proc-accel-emul.spec | 50 | ||||
-rw-r--r-- | src/accel_sim_processor.cpp | 21 |
4 files changed, 65 insertions, 14 deletions
diff --git a/debian/changelog b/debian/changelog index f607f4a..9332c45 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +sf-plugin-proc-accel-emul (0.2.4) unstable; urgency=low + + * modified for support updated libslp-sensor + + -- Sungmin Ha <sungmin82.ha@samsung.com> Thu, 5 Apr 2012 15:06:52 +0900 + sf-plugin-proc-accel-emul (0.2.3-2) unstable; urgency=low * modified for build only i386 diff --git a/debian/control b/debian/control index 38cb15a..d3f0aaf 100644 --- a/debian/control +++ b/debian/control @@ -3,7 +3,7 @@ Section: misc Priority: extra Maintainer: Sungmin Ha <sungmin82.ha@samsung.com> Build-Depends: libsf-common-dev, libslp-setting-dev -Standards-Version: 0.2.3-1 +Standards-Version: 0.2.4 Package: sf-plugin-proc-accel-emul Architecture: i386 diff --git a/packaging/sf-plugin-proc-accel-emul.spec b/packaging/sf-plugin-proc-accel-emul.spec new file mode 100644 index 0000000..7aae88e --- /dev/null +++ b/packaging/sf-plugin-proc-accel-emul.spec @@ -0,0 +1,50 @@ +#git:/slp/pkgs/e/emulator-plugin-accel-proc +Name: sf-plugin-proc-accel-emul +Version: 0.2.1 +Release: 1 +Summary: Accel simulator Processor plugin for sensor framework (using setting) +Group: System Environment/Libraries +License: GNUv2 +Source0: %{name}-%{version}.tar.gz +BuildArch: i386 +ExclusiveArch: %{ix86} +BuildRequires: cmake +BuildRequires: pkgconfig(sf_common) +BuildRequires: pkgconfig(vconf) + +%description +Accel simulator Processor plugin for sensor framework(unstripped) +Easy Accel simulator Processor plugin for SLP(not recommended) + +%prep +%setup -q + +%build +export LDFLAGS+="-Wl,--rpath=%{_prefix}/lib -Wl,--as-needed" + +LDFLAGS="$LDFLAGS" cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} + +make + +%install +rm -rf %{buildroot} +%make_install + +%clean +make clean +rm -rf CMakeCache.txt +rm -rf CMakeFiles +rm -rf cmake_install.cmake +rm -rf Makefile +rm -rf install_manifes.txt +rm -rf *.so + +%post + +%postun + +%files +%defattr(-,root,root,-) +%{_prefix}/lib/sensor_framework/*.so* + +%changelog diff --git a/src/accel_sim_processor.cpp b/src/accel_sim_processor.cpp index 466ba7a..ce65e51 100644 --- a/src/accel_sim_processor.cpp +++ b/src/accel_sim_processor.cpp @@ -841,22 +841,17 @@ long accel_sim_processor::set_cmd(int type , int property , long input_value) int accel_sim_processor::get_property(unsigned int property_level , void *property_data ) { -#ifdef TARGET - if ( (property_level & 0xFFFF) == 1 ) { - base_property_struct *return_property; - return_property = (base_property_struct *)property_data; - return_property->sensor_unit_idx = IDX_UNIT_METRE_PER_SECOND_SQUARED; - return_property->sensor_min_range = -20.09088; - return_property->sensor_max_range = 20.05164; - return_property->sensor_resolution = 0.03924; - return 0; - + if(m_filter) + { + return m_filter->get_property(property_level, property_data); + } else if(m_sensor) { + return m_sensor->get_property(property_level, property_data); } else { - ERR("Doesnot support property_level : %d\n",property_level); + ERR("no m_sensor, cannot get_property from sensor\n"); return -1; } -#endif - return -1; + + return 0; } int accel_sim_processor::get_struct_value(unsigned int struct_type , void *struct_values) |