|
Parking Garage Control System
ESP32 Parking Garage – ESP-IDF/FreeRTOS
|
Concrete gate implementation using GPIO. More...
#include <Gate.h>


Public Member Functions | |
| Gate (gpio_num_t lightBarrierPin, gpio_num_t motorPin, ledc_channel_t ledcChannel) | |
| Construct a gate with GPIO pins (without button) | |
| Gate (gpio_num_t buttonPin, uint32_t buttonDebounceMs, gpio_num_t lightBarrierPin, gpio_num_t motorPin, ledc_channel_t ledcChannel) | |
| Construct a gate with GPIO pins and button. | |
| void | open () override |
| Open the barrier. | |
| void | close () override |
| Close the barrier. | |
| bool | isOpen () const override |
| Check if barrier is currently open. | |
| bool | isCarDetected () const override |
| Check if car is detected in light barrier. | |
| bool | hasButton () const |
| Check if gate has a button. | |
| EspGpioInput & | getButton () |
| Get button for interrupt configuration. | |
| EspGpioInput & | getLightBarrier () |
| Get light barrier for interrupt configuration. | |
Public Member Functions inherited from IGate | |
| virtual | ~IGate ()=default |
Concrete gate implementation using GPIO.
Creates and manages light barrier, motor, and optional button hardware
| Gate::Gate | ( | gpio_num_t | lightBarrierPin, |
| gpio_num_t | motorPin, | ||
| ledc_channel_t | ledcChannel | ||
| ) |
Construct a gate with GPIO pins (without button)
| lightBarrierPin | GPIO pin for light barrier sensor |
| motorPin | GPIO pin for barrier motor (servo) |
| ledcChannel | LEDC channel for servo PWM |
| Gate::Gate | ( | gpio_num_t | buttonPin, |
| uint32_t | buttonDebounceMs, | ||
| gpio_num_t | lightBarrierPin, | ||
| gpio_num_t | motorPin, | ||
| ledc_channel_t | ledcChannel | ||
| ) |
Construct a gate with GPIO pins and button.
| buttonPin | GPIO pin for entry button |
| buttonDebounceMs | Button debounce time in milliseconds |
| lightBarrierPin | GPIO pin for light barrier sensor |
| motorPin | GPIO pin for barrier motor (servo) |
| ledcChannel | LEDC channel for servo PWM |
|
overridevirtual |
Close the barrier.
Implements IGate.
|
inline |
Get button for interrupt configuration.
|
inline |
Get light barrier for interrupt configuration.
|
inline |
Check if gate has a button.
|
overridevirtual |
Check if car is detected in light barrier.
Implements IGate.
|
overridevirtual |
Check if barrier is currently open.
Implements IGate.
|
overridevirtual |
Open the barrier.
Implements IGate.