rename gpio interface
This commit is contained in:
@@ -20,7 +20,7 @@ namespace detail
|
|||||||
|
|
||||||
Detector::Detector(std::unique_ptr<InputPinController> input_gpio_interface, std::vector<std::shared_ptr<DistributingEvent>> events)
|
Detector::Detector(std::unique_ptr<InputPinController> input_gpio_interface, std::vector<std::shared_ptr<DistributingEvent>> events)
|
||||||
:
|
:
|
||||||
input_gpio_interface(std::move(input_gpio_interface)), events(std::move(events)), is_running(true)
|
input_pin_controller(std::move(input_gpio_interface)), events(std::move(events)), is_running(true)
|
||||||
{
|
{
|
||||||
this->detect_thread = std::thread(&Detector::detect, this);
|
this->detect_thread = std::thread(&Detector::detect, this);
|
||||||
|
|
||||||
@@ -46,7 +46,7 @@ void Detector::check_inputs() const
|
|||||||
{
|
{
|
||||||
for(auto &event : events)
|
for(auto &event : events)
|
||||||
{
|
{
|
||||||
input_gpio_interface->read_data(event->address) ? event->active() : event->inactive();
|
input_pin_controller->read_data(event->address) ? event->active() : event->inactive();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ private:
|
|||||||
void check_inputs() const;
|
void check_inputs() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
const std::unique_ptr<input::InputPinController> input_gpio_interface;
|
const std::unique_ptr<input::InputPinController> input_pin_controller;
|
||||||
|
|
||||||
const std::vector<std::shared_ptr<DistributingEvent>> events;
|
const std::vector<std::shared_ptr<DistributingEvent>> events;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user