summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Hatch <Jeff.Hatch@multitech.com>2017-06-02 16:30:00 -0500
committerJeff Hatch <Jeff.Hatch@multitech.com>2017-06-02 16:30:00 -0500
commitaaf0cae749d393ec18505a4cf28aaeb3dd8e12b0 (patch)
tree35f8f7e6d535179553ce72fc0938c562f94cb197
parent6d647eb03257c107bd818e1c39d137fb28d7c282 (diff)
downloadradio-query-0.4.tar.gz
radio-query-0.4.tar.bz2
radio-query-0.4.zip
Add AT#FWSWITCH support for LNA radio0.4
-rw-r--r--main.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/main.cpp b/main.cpp
index 46d2135..12b5d81 100644
--- a/main.cpp
+++ b/main.cpp
@@ -80,6 +80,7 @@ const uint32_t OPT_SERVICE = 0x00000800;
const uint32_t OPT_TYPE = 0x00001000;
const uint32_t OPT_CARRIER = 0x00002000;
const uint32_t OPT_DATETIME = 0x00004000;
+const uint32_t OPT_ACTIVEFIRMWARE = 0x00008000;
const uint32_t OPT_SUMMARY_STATIC = 0x01000000;
const uint32_t OPT_SUMMARY_NETWORK = 0x02000000;
@@ -255,6 +256,12 @@ int main(int argc, char** argv) {
if(result == CellularRadio::SUCCESS) {
printf("%s %s GMT%s", sDate.c_str(), sTime.c_str(), sZone.c_str());
}
+ } else if(g_iOptions & OPT_ACTIVEFIRMWARE) {
+ std::string sValue;
+ result = g_apRadio->getActiveFirmware(sValue);
+ if(result == CellularRadio::SUCCESS) {
+ printf("%s", sValue.c_str());
+ }
}
if (g_bIstty && result == CellularRadio::CODE::SUCCESS)
@@ -491,6 +498,7 @@ void parseOptions(int argc, char** argv) {
{ "type", no_argument, &iOption, OPT_TYPE },
{ "carrier", no_argument, &iOption, OPT_CARRIER },
{ "datetime", no_argument, &iOption, OPT_DATETIME },
+ { "active-firmware", no_argument, &iOption, OPT_ACTIVEFIRMWARE },
{ "static", no_argument, &iOption, OPT_SUMMARY_STATIC },
{ "dynamic", no_argument, &iOption, OPT_SUMMARY_NETWORK },
{ 0, 0, 0, 0 } };
@@ -595,6 +603,8 @@ void printHelp(const std::string& sApp) {
printf("\t--type\n");
printf("\t--carrier\n");
printf("\t--datetime\n");
+ //Applicable for LTE910-NA1 dual FW images only
+ //printf("\t--active-firmware\n");
printf("\n");
printf("\tSupported Radios:\n");
printf("\t\tHE910, GE910, DE910, CE910\n");