java: fix return types and arrays for mpu60x0 and mpu9150

Signed-off-by: Petre Eftime <petre.p.eftime@intel.com>
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
This commit is contained in:
Petre Eftime
2015-09-01 18:56:04 +03:00
committed by Mihai Tudor Panu
parent 83cb6dc2fd
commit 7afd1f3fc1
4 changed files with 72 additions and 8 deletions

View File

@@ -100,3 +100,12 @@ void MPU9150::getMagnetometer(float *x, float *y, float *z)
if (z)
*z = mz;
}
#ifdef SWIGJAVA
float *MPU9150::getMagnetometer()
{
float *v = new float[3];
getMagnetometer(&v[0], &v[1], &v[2]);
return v;
}
#endif