java: changed some C types to C++ types
Signed-off-by: Andrei Vasiliu <andrei.vasiliu@intel.com> Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com> Conflicts: src/mma7455/mma7455.cxx src/mma7455/mma7455.h src/sm130/sm130.cxx src/sm130/sm130.h
This commit is contained in:
committed by
Mihai Tudor Panu
parent
b8835958e2
commit
ab730038fd
@@ -27,7 +27,7 @@
|
||||
#pragma once
|
||||
|
||||
#include <string.h>
|
||||
#include <mraa/i2c.h>
|
||||
#include <mraa/i2c.hpp>
|
||||
#include <math.h>
|
||||
|
||||
namespace upm {
|
||||
@@ -102,8 +102,10 @@ class LSM303 {
|
||||
|
||||
/**
|
||||
* LSM303 object destructor
|
||||
*/
|
||||
~LSM303 ();
|
||||
* where is no more need for this here - I2c connection will be stopped
|
||||
* automatically when m_i2c variable will go out of scope
|
||||
* ~LSM303 ();
|
||||
**/
|
||||
|
||||
/**
|
||||
* Gets the current heading; headings <0 indicate an error has occurred
|
||||
@@ -115,13 +117,13 @@ class LSM303 {
|
||||
/**
|
||||
* Gets the coordinates in the XYZ order
|
||||
*/
|
||||
mraa_result_t getCoordinates();
|
||||
mraa::Result getCoordinates();
|
||||
|
||||
/**
|
||||
* Gets accelerometer values
|
||||
* Should be called before other "get" functions for acceleration
|
||||
*/
|
||||
mraa_result_t getAcceleration();
|
||||
mraa::Result getAcceleration();
|
||||
|
||||
/**
|
||||
* Gets raw coordinate data; it is updated when getCoordinates() is called
|
||||
@@ -165,9 +167,9 @@ class LSM303 {
|
||||
|
||||
private:
|
||||
int readThenWrite(uint8_t reg);
|
||||
mraa_result_t setRegisterSafe(uint8_t slave, uint8_t sregister, uint8_t data);
|
||||
mraa::Result setRegisterSafe(uint8_t slave, uint8_t sregister, uint8_t data);
|
||||
|
||||
mraa_i2c_context m_i2c;
|
||||
mraa::I2c m_i2c;
|
||||
int m_addrMag;
|
||||
int m_addrAcc;
|
||||
uint8_t buf[6];
|
||||
|
||||
Reference in New Issue
Block a user