adxl345: Grove 3-Axis Accelerometer
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
This commit is contained in:
committed by
Propanu
parent
6aef5868af
commit
a4e590ae3a
20
src/adxl345/jsupm_adxl345.i
Normal file
20
src/adxl345/jsupm_adxl345.i
Normal file
@@ -0,0 +1,20 @@
|
||||
%module jsupm_adxl345
|
||||
%include "../upm.i"
|
||||
%include "../carrays_int16_t.i"
|
||||
%include "../carrays_float.i"
|
||||
|
||||
%{
|
||||
#include "adxl345.h"
|
||||
%}
|
||||
|
||||
%typemap(out) int16_t * {
|
||||
$result = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_int16Array, 0 | 0 );
|
||||
}
|
||||
|
||||
%typemap(out) float * {
|
||||
$result = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_floatArray, 0 | 0 );
|
||||
}
|
||||
|
||||
%include "adxl345.h"
|
||||
|
||||
%include <carrays.i>
|
||||
Reference in New Issue
Block a user