← Back

ofxCoreMotion

github.com/trentbrooks/ofxCoreMotion · @trentbrooks
OF 0.9 Bridges Hardware Interface iOS

OF/iOS addon for the Core Motion Framework. Gives access to device motion (attitude), gyroscope, accelerometer, and magnetometer.

44 5 Last commit 11y ago Created 14y ago

Forks

Forks pushed to more recently than trentbrooks/ofxCoreMotion itself, plus any admin-confirmed fork with commits of its own — worth checking if you're hitting issues with the original.

icq4ever/ofxCoreMotion by @icq4ever · ★ 0 · pushed 9y ago

README

https://github.com/trentbrooks/ofxCoreMotion/raw/master/screenshot.png

ofxCoreMotion

Openframeworks/ios addon (tested with OF 0.9.0, Xcode 7.1, ios 9.1) for the Core Motion Framework- http://developer.apple.com/library/ios/#documentation/CoreMotion/Reference/CoreMotion_Reference/_index.html

Example displays the values for attitude (quaternion & roll/pitch/yaw euler angles), gyroscope, accelerometer, & magentometer. The cube moves based on the attitude quaternion.

Can be used in replacement of ofxAccelerometer (which uses the deprecated UIAccelerometer).

Dependencies

Add the 'CoreMotion.framework' to your OF xcode project.

Credit

Original DeviceMotion/attitude example by Nardove found on the Openframeworks forum: http://forum.openframeworks.cc/index.php/topic,11517.0.html - Thanks!

See example project for usage.

-Trent Brooks

Get this addon

HTTPS
SSH