From 934e64af572f3cd01830902dd94e1caf2b69cd32 Mon Sep 17 00:00:00 2001 From: Jonas Zeunert Date: Thu, 20 Sep 2018 21:29:35 +0200 Subject: [PATCH] to string --- FlippR-Driver/contrib/Input_Matrix_Config.json | 1 - FlippR-Driver/src/input/Detector.cpp | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/FlippR-Driver/contrib/Input_Matrix_Config.json b/FlippR-Driver/contrib/Input_Matrix_Config.json index 021ab8e..ad0f692 100644 --- a/FlippR-Driver/contrib/Input_Matrix_Config.json +++ b/FlippR-Driver/contrib/Input_Matrix_Config.json @@ -6,7 +6,6 @@ "address" : 16, "priority" : 1 }, - { "name" : "Left outer exit canal", "address" : 17, diff --git a/FlippR-Driver/src/input/Detector.cpp b/FlippR-Driver/src/input/Detector.cpp index ee84b9d..91219e1 100644 --- a/FlippR-Driver/src/input/Detector.cpp +++ b/FlippR-Driver/src/input/Detector.cpp @@ -43,12 +43,12 @@ void Detector::detect() try { auto event = events.at(address); - CLOG(INFO, INPUT_LOGGER) << "Found event " << event->name << "(" << event->address << ")."; + CLOG(INFO, INPUT_LOGGER) << "Found event " << event->name << "(" << std::to_string(event->address) << ")."; event_notifier->distribute_event(event); } catch(std::out_of_range& e) { - CLOG_N_TIMES(1, WARNING, INPUT_LOGGER) << "Did not found event for address: " << address << " check config-file"; + CLOG_N_TIMES(1, WARNING, INPUT_LOGGER) << "Did not found event for address: " << std::to_string(address) << " check config-file"; } } } @@ -60,7 +60,7 @@ bool Detector::check_inputs(char& address) { if(input_gpio_interface->read_data(pin)) { - CLOG(INFO, INPUT_LOGGER) << "Pin " << pin << " is triggered."; + CLOG(INFO, INPUT_LOGGER) << "Pin " << std::to_string(pin) << " is triggered."; address = pin; return true; }