Class GPIOIno
Defined in File pal-gpio-arduino.hpp
Inheritance Relationships
Base Type
public tle5012::GPIOPAL(Class GPIOPAL)
Class Documentation
-
class GPIOIno : public virtual tle5012::GPIOPAL
GPIO platform abstraction layer Arduino API.
Public Functions
-
GPIOIno()
Constructor of the Arduino GPIO class.
This function is setting the basics for a GPIO.
-
GPIOIno(uint8_t pin, uint8_t mode, VLogic_t logic)
Constructor of the Arduino GPIO class.
This function is setting the basics for a GPIO. It allows to set the pin number, mode of the pin and the logic level.
- Parameters:
pin – [in] Number of the desired pin
mode – [in] Defines the mode of the pin (INPUT, OUTPUT, etc.)
logic – [in] Defines the logic level of the pin
-
~GPIOIno()
-
virtual Error_t init()
Initialize the GPIO.
This function is initializing the chosen pin.
- Returns:
Error_t
-
virtual Error_t changeMode(uint8_t mode)
Changes the GPIO mode.
This function changes the mode of the chosen pin.
- Returns:
Error_t
-
virtual Error_t deinit()
Deinitialize the GPIO.
This function deinitialize the chosen pin.
- Returns:
Error_t
-
virtual VLevel_t read()
Read GPIO logic level.
This function reads the logic level of the chosen pin and returns the logic level value.
- Return values:
0 – = GPIO_LOW
1 – = GPIO_HIGH
- Returns:
-
virtual Error_t write(VLevel_t level)
Set GPIO logic level.
This functions sets the logic level of the chosen pin.
- Parameters:
level – [in] Desired logic level of the pin
- Returns:
Error_t
-
virtual Error_t enable()
Enable the GPIO.
This functions enable the chosen pin. Depending on the chosen logic of the pin it sets the right logic level of the pin.
- Returns:
Error_t
-
virtual Error_t disable()
Disable the GPIO.
This functions disables the chosen pin. Depending on the chosen logic of the pin it sets the right logic level of the pin.
- Returns:
Error_t
Public Static Attributes
-
static constexpr uint8_t UNUSED_PIN = 0xFFU
Unused pin
-
GPIOIno()