Skip to content

Commit 18b8dce

Browse files
committed
doc: Misc improvements
Doing small updates: - Add doc building - Add missing Kconfig description to Configuration page - Improvements to logging - Remove release plan before v1.0.0 Signed-off-by: Tommi Rantanen <tommi.rantanen@nordicsemi.no>
1 parent 89894a8 commit 18b8dce

5 files changed

Lines changed: 72 additions & 12 deletions

File tree

README.md

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,3 @@ The Serial Modem contains the Serial Modem application for nRF91-based devices,
44
It includes host examples in the form of the Serial Modem AT Client library and the Serial Modem AT Client Shell sample.
55

66
You can find the documentation in the [Serial Modem] (https://docs.nordicsemi.com/bundle/addon-serial_modem-latest/page/index.html) documentation.
7-
8-
Serial Modem release plan looks as follows:
9-
10-
* v0.3.0: 19-Dec-2025
11-
* Aligns with NCS 3.2.0 release meaning SM v0.3.0 will be released 1-10 days after the NCS
12-
* v1.0.0: 20-Feb-2026
13-
* Official Serial Modem release after which changes in v1.x.x releases are backwards compatible

doc/app/sm_build_and_run.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ Using the LwM2M carrier library
215215
The application supports the |NCS| `LwM2M carrier`_ library that you can use to connect to the operator's device management platform.
216216
See the library's documentation for more information and configuration options.
217217

218-
To enable the LwM2M carrier library, add the parameter ``-DOVERLAY_CONFIG=overlay-carrier.conf`` to your build command.
218+
To enable the LwM2M carrier library, add the parameter ``-DEXTRA_CONF_FILE=overlay-carrier.conf`` to your build command.
219219

220220
The CA root certificates that are needed for modem FOTA are not provisioned in the |SM| application.
221221
You can flash the `Cellular: LwM2M carrier`_ sample to write the certificates to modem before flashing the |SM| application, or use the `Cellular: AT Client`_ sample as explained in `preparing the Cellular: LwM2M Client sample for production <lwm2m_client_provisioning_>`_.

doc/app/sm_configuration.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,14 @@ CONFIG_SM_UART_TX_BUF_SIZE - Send buffer size for UART.
203203
This option defines the size of the buffer for sending (TX) UART traffic.
204204
The default value is 256.
205205

206+
.. _CONFIG_SM_URC_BUFFER_SIZE:
207+
208+
CONFIG_SM_URC_BUFFER_SIZE - URC buffer size.
209+
Buffer, in which unsolicited result codes (URC) are stored before being sent to the host.
210+
The buffer has to be large enough to hold the largest URC that can be sent by the modem.
211+
Result codes longer than this size will get dropped.
212+
The default value is 4096.
213+
206214
.. _CONFIG_SM_PPP_FALLBACK_MTU:
207215

208216
CONFIG_SM_PPP_FALLBACK_MTU - Control the MTU used by PPP.

doc/app/sm_logging.rst

Lines changed: 29 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,20 +31,45 @@ To switch to ``UART0`` output for application logs, change the following options
3131
CONFIG_LOG_BACKEND_RTT=n
3232
CONFIG_LOG_BACKEND_UART=y
3333

34+
The default logging level for the |SM| is ``CONFIG_SM_LOG_LEVEL_INF``.
35+
You can get more verbose logs by setting the ``CONFIG_SM_LOG_LEVEL_DBG`` Kconfig option.
36+
37+
TF-M logging must use the same UART as the application. For more details, see `shared TF-M logging`_.
38+
3439
Modem traces
3540
************
3641

3742
To send modem traces over UART on an nRF91 Series DK, configuration must be added for the UART device in the devicetree and Kconfig.
38-
This is done by adding the `modem trace UART snippet`_ when building and programming.
43+
This is done by adding the `modem trace UART snippet`_ (``-Dapp_SNIPPET=nrf91-modem-trace-uart``) when building and programming.
3944

4045
Use the `Cellular Monitor app`_ for capturing and analyzing modem traces.
4146

42-
TF-M logging must use the same UART as the application. For more details, see `shared TF-M logging`_.
47+
.. note::
48+
49+
Modem traces captured through UART are corrupted if application logs through RTT are simultaneously captured.
50+
When capturing modem traces through UART with the `Cellular Monitor app`_ and simultaneously capturing RTT logs, for example, with J-Link RTT Viewer, the modem trace misses packets, and captured packets might have incorrect information.
51+
52+
If you need to capture modem traces and RTT logs at the same time, enable HW flow control for modem trace UART.
53+
This can be done for the `nRF9151 DK <nrf9151dk_>`_ by adding the following change to :file:`app/boards/nrf9151dk_nrf9151_ns.overlay`:
54+
55+
.. parsed-literal::
56+
:class: highlight
57+
58+
&uart1 {
59+
hw-flow-control;
60+
};
61+
62+
Otherwise, you can choose not to capture RTT logs.
63+
Having only RTT logs enabled does not cause this issue.
64+
65+
HW flow control prevents the trace UART from sending, when there is no reader for the data.
66+
This in turn prevents the trace UART from suspending as it cannot empty it's buffers.
67+
This increases the overall power consumption by ~700uA even when |SM| is in sleep mode.
4368

4469
.. _sm_modem_trace_cmux:
4570

46-
Collecting modem traces through CMUX backend
47-
********************************************
71+
Modem traces through CMUX
72+
*************************
4873

4974
The |SM| application supports collecting modem traces through the CMUX multiplexer.
5075
When enabled, modem traces are sent through a dedicated CMUX channel, allowing simultaneous AT commands, PPP data, and trace collection over the same serial port.

doc/gsg_guide.rst

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,10 @@ Complete the following steps for building and running:
7070

7171
west build -p -b nrf9151dk/nrf9151/ns
7272

73+
To build the application with Kconfig and DTC overlays and extra Kconfig options, the following command gives an example of how they are passed as build arguments::
74+
75+
west build -p -b nrf9151dk/nrf9151/ns -- -DEXTRA_CONF_FILE="overlay-ppp.conf;overlay-cmux.conf" -DEXTRA_DTC_OVERLAY_FILE="overlay-external-mcu.overlay" -DCONFIG_SM_LOG_LEVEL_DBG=y
76+
7377
#. To program the application, run the following command::
7478

7579
west flash
@@ -90,3 +94,33 @@ The default baud rate is 115200.
9094
To set the manifest path for |SM|, run the following command::
9195

9296
west config manifest.path ncs-serial-modem
97+
98+
Documentation
99+
*************
100+
101+
You only need to build the documentation if you modify the documentation source files, and want to provide the documentation to others.
102+
103+
A minimal documentation setup is provided for Doxygen and Sphinx.
104+
Before continuing, check if you have Doxygen installed.
105+
It is recommended to use the same Doxygen version used in [CI](.github/workflows/doc-build-pr.yml).
106+
107+
Complete the following steps for building the documentation:
108+
109+
#. Change to the ``doc`` folder::
110+
111+
cd doc
112+
113+
#. To install Sphinx, make sure you have a Python installation in place and run::
114+
115+
pip install -r requirements.txt
116+
117+
#. Build API documentation::
118+
119+
doxygen
120+
121+
#. Build HTML documentation::
122+
123+
make html
124+
125+
The output will be stored in the ``doc/_build_sphinx/html/index.html`` file.
126+
You may check for other output formats other than HTML by running ``make help``.

0 commit comments

Comments
 (0)