Merge branch 'master' of github.com:swinginbird/flippr-code
This commit is contained in:
@@ -15,11 +15,8 @@
|
||||
|
||||
#include <fstream>
|
||||
|
||||
#include "../lib/json/json.hpp"
|
||||
#include "../lib/wiringPi/wiringPi.h"
|
||||
|
||||
using namespace nlohmann;
|
||||
|
||||
class GPIOInterface
|
||||
{
|
||||
public:
|
||||
@@ -35,9 +32,6 @@ public:
|
||||
{
|
||||
return digitalRead(address);
|
||||
}
|
||||
|
||||
protected:
|
||||
json config;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -20,6 +20,9 @@ bool InputGPIOInterface::read_input_data(char pin)
|
||||
write_input_row(pin / MATRIX_SIZE);
|
||||
write_input_col(pin % MATRIX_SIZE);
|
||||
|
||||
// wait for mux to set address
|
||||
std::this_thread::sleep_for(std::chrono::nanoseconds(SLEEP_DURATION_NANO));
|
||||
|
||||
return read_pin(this->input_data_address);
|
||||
}
|
||||
|
||||
|
||||
8
FlippR-Driver/src/utilities/config.h
Normal file
8
FlippR-Driver/src/utilities/config.h
Normal file
@@ -0,0 +1,8 @@
|
||||
/*
|
||||
* BlockingQueue.hpp
|
||||
*
|
||||
* Created on: May 17, 2018
|
||||
* Author: Andreas Schneider, Johannes Wendel, Jonas Zeunert, Rafael Vinci, Dr. Franca Rupprecht
|
||||
*/
|
||||
|
||||
#define INPUT_LOGGER "input_logger"
|
||||
Reference in New Issue
Block a user