Parking Garage Control System
ESP32 Parking Garage – ESP-IDF/FreeRTOS
Loading...
Searching...
No Matches
IGpioInput Class Referenceabstract

Interface for GPIO input abstraction. More...

#include <IGpioInput.h>

Inheritance diagram for IGpioInput:

Public Member Functions

virtual ~IGpioInput ()=default
 
virtual bool getLevel () const =0
 Get current logic level of GPIO input.
 
virtual void setInterruptHandler (std::function< void(bool level)> handler)=0
 Set interrupt handler callback.
 
virtual void enableInterrupt ()=0
 Enable interrupt for this GPIO.
 
virtual void disableInterrupt ()=0
 Disable interrupt for this GPIO.
 

Detailed Description

Interface for GPIO input abstraction.

Provides hardware abstraction for GPIO inputs with interrupt support. Enables testability through mock implementations.

Constructor & Destructor Documentation

◆ ~IGpioInput()

virtual IGpioInput::~IGpioInput ( )
virtualdefault

Member Function Documentation

◆ disableInterrupt()

virtual void IGpioInput::disableInterrupt ( )
pure virtual

Disable interrupt for this GPIO.

Implemented in EspGpioInput.

◆ enableInterrupt()

virtual void IGpioInput::enableInterrupt ( )
pure virtual

Enable interrupt for this GPIO.

Implemented in EspGpioInput.

◆ getLevel()

virtual bool IGpioInput::getLevel ( ) const
pure virtual

Get current logic level of GPIO input.

Returns
true if HIGH, false if LOW

Implemented in EspGpioInput.

◆ setInterruptHandler()

virtual void IGpioInput::setInterruptHandler ( std::function< void(bool level)>  handler)
pure virtual

Set interrupt handler callback.

Parameters
handlerFunction called when interrupt triggers (parameter: current level)

Implemented in EspGpioInput.


The documentation for this class was generated from the following file:
Coverage