diff options
Diffstat (limited to 'apps/sm-get-value.cpp')
-rw-r--r-- | apps/sm-get-value.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/apps/sm-get-value.cpp b/apps/sm-get-value.cpp index 115c6ae..b813121 100644 --- a/apps/sm-get-value.cpp +++ b/apps/sm-get-value.cpp @@ -87,9 +87,13 @@ namespace apps { class sm_get_value : public app { public: + sm_get_value() : app("sm-get-value") { + } + + ~sm_get_value() = default; + void add_options(po::options_description_easy_init &options) override { - options - ("help", "produce help message") + options("help", "produce help message") ("device", po::value<string>()->required(), "MAC of device to poll") ("sensor", po::value<vector<unsigned int>>(&sensors)->multitoken(), "Sensor to poll, defaults to all") ("sleep", po::value<unsigned int>(&sleepTime)->default_value(0), @@ -123,7 +127,7 @@ public: loop = sleepTime > 0; do { - cout << "Connecting to device: " << device.getMac().str() << endl; + LOG4CPLUS_INFO(logger, "Connecting to device: " + device.getMac().str()); auto &gatt = device.connectGatt(); try { |