Age | Commit message (Collapse) | Author | Files |
|
Sorted the MCC/MNC table by PLMN ID to simplify its maintenance.
The content and the format are not changed, only the order of items
in the table.
|
|
Restored the original table of MCC/MNC values that was used to populate
the `MTS_IO_MccMncTable.cpp` file.
This step is required to extend the format of MCC/MNC table with
additional fields and re-generate the file based on new data instead of
changing all the lines by hand.
Also added a script that restores the MCC/MNC table from a CPP file.
|
|
Extended `create-mcc-mnc-table.py` to support writing the resulting
CPP code directly to the target file:
- refactoring: renamed `print_cpp_mcc_mnc_table` to `print_cpp_mcc_mnc_create_table`
to better represent its purpose - printing the body of `MccMncTable::createTable()`;
- refactoring: grouped all the `print_cpp_*` functions to the single `print_cpp` function;
- new feature: printing the code directly to the target file without using stdout;
printing to stdout is used by default for compatibility reasons.
|
|
Extended `create-mcc-mnc-table.py` for CSV support:
- refactoring: renamed the 'network' variable to 'carrier' as it's
named 'carrier' in the CPP code;
- new feature: added support of command-line arguments to select
the source between the website and CSV; the website is used by
default for compatibility reasons.
|
|
Removed MCCs that are not listed by ITU.
|
|
Refactored the `create-mcc-mnc-table.py` script to support generating
`MTS_IO_MccMncTable.cpp` from the website and (in the future) csv files.
The previous script contained a lot of logic related to generating the
MCC/MNC tables in C++ code:
1) printing constant data - functions, comments, etc;
2) formatting and printing the lines with MCC/MNC data;
3) converting MCC and MNC values to unique integers (hashes);
4) parsing the data from the website.
The updated implementation of the script have separated step 4 from all
the other steps which allows to extend the MCC/MNC building logic with
loading MCC/MNC values from a `csv` file in the future.
The behaviour of the script is NOT changed during refactoring. Both the
old and the new version of the script generate exactly the same code
when started on the same source data (website).
|
|
Ported the "generate_mcc_mnc_cpp.py" script to Python 3.
Python 2 is not supported anymore and is not included to the modern
distributions of Linux. The transformation is made mainly by `2to3`
without refactoring and with only minimal changes required to support
Python 3.
|
|
Fixed carrier MCC/MNC table lookup for networks with two-digit conuntry codes.
The original MCC/MNC population script used the following encoding for MCC/MNC values:
- MCC - interpret the original value as hex;
- 2-digit MNC - append "f" and interpret the resulting value as hex;
- 3-digit MNC - interpret the original value as hex.
So during lookup the system shall also use this conversion logic before querying
the information from the table.
|
|
[MTX-3998] mPower R. Apr 2021: +CEMODE shall be set to CEMODE=2 - Quectel - GP-1111
See merge request !38
|
|
GP-1111
Refactoring after review
|
|
GP-1111
Refactoring common functions, telit and quectel functions related to CEMODE switching
|
|
GP-1111
Added CEMODE switching support for Quectel radios
|
|
[GP-1111] mPower R. Apr 2021: +CEMODE shall be set to CEMODE=2 - libmts-io for Telit
See merge request !37
|
|
for Telit
Changes after a code review.
|
|
for Telit
Changes after a code review
|
|
for Telit
Adding an ability to set UE mode of operation to libmts-io.
There was added two clear virtual methods in iCellularRadio,
correct implementation for them for Telit LTE modems and implementation
with error messages for all other.
|
|
Allow building against jsoncpp 1.9.2
See merge request !35
|
|
|
|
[IN:4046] MTR-MNG2 Dashboard has blank Cellular Mode.
See merge request !34
|
|
This commit contains the following changes:
- mark all GSM modes as 2G (EGPRS/EDGE is also 2G/GSM);
- mark NB-IoT and CAT M1 as 4G/LTE.
Those changes allow to correctly display 4G modes for MNG2 and 2G modes for all radios.
|
|
Quectel EG25-G Delta Radio Firmware Upgrade support - libmts-io implementation
See merge request !33
|
|
Small improvements in code comments.
|
|
Switched from `sendCommand` with empty command argument to `waitResponse` for URC analysis.
Sending empty string to the serial interface is undefined behaviour according to the POSIX
standart. More of it, we don't need to execute `write` on file descriptor to wait for URC messages.
It was more like a hack than something that was actually required.
This commit removes the hack and replaces it with a proper waiting for a response.
|
|
This commit fixes additional issue discrovered after implementation of ACK mode.
When a single 1024 bytes long chunk of data is sent to the radio - the radio reports
that it received nothing. Which is a lie according to Wireshark USB logs, data is
actually sent over USB and looks like radio acknowledged it in USB packet.
This issue is reproducible when chunk size is set to 1024 or 512 bytes. This issue
is not reproducible with chunk size of 256 bytes.
When 1025 or 2048 bytes are sent to the radio - all bytes are received just fine and
we get an ACK string for each 1024 bytes of data.
This commit allows to send 2048 bytes long chunks of data, wait for two ACK strings
from the radio and finish transmission successfully.
|
|
During testing I discrovered that EG25-G radio may lose some data during transmission
over Serial AT interface or just freezes and stops responding over Serial AT interface.
When ACK mode is not used, the radio may either return an error:
```
Expected: [+QFUPL: 24312545,fa6b], Actual: [+QFUPL: 17124608,b907
+CME ERROR: 409 // Fail to write the file
]
```
Or it may just freeze on modem_at1 interface and stop responding to AT commands:
```
8:0:34:32|TRACE|RADIO| Sending command [AT]
8:0:34:133|DEBUG|RESULT:
8:0:34:133|DEBUG|Shutting Down
```
This commit implements an alternative, ACK mode for data transmission to prevent data losses.
Data is sent in chunks and the device waits for ACK string from the radio for each chunk.
|
|
Added waitResponse overloads to the public interface of ICellularRadio.
|
|
Refactored MTS::IO::ICellularRadio::sendCommand. Moved response waiting code to the
MTS::IO::ICellularRadio::waitResponse function.
**Motivation**
In many places in the modern libmts-io implementation there are cases when we need to
wait for some response from the radio without executing or sending any commands.
Such places may wait for some URC messages, acknowledge strings during
data transmission and so on.
One way to handle such cases is to use `sendCommand` with `cmd` argument set to an empty
string. It generally works but according to POSIX:
"If count is zero and fd refers to a file other than a regular file, the results are
not specified."
The other way to handle such cases is to use `isNeedMoreData` callback of `sendCommand`
function to analyze all the data on the fly. But this approach may not work for data
transfers when `sendCommand` and its std::string argument may not be used to store binary
data with null characters within.
This commit moves the "wait for the radio to answer" part to the separate function
which allows reusablity of such a code.
|
|
Increase the timeout for +QFUPL response to 10 seconds.
5 seconds is the default timeout for the radio to wait for new data on its serial interface.
+QFUPL response timeout was increased to 10 seconds to debug cases when hardware
flow control fails for some reason and the radio does not receive all the data sent
to it from the device.
|
|
CellularRadio::resetConnection implementations disables serial echo on connection reset.
Serial echo is disabled using ATE0 command, radio may handle it and return an OK response.
During testing I discovered that EG25 radio does not return an OK response in 100ms
(default timeout time) and this OK response may conflict with successive AT commands.
This commit adds a simple "AT" command to be executed before getVendorFirmware to "eat"
all the data accumulated in the buffer.
|
|
During testing with L4G1 device I discovered some inconsistencies in behaviour between
EG25-G device and EG95 devices (EG95-NA and EG95-E).
EG25-G device that I have on hands does not allow to perform downgrades using delta images.
When there is an attempt to apply a downgrade delta image it behaves as the following:
- radio prints `OK`
- radio prints `+QIND: "FOTA",502`
- radio is not rebooted
While EG95 radios always reboot at least once to apply the firmware image. Even if it is not valid.
Also I noticed that detach from the serial bus may take more than 10 seconds in some rare cases.
Thus we need to wait not a fixed amount of time but until the radio actually detaches from the bus.
This commit attempts to address the findings described above.
|
|
Delta Radio Firmware Upgrade implementation uses file management commands for Quectel radios.
Radio behaviour for +QFLST output on EG25 radios is different that on EG95:
- EG95 radios list all files on UFS _with_ "UFS:" prefix;
- EG25 radios list all files on UFS _without_ "UFS:" prefix.
This commit allows to handle both formats of +QFLST output to check file presense.
|
|
[GP-759] Delta Radio Firmware Upgrade support for L4N1
See merge request !32
|
|
Increased the maximum delay for AT#OTAUPW response to 10 seconds.
In some cases 1 second is too short for the radio to start accepting the injected firmware.
|
|
|
|
Quectel Delta Radio Firmware Upgrade support - libmts-io implementation
See merge request !31
|
|
During testing it was discovered that rarely CellularRadio::sendCommand implementation
returns not one line with URC output but multiple lines.
It happened once during testing and development. But is likely to happen again under
increased CPU load and/or when CPU does not keep pace with the serial data flow.
|
|
Added more strict handling for comma-separated data in URC messages to prevent out-of-bounds reads.
|
|
Delta Radio Firmware Upgrade support: LEU7 and L4E1
See merge request !30
|
|
During testing it was discovered that the radio is detached for 4 minutes 40 seconds while
the upgrade is in progress. This was too close to the time limit of 5 minutes set before.
This commit increases attach timeout to 6 minutes to be on the safe side.
|
|
Changes after code review:
1. Handle cases when the number of bytes written is different from the number of bytes requested to transfer.
2. Use fstat instead of lseek to determine the firmware size.
3. Renamed TelitRadio::startWrite and TelitRadio::abortWrite functions to better represent their applicability scope.
|
|
Fixed Quectel checksum calculation algorithm to correctly handle odd file sizes.
|
|
Add vendor firmware version
See merge request !29
|
|
|
|
|
|
|
|
MTX-3404 mPower Oct20: Delta Radio Firmware Upgrade - L4E1 - libmts-io support
See merge request !28
|
|
|
|
|
|
|
|
|