mirror of
https://github.com/eclipse/upm.git
synced 2025-03-15 04:57:30 +03:00
misc: Removed mraa_init and mraa::init
This change is due to commit 35760929dbb912fc3dfc738fee67c4f0dd63d55f from MRAA. Signed-off-by: Andrei Vasiliu <andrei.vasiliu@intel.com> Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
This commit is contained in:
parent
701a25261f
commit
ce6a095079
@ -47,7 +47,7 @@ adafruitss::adafruitss(int bus,int i2c_address)
|
||||
": mraa_i2c_address() failed");
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
m_rx_tx_buf[0]=PCA9685_MODE1;
|
||||
m_rx_tx_buf[1]=0;
|
||||
if (mraa_i2c_write(m_i2c,m_rx_tx_buf,2) != MRAA_SUCCESS)
|
||||
|
@ -32,7 +32,6 @@ using namespace upm;
|
||||
|
||||
APDS9002::APDS9002(int pin)
|
||||
{
|
||||
|
||||
if ( !(m_aio = mraa_aio_init(pin)) )
|
||||
{
|
||||
throw std::invalid_argument(std::string(__FUNCTION__) +
|
||||
|
@ -33,8 +33,6 @@ using namespace std;
|
||||
|
||||
ENC03R::ENC03R(int pin, float vref)
|
||||
{
|
||||
mraa_init();
|
||||
|
||||
if ( !(m_aio = mraa_aio_init(pin)) )
|
||||
{
|
||||
throw std::invalid_argument(std::string(__FUNCTION__) +
|
||||
|
@ -33,8 +33,6 @@ using namespace std;
|
||||
|
||||
GroveEHR::GroveEHR(int pin)
|
||||
{
|
||||
mraa_init();
|
||||
|
||||
if ( !(m_gpio = mraa_gpio_init(pin)) )
|
||||
{
|
||||
throw std::invalid_argument(std::string(__FUNCTION__) +
|
||||
|
@ -32,7 +32,6 @@ using namespace upm;
|
||||
|
||||
GroveLoudness::GroveLoudness(int pin)
|
||||
{
|
||||
;
|
||||
if ( !(m_aio = mraa_aio_init(pin)) )
|
||||
{
|
||||
throw std::invalid_argument(std::string(__FUNCTION__) +
|
||||
|
@ -45,8 +45,6 @@ HCSR04::HCSR04 (uint8_t triggerPin, uint8_t echoPin, void (*fptr)(void *)) {
|
||||
mraa_result_t error = MRAA_SUCCESS;
|
||||
m_name = "HCSR04";
|
||||
|
||||
mraa_init();
|
||||
|
||||
m_triggerPinCtx = mraa_gpio_init (triggerPin);
|
||||
if (m_triggerPinCtx == NULL) {
|
||||
throw std::invalid_argument(std::string(__FUNCTION__) +
|
||||
|
@ -34,7 +34,6 @@ using namespace upm;
|
||||
|
||||
MY9221::MY9221 (uint8_t di, uint8_t dcki) {
|
||||
mraa::Result error = mraa::SUCCESS;
|
||||
mraa_init();
|
||||
|
||||
// init clock context
|
||||
m_clkPinCtx = mraa_gpio_init(dcki);
|
||||
|
@ -37,7 +37,7 @@ using namespace upm;
|
||||
NRF24L01::NRF24L01 (uint8_t cs, uint8_t ce)
|
||||
: m_csnPinCtx(cs), m_cePinCtx(ce), m_spi(0)
|
||||
{
|
||||
mraa::init();
|
||||
init (cs, ce);
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -38,8 +38,6 @@ ST7735::ST7735 (uint8_t csLCD, uint8_t cSD, uint8_t rs, uint8_t rst)
|
||||
: GFX (160, 128, m_map, font), m_csLCDPinCtx(m_csLCD), m_cSDPinCtx(m_cSD),
|
||||
m_rSTPinCtx(m_rST), m_rSPinCtx(m_rS), m_spi(0) {
|
||||
|
||||
mraa::init();
|
||||
|
||||
m_csLCD = csLCD;
|
||||
m_cSD = cSD;
|
||||
m_rST = rst;
|
||||
|
@ -37,8 +37,6 @@ StepMotor::StepMotor (int dirPin, int stePin)
|
||||
mraa::Result error = mraa::SUCCESS;
|
||||
m_name = "StepMotor";
|
||||
|
||||
mraa::init();
|
||||
|
||||
m_stePin = stePin;
|
||||
m_dirPin = dirPin;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user