summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/MTS_IO_CellularRadioFactory.cpp4
-rw-r--r--src/MTS_IO_ICellularRadio.cpp24
2 files changed, 25 insertions, 3 deletions
diff --git a/src/MTS_IO_CellularRadioFactory.cpp b/src/MTS_IO_CellularRadioFactory.cpp
index 8ebd8dc..4ee8756 100644
--- a/src/MTS_IO_CellularRadioFactory.cpp
+++ b/src/MTS_IO_CellularRadioFactory.cpp
@@ -199,7 +199,5 @@ ICellularRadio* CellularRadioFactory::createLE866A1JS(const std::string &sPort)
ICellularRadio* CellularRadioFactory::createEG95Radio(const std::string& sPort) const
{
- // TODO: return new EG95Radio(sPort);
- printError("TODO: EG95Radio");
- return new HE910DRadio(sPort);
+ return new EG95Radio(sPort);
}
diff --git a/src/MTS_IO_ICellularRadio.cpp b/src/MTS_IO_ICellularRadio.cpp
index 2f19f3a..7f216d0 100644
--- a/src/MTS_IO_ICellularRadio.cpp
+++ b/src/MTS_IO_ICellularRadio.cpp
@@ -181,6 +181,27 @@ MTS::IO::ICellularRadio::CODE MTS::IO::ICellularRadio::convertModelToMtsShortCod
} else if (sModel.find("DE910") == 0) {
sCode = "EV3";
eCode = SUCCESS;
+ } else if (sModel.find("EG95") == 0) {
+ if (NULL == radioObject) {
+ sCode = VALUE_NOT_SUPPORTED;
+ eCode = ERROR;
+ } else {
+ std::string sValue;
+ eCode = radioObject->getFirmware(sValue);
+ if (eCode != SUCCESS) {
+ sCode = VALUE_NOT_SUPPORTED;
+ eCode = ERROR;
+ } else if (sValue.find("EG95E") != std::string::npos) {
+ sCode = "LEU7";
+ eCode = SUCCESS;
+ } else if (sValue.find("EG95NA") != std::string::npos) {
+ sCode = "LNA7";
+ eCode = SUCCESS;
+ } else {
+ sCode = VALUE_NOT_SUPPORTED;
+ eCode = ERROR;
+ }
+ }
} else {
sCode = VALUE_NOT_SUPPORTED;
printError("RADIO| Could not identify MTS short code from model. [%s]", sModel.c_str());
@@ -274,6 +295,9 @@ MTS::IO::ICellularRadio::CODE MTS::IO::ICellularRadio::convertModelToType(const
} else if (sModel.find("DE910") == 0) {
sType = VALUE_TYPE_CDMA;
eCode = SUCCESS;
+ } else if (sModel.find("EG95") == 0) {
+ sType = VALUE_TYPE_LTE;
+ eCode = SUCCESS;
} else {
sType = VALUE_TYPE_GSM;
eCode = ERROR;