<feed xmlns='http://www.w3.org/2005/Atom'>
<title>libmts-io.git/src, branch 1.0.23</title>
<subtitle>MultiTech IO C++ Library</subtitle>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/'/>
<entry>
<title>Allow building agains jsoncpp 1.9.2</title>
<updated>2021-03-06T22:15:59+00:00</updated>
<author>
<name>Mykyta Dorokhin</name>
<email>mykyta.dorokhin@globallogic.com</email>
</author>
<published>2021-03-06T22:15:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=08fb28a8ed9dddc90af27e60d58e21ba6f282425'/>
<id>08fb28a8ed9dddc90af27e60d58e21ba6f282425</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[IN:4046] MTR-MNG2 Dashboard has blank Cellular Mode.</title>
<updated>2020-08-19T16:49:58+00:00</updated>
<author>
<name>Serhii Kostiuk</name>
<email>serhii.o.kostiuk@globallogic.com</email>
</author>
<published>2020-08-19T16:43:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=de5833a550219988ab4becc6f75841ecde38096b'/>
<id>de5833a550219988ab4becc6f75841ecde38096b</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
<entry>
<title>Quectel EG25-G Delta Radio Firmware Upgrade support - libmts-io implementation</title>
<updated>2020-08-07T13:03:56+00:00</updated>
<author>
<name>Serhii Kostiuk</name>
<email>serhii.o.kostiuk@globallogic.com</email>
</author>
<published>2020-08-07T13:03:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=b32dbb2c5f12fbacf598edb812acab816068de00'/>
<id>b32dbb2c5f12fbacf598edb812acab816068de00</id>
<content type='text'>
Small improvements in code comments.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Small improvements in code comments.
</pre>
</div>
</content>
</entry>
<entry>
<title>Quectel EG25-G Delta Radio Firmware Upgrade support - libmts-io implementation</title>
<updated>2020-08-07T12:54:02+00:00</updated>
<author>
<name>Serhii Kostiuk</name>
<email>serhii.o.kostiuk@globallogic.com</email>
</author>
<published>2020-08-06T14:49:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=68437a8e36e60eac503a1e7e6ed66d8acb74ad5d'/>
<id>68437a8e36e60eac503a1e7e6ed66d8acb74ad5d</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
<entry>
<title>Quectel EG25-G Delta Radio Firmware Upgrade support - libmts-io implementation</title>
<updated>2020-08-07T12:52:54+00:00</updated>
<author>
<name>Serhii Kostiuk</name>
<email>serhii.o.kostiuk@globallogic.com</email>
</author>
<published>2020-08-07T08:07:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=5c529e115394ba3d04c7531d046776293e2bf06c'/>
<id>5c529e115394ba3d04c7531d046776293e2bf06c</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
<entry>
<title>Quectel EG25-G Delta Radio Firmware Upgrade support - libmts-io implementation</title>
<updated>2020-08-07T12:52:22+00:00</updated>
<author>
<name>Serhii Kostiuk</name>
<email>serhii.o.kostiuk@globallogic.com</email>
</author>
<published>2020-08-06T11:47:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=c1a58778eecd0115d746afbca1079683b244b672'/>
<id>c1a58778eecd0115d746afbca1079683b244b672</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
<entry>
<title>Quectel EG25-G Delta Radio Firmware Upgrade support - libmts-io implementation</title>
<updated>2020-08-06T11:06:19+00:00</updated>
<author>
<name>Serhii Kostiuk</name>
<email>serhii.o.kostiuk@globallogic.com</email>
</author>
<published>2020-08-06T11:06:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=e1855057708468bc5383d948be70da7179730231'/>
<id>e1855057708468bc5383d948be70da7179730231</id>
<content type='text'>
Added waitResponse overloads to the public interface of ICellularRadio.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Added waitResponse overloads to the public interface of ICellularRadio.
</pre>
</div>
</content>
</entry>
<entry>
<title>Quectel EG25-G Delta Radio Firmware Upgrade support - libmts-io implementation</title>
<updated>2020-08-06T10:22:34+00:00</updated>
<author>
<name>Serhii Kostiuk</name>
<email>serhii.o.kostiuk@globallogic.com</email>
</author>
<published>2020-08-06T10:11:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=96445eaa166dd8f4ba99014f5eea2c1146b9db80'/>
<id>96445eaa166dd8f4ba99014f5eea2c1146b9db80</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
<entry>
<title>Quectel EG25-G Delta Radio Firmware Upgrade support - libmts-io implementation</title>
<updated>2020-08-05T11:10:25+00:00</updated>
<author>
<name>Serhii Kostiuk</name>
<email>serhii.o.kostiuk@globallogic.com</email>
</author>
<published>2020-08-05T11:10:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=c7f63212d7e6596975835f23150ef20aea3b7b96'/>
<id>c7f63212d7e6596975835f23150ef20aea3b7b96</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
<entry>
<title>Quectel EG25-G Delta Radio Firmware Upgrade support - libmts-io implementation</title>
<updated>2020-08-04T09:32:04+00:00</updated>
<author>
<name>Serhii Kostiuk</name>
<email>serhii.o.kostiuk@globallogic.com</email>
</author>
<published>2020-08-04T09:21:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/libmts-io.git/commit/?id=51a4db87617b4dc7d9276e31298d0a9d44ecb69e'/>
<id>51a4db87617b4dc7d9276e31298d0a9d44ecb69e</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
</feed>
