From c8d7d6c4e60bb46766031342955b53afd9c3bc7e Mon Sep 17 00:00:00 2001 From: Jeff Hatch Date: Thu, 21 Jun 2018 08:54:19 -0500 Subject: Update to detect LAT3 or LNA3 with FWSWITCH AT command --- src/MTS_IO_CellularRadio.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/MTS_IO_CellularRadio.cpp b/src/MTS_IO_CellularRadio.cpp index 746d3c5..569f8fc 100644 --- a/src/MTS_IO_CellularRadio.cpp +++ b/src/MTS_IO_CellularRadio.cpp @@ -42,6 +42,7 @@ #include #include #include +#include #include #include #include @@ -301,7 +302,14 @@ CellularRadio::CODE CellularRadio::convertModelToMtsShortCode(const std::string& sCode = "LAT1"; eCode = SUCCESS; } else if (sModel.find("LE910-NA1") == 0) { - sCode = "LNA3"; + std::string cmd = "radio-query --active-firmware"; + std::string result; + int32_t code = MTS::System::cmd(cmd, result); + if (!code) { + sCode = "LNA3"; + } else { + sCode = "LAT3"; + } eCode = SUCCESS; } else if (sModel.find("LE910-SVG") == 0) { sCode = "LVW2"; -- cgit v1.2.3