diff options
author | Serhii Kostiuk <serhii.o.kostiuk@globallogic.com> | 2020-02-18 17:47:13 +0200 |
---|---|---|
committer | Serhii Kostiuk <serhii.o.kostiuk@globallogic.com> | 2020-02-18 17:47:13 +0200 |
commit | 3b7ac31ffaa0689105030f04a2a1651e19a45664 (patch) | |
tree | 28929b64e419d6883fa9cd66d2aa8a832ca52120 | |
parent | a6d4914dbf938fbf48c6ace4280f97864c1b4866 (diff) | |
download | radio-query-3b7ac31ffaa0689105030f04a2a1651e19a45664.tar.gz radio-query-3b7ac31ffaa0689105030f04a2a1651e19a45664.tar.bz2 radio-query-3b7ac31ffaa0689105030f04a2a1651e19a45664.zip |
[MTX-3232] Add "supportedCellularModes" value to the radio-query --static
This new field will return a comma-separated list of cellular modes (2g,3g,4g)
that are supported by the modem.
This new value allows to handle the list of supported cellular modes in
the same way as we handle other static parameters like modem type and model
without any need to separately call radio-query --supported-cellular-modes.
-rw-r--r-- | main.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -516,6 +516,14 @@ Json::Value getStaticData() { jData[MTS::IO::ICellularRadio::KEY_MIP] = jMip; } + std::string sSupportedCellModes(ICellularRadio::VALUE_UNKNOWN); + ICellularRadio::CELLULAR_MODES supportedCellModes; + + if(g_apRadio->getSupportedCellularModes(supportedCellModes) == ICellularRadio::SUCCESS) { + sSupportedCellModes = cellularModeStr(supportedCellModes).c_str(); + } + jData[MTS::IO::ICellularRadio::KEY_SUPPORTED_CELL_MODES] = sSupportedCellModes; + return jData; } |