summaryrefslogtreecommitdiffstats
path: root/libsensors/AkmSensor.cpp
diff options
context:
space:
mode:
authortim.sk.lee <tim.sk.lee@samsung.com>2010-10-28 00:33:01 -0700
committerMaarten Hooft <mthooft@google.com>2010-11-09 21:06:33 -0800
commit286d99b62709872dc9f891991cccc1272e884cb7 (patch)
treececb132f223bd3a223240aef20e42fd810d12fdf /libsensors/AkmSensor.cpp
parent1f5810e62f6bd75d850c98c3263dbcc4c7885198 (diff)
downloaddevice_samsung_crespo-286d99b62709872dc9f891991cccc1272e884cb7.zip
device_samsung_crespo-286d99b62709872dc9f891991cccc1272e884cb7.tar.gz
device_samsung_crespo-286d99b62709872dc9f891991cccc1272e884cb7.tar.bz2
S5PC11X: SENSOR: Mag, accel, orientation and gyro get the cotinuous events
By using EV_REL instead of EV_ABS, sensors can get continous events even though they're not changed. Change-Id: I2341c0d1a1cdec223328796355ebf0210a9dea5e Signed-off-by: tim.sk.lee <tim.sk.lee@samsung.com>
Diffstat (limited to 'libsensors/AkmSensor.cpp')
-rw-r--r--libsensors/AkmSensor.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/libsensors/AkmSensor.cpp b/libsensors/AkmSensor.cpp
index f2470c3..68d2fc2 100644
--- a/libsensors/AkmSensor.cpp
+++ b/libsensors/AkmSensor.cpp
@@ -245,7 +245,7 @@ int AkmSensor::readEvents(sensors_event_t* data, int count)
while (count && mInputReader.readEvent(&event)) {
int type = event->type;
- if (type == EV_ABS) {
+ if (type == EV_REL) {
processEvent(event->code, event->value);
mInputReader.next();
} else if (type == EV_SYN) {
@@ -320,4 +320,4 @@ void AkmSensor::processEvent(int code, int value)
uint8_t(value & SENSOR_STATE_MASK);
break;
}
-} \ No newline at end of file
+}