diff --git a/FlippR-Driver/contrib/Input_Config.json b/FlippR-Driver/contrib/Input_Config.json index 3e97d94..5e994f7 100644 --- a/FlippR-Driver/contrib/Input_Config.json +++ b/FlippR-Driver/contrib/Input_Config.json @@ -1,27 +1,27 @@ { - "row": - [ - { - "A": 15 - }, - { - "B": 16 - }, - { - "C": 1 - } - ], - "col" : - [ - { - "A": 4 - }, - { - "B": 5 - }, - { - "C": 6 - } - ], - "data" : 13 + "input" : { + "row": [ + { + "A": 15 + }, + { + "B": 16 + }, + { + "C": 1 + } + ], + "col": [ + { + "A": 4 + }, + { + "B": 5 + }, + { + "C": 6 + } + ], + "data": 13 + } } diff --git a/FlippR-Driver/src/utilities/InputGPIOInterface.cpp b/FlippR-Driver/src/utilities/InputGPIOInterface.cpp index 8f26111..54e2f84 100644 --- a/FlippR-Driver/src/utilities/InputGPIOInterface.cpp +++ b/FlippR-Driver/src/utilities/InputGPIOInterface.cpp @@ -67,11 +67,11 @@ void InputGPIOInterface::init_members(std::istream &input_config_stream) col_address_B = col_json.at("B").get(); col_address_C = col_json.at("C").get(); - data_address = input_config.at("data").get(); + data_address = input_config.at("data").get(); } catch (json::type_error& e) { - CLOG(ERROR, INPUT_LOGGER) << "ERROR"; + CLOG(ERROR, INPUT_LOGGER) << e.what(); } catch (json::out_of_range& e) { - CLOG(ERROR, INPUT_LOGGER) << "ANOTHER ERROR!"; + CLOG(ERROR, INPUT_LOGGER) << e.what(); } }