mirror of
https://github.com/eclipse/upm.git
synced 2025-07-09 13:21:22 +03:00
java: solved callbacks
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
323905a215
commit
19bcbc7c42
@ -34,6 +34,10 @@
|
||||
#include <mraa/gpio.hpp>
|
||||
#endif
|
||||
|
||||
#ifdef SWIGJAVA
|
||||
#include "../IsrCallback.h"
|
||||
#endif
|
||||
|
||||
#define MPU60X0_I2C_BUS 0
|
||||
#define MPU60X0_DEFAULT_I2C_ADDR 0x68
|
||||
|
||||
@ -904,7 +908,11 @@ namespace upm {
|
||||
* @param isr the interrupt handler, accepting a void * argument
|
||||
* @param arg the argument to pass the the interrupt handler
|
||||
*/
|
||||
#ifdef SWIGJAVA
|
||||
void installISR(int gpio, mraa::Edge level, IsrCallback *cb);
|
||||
#else
|
||||
void installISR(int gpio, mraa::Edge level, void (*isr)(void *), void *arg);
|
||||
#endif
|
||||
|
||||
/**
|
||||
* uninstall a previously installed interrupt handler
|
||||
@ -931,6 +939,10 @@ namespace upm {
|
||||
float m_gyroScale;
|
||||
|
||||
private:
|
||||
#ifdef SWIGJAVA
|
||||
void installISR(int gpio, mraa::Edge level, void (*isr)(void *), void *arg);
|
||||
#endif
|
||||
|
||||
mraa::I2c m_i2c;
|
||||
uint8_t m_addr;
|
||||
|
||||
|
Reference in New Issue
Block a user