Skip to content

i-sachinkumar/SensorsEventManager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

platform API License Android Arsenal

Handled By : @i-sachinkumar

SensorsEventManager (Sensors Handling Library)

  • Android NDK library in C++, providing device’s motion sensors data
  • Header only ibrary
  • Super easy to Implement, handle, and extend

Header Files:

Get it from here

Example Use Case:

AccelerationEventQueue accelerationEventQueue;	//ACCELEROMETER
GyroscopeEventQueue gyroscopeEventQueue;	//GYROSCOPE


void enableAll() {
	accelerationEventQueue.enableSensor(ASENSOR_TYPE_ACCELEROMETER);
	gyroscopeEventQueue.enableSensor(ASENSOR_TYPE_GYROSCOPE);
}

void disableAll(){
	accelerationEventQueue.disableSensor();
	gyroscopeEventQueue.disableSensor();
}

bool isRecording = false;

while (isRecording) {
       //LOG("data given below")
       accelerationEventQueue.val[0]
       accelerationEventQueue.val[1]
       accelerationEventQueue.val[2] 
       gyroscopeEventQueue.val[0]
       gyroscopeEventQueue.val[1]
       gyroscopeEventQueue.val[2]
}

Contributing

Contributions are always welcome!
See contributing.md for ways to get started.

Please adhere to this project's code of conduct.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages