aboutsummaryrefslogtreecommitdiffstats
path: root/Java/com_phidgets_AccelerometerPhidget.c
blob: 6d7bd0b0f15cfa33291287378566be1c468c639d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include "../stdafx.h"
#include "phidget_jni.h"
#include "com_phidgets_AccelerometerPhidget.h"
#include "../cphidgetaccelerometer.h"

EVENT_VARS(accelerationChange, AccelerationChange)

JNI_LOAD(accel, Accelerometer)
	EVENT_VAR_SETUP(accel, accelerationChange, AccelerationChange, ID, V)
}

EVENT_HANDLER_INDEXED(Accelerometer, accelerationChange, AccelerationChange, 
					  CPhidgetAccelerometer_set_OnAccelerationChange_Handler, double)

JNI_CREATE(Accelerometer)
JNI_INDEXED_GETFUNC(Accelerometer, AccelerationChangeTrigger, AccelerationChangeTrigger, jdouble)
JNI_INDEXED_SETFUNC(Accelerometer, AccelerationChangeTrigger, AccelerationChangeTrigger, jdouble)
JNI_INDEXED_GETFUNC(Accelerometer, AccelerationMax, AccelerationMax, jdouble)
JNI_INDEXED_GETFUNC(Accelerometer, AccelerationMin, AccelerationMin, jdouble)
JNI_INDEXED_GETFUNC(Accelerometer, Acceleration, Acceleration, jdouble)
JNI_GETFUNC(Accelerometer, AxisCount, AxisCount, jint)