Adobe AIR Gyroscope Native Extension with Euler Angles (roll, pitch, yaw) for iOS

UPDATE: I have released the extension including source on google code with some changes.
Euler Gyroscope ANE on Google Code

I baked my very first AIR iOS Native Extension. It’s just an adapted version of this version from Adobe. Because in my opinion the data of radians per second aren’t really good to handle. So I looked into Apples API documentation and found out that there are Euler Angles in the CMMotionManager CMDeviceMotion classes. So I just changed a few lines in the Objective-C Code. I learned much from this tutorial Native Extionsion for Adobe AIR and iOS 101 by Liquid Photo

NSString *myStr = [NSString stringWithFormat:@"%f&%f&%f&%f&%f&%f", 
rotate.x, 
rotate.y, 
rotate.z, 
motionManager.deviceMotion.attitude.roll, 
motionManager.deviceMotion.attitude.pitch, 
motionManager.deviceMotion.attitude.yaw];

[motionManager startDeviceMotionUpdates];

motionManager.deviceMotionUpdateInterval = 0;

And added these three parameters roll, pitch and yaw to the Actionscript Gyroscope Event.

new GyroscopeEvent(GyroscopeEvent.UPDATE, _x, _y, _z, _roll, _pitch, _yaw)

You can download source and final iOS .ane Native Extension file here:
iOS Air Native Extension Gyroscope – with Euler Angles

Simulations of medical devices on touch devices, multi-screen publishing (Desktop, iPhone, iPad, Android …)

At innovation mecom, where I’m employed, we developed a simulation for training and marketing of a Dräger NIV ventilator called Carina®. It’s a small handy device to ventilate patients in hospitals. This Flash AS3 simulation reproduces all functions of the real device. So it is possible to get a real good impression of it even without using a real device.

UPDATE: The iPhone Version is online.

The online version of this trainer can be found here.

I did the coding of this simulation and I thought it would be an amazing experience to use this on an iPhone or another touch device.

Continue reading