Hall Switch  2.1.0
C++ library of Infineon single Hall-effect switch family for magnetic sensing applications
GPIOIno Class Reference

#include <hall-pal-ino.hpp>

Inheritance diagram for GPIOIno:
Collaboration diagram for GPIOIno:

Public Member Functions

 GPIOIno ()
 GPIO Ino default constructor. More...
 
 GPIOIno (uint8_t pin, uint8_t mode, VLogic_t logic)
 GPIO Ino constructor. More...
 
 ~GPIOIno ()
 GPIO Ino destructor. More...
 
HallSwitch::Error_t init ()
 Initializes the Arduino GPIO. More...
 
HallSwitch::Error_t deinit ()
 Deinitializes the Arduino GPIO. More...
 
HallSwitch::Error_t enableInt (HallSwitch *ptr)
 Enables the Arduino GPIO interrupt. More...
 
HallSwitch::Error_t disableInt ()
 Disables the Arduino GPIO interrupt. More...
 
IntEvent_t intEvent ()
 Gets the latest Arduino interrupt event. More...
 
VLevel_t read ()
 Reads the Arduino GPIO voltage level. More...
 
HallSwitch::Error_t write (VLevel_t level)
 Writes the Arduino GPIO output voltage level. More...
 
HallSwitch::Error_t enable ()
 Enables the Arduino GPIO output according to the GPIO logic. More...
 
HallSwitch::Error_t disable ()
 Disables the Arduino GPIO output according to the GPIO logic. More...
 

Additional Inherited Members

- Public Types inherited from HallSwitch::GPIO
enum  IntEvent_t { INT_FALLING_EDGE = 0, INT_RISING_EDGE = 1 }
 
enum  VLevel_t { GPIO_LOW = 0, GPIO_HIGH = 1 }
 
enum  VLogic_t { NEGATIVE = 1, POSITIVE = 2 }
 

Constructor & Destructor Documentation

GPIOIno::GPIOIno ( )

GPIO Ino default constructor.

GPIOIno::GPIOIno ( uint8_t  pin,
uint8_t  mode,
VLogic_t  logic 
)

GPIO Ino constructor.

GPIOIno::~GPIOIno ( )

GPIO Ino destructor.

Member Function Documentation

HallSwitch::Error_t GPIOIno::init ( )
virtual

Initializes the Arduino GPIO.

Returns
GPIO error code
Return values
OKalways

Implements HallSwitch::GPIO.

HallSwitch::Error_t GPIOIno::deinit ( )
virtual

Deinitializes the Arduino GPIO.

Returns
GPIO error code
Return values
OKalways

Implements HallSwitch::GPIO.

HallSwitch::Error_t GPIOIno::enableInt ( HallSwitch ptr)
virtual

Enables the Arduino GPIO interrupt.

Returns
GPIO error code
Return values
OKalways

Implements HallSwitch::GPIO.

Here is the call graph for this function:

HallSwitch::Error_t GPIOIno::disableInt ( )
inlinevirtual

Disables the Arduino GPIO interrupt.

Returns
GPIO error code
Return values
OKalways

Implements HallSwitch::GPIO.

GPIOIno::IntEvent_t GPIOIno::intEvent ( )
inlinevirtual

Gets the latest Arduino interrupt event.

Returns
GPIO interrupt event
Return values
INT_FALLING_EDGEif falling edge event
INT_RISING_EDGEif rising edge event

Implements HallSwitch::GPIO.

GPIOIno::VLevel_t GPIOIno::read ( )
inlinevirtual

Reads the Arduino GPIO voltage level.

Returns
GPIO voltage level
Return values
GPIO_LOWif voltage low
GPIO_HIGHif voltage high

Implements HallSwitch::GPIO.

HallSwitch::Error_t GPIOIno::write ( VLevel_t  level)
inlinevirtual

Writes the Arduino GPIO output voltage level.

Parameters
[in]levelVoltage level
Returns
GPIO error code
Return values
OKif success
WRITE_ERRORif write error

Implements HallSwitch::GPIO.

HallSwitch::Error_t GPIOIno::enable ( )
inlinevirtual

Enables the Arduino GPIO output according to the GPIO logic.

  • Low if negative
  • High if positive
    Returns
    GPIO interrupt event
    Return values
    OKif success
    WRITE_ERRORif write error

Implements HallSwitch::GPIO.

HallSwitch::Error_t GPIOIno::disable ( )
inlinevirtual

Disables the Arduino GPIO output according to the GPIO logic.

  • Low if positive
  • High if negative
    Returns
    GPIO error code
    Return values
    OKif success
    WRITE_ERRORif write error

Implements HallSwitch::GPIO.


The documentation for this class was generated from the following files: