detector stuff
This commit is contained in:
@@ -26,8 +26,10 @@ Detector::~Detector()
|
||||
is_running = false;
|
||||
|
||||
detect_thread.join();
|
||||
|
||||
delete this->input_gpio_interface;
|
||||
this->input_gpio_interface = NULL;
|
||||
|
||||
delete this->event_notifier;
|
||||
this->event_notifier = NULL;
|
||||
}
|
||||
@@ -55,7 +57,7 @@ void Detector::detect()
|
||||
|
||||
bool Detector::check_inputs(char& address)
|
||||
{
|
||||
for(int pin = 0; pin < MATRIX_SIZE * MATRIX_SIZE; pin++)
|
||||
for(int pin = 0; pin < (INPUT_MATRIX_SIZE * INPUT_MATRIX_SIZE); pin++)
|
||||
{
|
||||
if(input_gpio_interface->read_input_data(pin))
|
||||
{
|
||||
@@ -64,7 +66,6 @@ bool Detector::check_inputs(char& address)
|
||||
}
|
||||
}
|
||||
return false;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#define SRC_INPUT_INPUTDRIVER_HPP_
|
||||
|
||||
#include "EventHandler.hpp"
|
||||
|
||||
namespace Input
|
||||
{
|
||||
|
||||
|
||||
Reference in New Issue
Block a user