hmtrp: Added functions that throw exceptions when failing to read from sensors, and added java exception handling.
Signed-off-by: Stefan Andritoiu <stefan.andritoiu@intel.com> Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
This commit is contained in:
committed by
Mihai Tudor Panu
parent
9bfda4219d
commit
4de9734f0a
@@ -3,6 +3,7 @@
|
||||
%include "stdint.i"
|
||||
%include "typemaps.i"
|
||||
%include "../java_buffer.i"
|
||||
%include "../java_exceptions.i"
|
||||
|
||||
%apply uint32_t *OUTPUT { uint32_t *freq, uint32_t *dataRate };
|
||||
%apply uint16_t *OUTPUT { uint16_t *rxBandwidth };
|
||||
@@ -15,6 +16,12 @@
|
||||
speed_t int_B9600 = B9600;
|
||||
%}
|
||||
|
||||
%ignore getRFSignalStrength(uint8_t *strength);
|
||||
READDATA_EXCEPTION(getRFSignalStrength())
|
||||
|
||||
%ignore getModSignalStrength(uint8_t *strength);
|
||||
READDATA_EXCEPTION(getModSignalStrength())
|
||||
|
||||
%include "hmtrp.h"
|
||||
speed_t int_B9600 = B9600;
|
||||
|
||||
@@ -27,4 +34,4 @@ speed_t int_B9600 = B9600;
|
||||
System.exit(1);
|
||||
}
|
||||
}
|
||||
%}
|
||||
%}
|
||||
|
||||
Reference in New Issue
Block a user