diff options
-rw-r--r-- | src/Device/Device.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/Device/Device.cpp b/src/Device/Device.cpp index 680cf44..7f92e75 100644 --- a/src/Device/Device.cpp +++ b/src/Device/Device.cpp @@ -25,7 +25,7 @@ const std::regex Device::apFilters("(modalias)|(power)(.*)|(subsystem)|(uevent)"); const std::regex Device::serialModeFilter("(.*)(serial-mode)"); const std::regex Device::mtcdt3HwVersionFilters("(MTCDT3AC)(.*)"); -const std::regex Device::iotRtrVersionFilters("(MTCAP3)(.*)"); // TODO - change it after getting IOTROUTER hardware +const std::regex Device::iotRtrVersionFilters("(IOTR)(.*)"); const std::regex Device::mtrFilters("(MTR-)(.*)"); const std::regex Device::storeFilters( "(.*)(mac-)(.*)|(.*)(-id)|(uuid)|(.*)(/eui)|(.*)(/" @@ -187,14 +187,12 @@ void Device::getSystemTreeJson(const char *dir_name) { capabilityList["serial"] = true; } if (regex_match(fileData, iotRtrVersionFilters)) { - capabilityList["din"] = true; // TODO - remove it when it will be in EEPROM - capabilityList["dout"] = true; // TODO - remove it when it will be in EEPROM /* The order of the elements is important! This array is used to access Digital IOs, in particular in SMS commands! */ - dInputs.push_back("led-power"); //TODO - change it to real names after getting IOTRouter HW - dOutputs.push_back("led-lora"); //TODO - change it to real names after getting IOTRouter HW + dInputs.push_back("USER_DIO_IN"); + dOutputs.push_back("USER_DIO_OUT"); } } else if (strcmp(d_name, "mac-eth") == 0) { deviceInfoList["macAddress"] = fileData; @@ -827,7 +825,7 @@ void Device::writeJson(const rapidjson::Document &json, const std::string &file) bool Device::readJson(rapidjson::Document &json, const std::string &file) { std::ifstream is(file); if (!is.is_open()) { - printWarning("Can't read to %s: %s", file.c_str(), strerror(errno)); + printDebug("Can't read to %s: %s", file.c_str(), strerror(errno)); return false; } rapidjson::IStreamWrapper isw { is }; |