summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Hatch <Jeff.Hatch@multitech.com>2018-05-25 14:52:15 -0500
committerJeff Hatch <Jeff.Hatch@multitech.com>2018-05-25 14:52:15 -0500
commit4b1e0509379acf7773ffa6575825bffb4c068d13 (patch)
tree7cd1d4184684ba7542fc26e396c92b8c900c5ce6
parentbfcef5e9d1e384cf34ebef0f7cc98858a8445827 (diff)
downloadlibmts-io-1.0.8.tar.gz
libmts-io-1.0.8.tar.bz2
libmts-io-1.0.8.zip
Add support for LE866A1-JS radio for Japan1.0.8
-rw-r--r--Makefile4
-rw-r--r--include/mts/MTS_IO_CellularRadioFactory.h1
-rw-r--r--include/mts/MTS_IO_LE866A1JSRadio.h52
-rw-r--r--include/mts/MTS_IO_LE866Radio.h61
-rw-r--r--src/MTS_IO_CellularRadio.cpp18
-rw-r--r--src/MTS_IO_CellularRadioFactory.cpp6
-rw-r--r--src/MTS_IO_LE866A1JSRadio.cpp38
-rw-r--r--src/MTS_IO_LE866Radio.cpp39
8 files changed, 214 insertions, 5 deletions
diff --git a/Makefile b/Makefile
index b89749c..1377b22 100644
--- a/Makefile
+++ b/Makefile
@@ -15,6 +15,8 @@ MTS_IO_HE910Radio.o \
MTS_IO_HE910DRadio.o \
MTS_IO_HE910EUDRadio.o \
MTS_IO_LE910JN1Radio.o \
+MTS_IO_LE866Radio.o \
+MTS_IO_LE866A1JSRadio.o \
MTS_IO_LE910Radio.o \
MTS_IO_LE910NAGRadio.o \
MTS_IO_LE910NA1Radio.o \
@@ -39,6 +41,8 @@ MTS_IO_HE910Radio.d \
MTS_IO_HE910DRadio.d \
MTS_IO_HE910EUDRadio.d \
MTS_IO_LE910JN1Radio.d \
+MTS_IO_LE866Radio.d \
+MTS_IO_LE866A1JSRadio.d \
MTS_IO_LE910Radio.d \
MTS_IO_LE910NAGRadio.d \
MTS_IO_LE910NA1Radio.d \
diff --git a/include/mts/MTS_IO_CellularRadioFactory.h b/include/mts/MTS_IO_CellularRadioFactory.h
index 8a5aeb9..4eb53c6 100644
--- a/include/mts/MTS_IO_CellularRadioFactory.h
+++ b/include/mts/MTS_IO_CellularRadioFactory.h
@@ -60,6 +60,7 @@ namespace MTS {
virtual CellularRadio* createGE910(const std::string& sPort = CellularRadio::DEFAULT_RADIO_PORT);
virtual CellularRadio* createDE910(const std::string& sPort = CellularRadio::DEFAULT_RADIO_PORT);
virtual CellularRadio* createCE910(const std::string& sPort = CellularRadio::DEFAULT_RADIO_PORT);
+ virtual CellularRadio* createLE866A1JS(const std::string& sPort = CellularRadio::DEFAULT_RADIO_PORT);
protected:
typedef MTS::IO::CellularRadio* (CellularRadioFactory::*CREATEFUNCPTR)(const std::string& sPort);
diff --git a/include/mts/MTS_IO_LE866A1JSRadio.h b/include/mts/MTS_IO_LE866A1JSRadio.h
new file mode 100644
index 0000000..eb7a8c7
--- /dev/null
+++ b/include/mts/MTS_IO_LE866A1JSRadio.h
@@ -0,0 +1,52 @@
+/*
+ * Copyright (C) 2016 by Multi-Tech Systems
+ *
+ * This file is part of libmts-io.
+ *
+ * libmts-io is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * libmts-io is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with libmts-io. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+/*
+ * MTS_IO_LE866A1JS.h
+ *
+ * Created on: May 24, 2018
+ * Author: jeff
+ */
+
+#ifndef INCLUDE_MTS_MTS_IO_LE866A1JSRADIO_H_
+#define INCLUDE_MTS_MTS_IO_LE866A1JSRADIO_H_
+
+#include <mts/MTS_IO_LE910Radio.h>
+
+namespace MTS {
+ namespace IO {
+
+ class LE866A1JSRadio : public LE910Radio {
+
+ public:
+ static const std::string MODEL_NAME;
+
+ LE866A1JSRadio(const std::string& sPort);
+ virtual ~LE866A1JSRadio(){};
+
+ protected:
+
+ private:
+
+ };
+ }
+}
+
+#endif /* INCLUDE_MTS_MTS_IO_LE866A1JSRADIO_H_ */
diff --git a/include/mts/MTS_IO_LE866Radio.h b/include/mts/MTS_IO_LE866Radio.h
new file mode 100644
index 0000000..c11c5b4
--- /dev/null
+++ b/include/mts/MTS_IO_LE866Radio.h
@@ -0,0 +1,61 @@
+/*
+ * MTS_IO_LE866Radio.h
+ *
+ * Created on: May 24, 2018
+ * Author: jeff
+ */
+
+#ifndef INCLUDE_MTS_MTS_IO_LE866RADIO_H_
+#define INCLUDE_MTS_MTS_IO_LE866RADIO_H_
+
+/*
+ * Copyright (C) 2017 by Multi-Tech Systems
+ *
+ * This file is part of libmts-io.
+ *
+ * libmts-io is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * libmts-io is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with libmts-io. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+/*!
+ \file MTS_IO_ME910Radio.cpp
+ \brief A brief description
+
+ A more elaborate description
+*/
+
+#include <mts/MTS_IO_CellularRadio.h>
+
+namespace MTS {
+ namespace IO {
+
+ class LE866Radio : public CellularRadio {
+
+ public:
+ static const std::string MODEL_NAME;
+
+ LE866Radio(const std::string& sLE866Model, const std::string& sPort);
+ virtual ~LE866Radio(){};
+
+ protected:
+
+ private:
+
+
+ };
+ }
+}
+
+
+#endif /* INCLUDE_MTS_MTS_IO_LE866RADIO_H_ */
diff --git a/src/MTS_IO_CellularRadio.cpp b/src/MTS_IO_CellularRadio.cpp
index 6b49546..746d3c5 100644
--- a/src/MTS_IO_CellularRadio.cpp
+++ b/src/MTS_IO_CellularRadio.cpp
@@ -292,8 +292,11 @@ CellularRadio::CODE CellularRadio::convertModelToMtsShortCode(const std::string&
sCode = "H6";
eCode = SUCCESS;
} else if (sModel.find("LE910-JN1") == 0) {
- sCode = "LDC3";
- eCode = SUCCESS;
+ sCode = "LDC3";
+ eCode = SUCCESS;
+ } else if (sModel.find("LE866A1-JS") == 0) {
+ sCode = "LSB3";
+ eCode = SUCCESS;
} else if (sModel.find("LE910-NAG") == 0) {
sCode = "LAT1";
eCode = SUCCESS;
@@ -364,8 +367,11 @@ CellularRadio::CODE CellularRadio::convertModelToType(const std::string& sModel,
sType = VALUE_TYPE_GSM;
eCode = SUCCESS;
} else if (sModel.find("LE910-JN1") == 0) {
- sType = VALUE_TYPE_LTE;
- eCode = SUCCESS;
+ sType = VALUE_TYPE_LTE;
+ eCode = SUCCESS;
+ } else if (sModel.find("LE866A1-JS") == 0) {
+ sType = VALUE_TYPE_LTE;
+ eCode = SUCCESS;
} else if (sModel.find("LE910-NAG") == 0) {
sType = VALUE_TYPE_LTE;
eCode = SUCCESS;
@@ -1556,7 +1562,9 @@ std::string CellularRadio::extractModelFromResult(const std::string& sResult) {
} else if(sResult.find("HE910-EUD") != std::string::npos) {
sModel = "HE910-EUD";
} else if(sResult.find("LE910-JN1") != std::string::npos) {
- sModel = "LE910-JN1";
+ sModel = "LE910-JN1";
+ } else if(sResult.find("LE866A1-JS") != std::string::npos) {
+ sModel = "LE866A1-JS";
} else if(sResult.find("LE910-NAG") != std::string::npos) {
sModel = "LE910-NAG";
} else if(sResult.find("LE910-NA1") != std::string::npos) {
diff --git a/src/MTS_IO_CellularRadioFactory.cpp b/src/MTS_IO_CellularRadioFactory.cpp
index df70d90..7a3f513 100644
--- a/src/MTS_IO_CellularRadioFactory.cpp
+++ b/src/MTS_IO_CellularRadioFactory.cpp
@@ -36,6 +36,7 @@
#include <mts/MTS_IO_LE910EUGRadio.h>
#include <mts/MTS_IO_ME910C1NARadio.h>
#include <mts/MTS_IO_ME910C1NVRadio.h>
+#include <mts/MTS_IO_LE866A1JSRadio.h>
#include <mts/MTS_IO_GE910Radio.h>
#include <mts/MTS_IO_CE910Radio.h>
#include <mts/MTS_IO_DE910Radio.h>
@@ -55,6 +56,7 @@ CellularRadioFactory::CellularRadioFactory() {
m_mCreationMap[GE910Radio::MODEL_NAME] = &CellularRadioFactory::createGE910;
m_mCreationMap[DE910Radio::MODEL_NAME] = &CellularRadioFactory::createDE910;
m_mCreationMap[CE910Radio::MODEL_NAME] = &CellularRadioFactory::createCE910;
+ m_mCreationMap[LE866A1JSRadio::MODEL_NAME] = &CellularRadioFactory::createLE866A1JS;
}
MTS::IO::CellularRadio* CellularRadioFactory::create(const std::string& sModel, const std::string& sPort) {
@@ -161,3 +163,7 @@ CellularRadio* CellularRadioFactory::createDE910(const std::string& sPort) {
CellularRadio* CellularRadioFactory::createCE910(const std::string& sPort) {
return new CE910Radio(sPort);
}
+
+CellularRadio* CellularRadioFactory::createLE866A1JS(const std::string &sPort) {
+ return new LE866A1JSRadio(sPort);
+}
diff --git a/src/MTS_IO_LE866A1JSRadio.cpp b/src/MTS_IO_LE866A1JSRadio.cpp
new file mode 100644
index 0000000..fc5a2ce
--- /dev/null
+++ b/src/MTS_IO_LE866A1JSRadio.cpp
@@ -0,0 +1,38 @@
+/*
+ * Copyright (C) 2018 by Multi-Tech Systems
+ *
+ * This file is part of libmts-io.
+ *
+ * libmts-io is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * libmts-io is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with libmts-io. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+/*
+ * MTS_IO_LE866A1JSRadio.cpp
+ *
+ * Created on: May 24, 2018
+ * Author: jeff
+ */
+
+#include <mts/MTS_IO_LE866A1JSRadio.h>
+
+using namespace MTS::IO;
+
+const std::string LE866A1JSRadio::MODEL_NAME("LE866A1-JS");
+
+LE866A1JSRadio::LE866A1JSRadio(const std::string& sPort)
+: LE910Radio(MODEL_NAME, sPort)
+{
+
+}
diff --git a/src/MTS_IO_LE866Radio.cpp b/src/MTS_IO_LE866Radio.cpp
new file mode 100644
index 0000000..2e92f67
--- /dev/null
+++ b/src/MTS_IO_LE866Radio.cpp
@@ -0,0 +1,39 @@
+/*
+ * Copyright (C) 2018 by Multi-Tech Systems
+ *
+ * This file is part of libmts-io.
+ *
+ * libmts-io is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * libmts-io is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with libmts-io. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+/*
+ * MTS_IO_LE866Radio.cpp
+ *
+ * Created on: May 24, 2018
+ * Author: jeff
+ */
+
+#include <mts/MTS_Text.h>
+#include <mts/MTS_Logger.h>
+#include <mts/MTS_IO_LE866Radio.h>
+
+using namespace MTS::IO;
+
+LE866Radio::LE866Radio(const std::string& sLE866Model, const std::string& sPort)
+: CellularRadio(sLE866Model, sPort)
+{
+
+}
+
+