Hi all,
Now I am facing to a strange issue about g-sensor and screen orientation on rowboat gingerbread 2.3.4 (TI Gingerbread2.3.4 v2.1)
I have done porting sensor and battery driver, the issue is the home screen orientation not work when battery attached.
The home screen orientation is work if battery is not attached.
After trace logcat, I found the sensors_poll_context_t->activate is not get called when battery is not attached ( marked red )
I googled and only know the home screen orientation is handled by phonewindowmanager.java
but don't know why battery service will cause orientation not work
Hope if anyone experienced this issue could help me to fingure out this issue, thanks.
=================================================
The normal logcat
.
.
D/PowerManagerService( 1316): bootCompleted
I/SurfaceFlinger( 1316): Boot is finished (11257 ms)
I/SurfaceFlinger( 1316): Boot is finished (11257 ms)
D/HomeLoaders( 1424): ----> workspace loader 1 finished loading data
D/HomeLoaders( 1424): ----> worskpace items=6
[ 30.336334] init: starting 'wl12xx'e widgets=1
D/HomeLoaders( 1424): ----> worskpace items=6
[ 30.336334] init: starting 'wl12xx'e widgets=1
D/HomeLoaders( 1424): --> done loading workspace; not stopped
D/HomeLoaders( 1424): ----> items cloned, ready to refresh UI
I/dalvikvm( 1316): Total arena pages for JIT: 11
D/SensorsHAL( 1316): sensors_poll_context_t->activate(handle: 0, enabled: 1) // will not happen when battery attached
V/AccSensors( 1316): AccSensor::+enable(1)
D/AccSensors( 1316): AccSensor::enable(en=1) : fd=187, path=/sys/class/i2c-adapter/i2c-3/3-0019/enable_device
D/SensorsHAL( 1316): sensors_poll_context_t::pollEvents(): mPollFds[0].fd = 30; mPollFds[0].revents = 99; PendingEvent = 0
D/SensorsHAL( 1316): sensors_poll_context_t::pollEvents(): sensor idex: 0; senor->readEvents(coutn=16) return 1;
D/SensorsHAL( 1316): no more data for this sensor
D/HomeLoaders( 1424): ----> items cloned, ready to refresh UI
I/dalvikvm( 1316): Total arena pages for JIT: 11
D/SensorsHAL( 1316): sensors_poll_context_t->activate(handle: 0, enabled: 1) // will not happen when battery attached
V/AccSensors( 1316): AccSensor::+enable(1)
D/AccSensors( 1316): AccSensor::enable(en=1) : fd=187, path=/sys/class/i2c-adapter/i2c-3/3-0019/enable_device
D/SensorsHAL( 1316): sensors_poll_context_t::pollEvents(): mPollFds[0].fd = 30; mPollFds[0].revents = 99; PendingEvent = 0
D/SensorsHAL( 1316): sensors_poll_context_t::pollEvents(): sensor idex: 0; senor->readEvents(coutn=16) return 1;
D/SensorsHAL( 1316): no more data for this sensor