Skip to content

Commit

Permalink
nrf_modem: release v2.6.0
Browse files Browse the repository at this point in the history
For a detailed list of changes, see the CHANGELOG file.

Co-authored-by: divya pillai <[email protected]>
Signed-off-by: Emanuele Di Santo <[email protected]>
  • Loading branch information
2 people authored and eivindj-nordic committed Feb 26, 2024
1 parent 3bf59c9 commit 4155c17
Show file tree
Hide file tree
Showing 26 changed files with 1,192 additions and 553 deletions.
6 changes: 6 additions & 0 deletions doc/links.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@

.. _`coex interface of nRF9160`: https://infocenter.nordicsemi.com/index.jsp?topic=%2Fps_nrf9160%2Fip%2Fradio_lte%2Fdoc%2Fmagpio_if.html

.. _`Revision Identification +CGMR`: https://infocenter.nordicsemi.com/topic/ref_at_commands_nrf91x1/REF/at_commands/general/cgmr.html

.. ### Source: www.nordicsemi.com

.. _`nRF9160 modem firmware zip file`: https://www.nordicsemi.com/Products/Low-power-cellular-IoT/nRF9160/Download#0B34B59935AF4AFCB7AB93E9646C1F53
Expand Down Expand Up @@ -106,3 +108,7 @@
.. _`nRF Connect for Desktop`: https://www.nordicsemi.com/Products/Development-tools/nRF-Connect-for-Desktop

.. _`nPM1300 Evaluation Kit`: https://infocenter.nordicsemi.com/

.. _`Wireshark`: https://www.wireshark.org/

.. _`3GPP TS 24.301 Technical Specification`: https://www.3gpp.org/DynaReport/24301.htm
53 changes: 53 additions & 0 deletions nrf_modem/doc/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,59 @@ Changelog

All notable changes to this project are documented in this file.

nrf_modem 2.6.0
***************

Core library
============

* Added the :c:func:`nrf_modem_os_mutex_init`, :c:func:`nrf_modem_os_mutex_lock` and :c:func:`nrf_modem_os_mutex_unlock` functions to meet the OS requirements.
* Fixed a bug where some modem faults during initialization were not sent to the modem fault handler function as intended.

Sockets
=======

* Added:

* The new :c:macro:`NRF_SO_KEEPOPEN` socket option to allow sockets to remain open when their PDN connection is lost, or the device is set to flight mode.
* The RAI socket option :c:macro:`NRF_SO_RAI` and the values ``NRF_RAI_NO_DATA``, ``NRF_RAI_LAST``, ``NRF_RAI_ONE_RESP``, ``NRF_RAI_ONGOING``, and ``NRF_RAI_WAIT_MORE``.
* A set of security tags that can be used for testing and debugging purposes, to allow the `Cellular Monitor`_ application to decrypt TLS traffic.

* Updated:

* The :c:macro:`nrf_sa_family_t` type definition to ``unsigned short`` (from ``unsigned int``), to reduce the size of the socket address types.
* The type of the field :c:member:`nrf_sockaddr.sa_family` to :c:macro:`nrf_sa_family_t` (from ``int``).
* The type of the field :c:member:`nrf_sockaddr_in6.sin6_scope_id` to ``uint8_t`` (from ``uint32_t``).
* The :c:macro:`NRF_SO_RCVTIMEO` socket option can now be used to set a timeout for the :c:func:`nrf_accept` operation.

* Fixed:

* Rare multi-threading bugs in the :c:func:`nrf_socket`, :c:func:`nrf_recv`, and :c:func:`nrf_connect` functions.
* A bug in the :c:func:`nrf_accept` function that caused it to not wait for a connection as intended.
* A bug where the :c:macro:`NRF_POLLNVAL` event would not be reported when using poll callbacks set with the :c:macro:`NRF_SO_POLLCB` socket option.
* A bug where retrieving the value of :c:macro:`NRF_SO_SEC_HOSTNAME` caused a bad memory access, if the option had not been set.

* Deprecated:

* The ``nrf_sec_cipher_t``, ``nrf_sec_peer_verify_t``, ``nrf_sec_role_t``, and ``nrf_sec_session_cache_t`` types. Use ``int`` instead.
* The RAI socket options :c:macro:`NRF_SO_RAI_NO_DATA`, :c:macro:`NRF_SO_RAI_LAST`, :c:macro:`NRF_SO_RAI_ONE_RESP`, :c:macro:`NRF_SO_RAI_ONGOING`, and :c:macro:`NRF_SO_RAI_WAIT_MORE`.

* Removed the field ``nrf_sockaddr_in6.sin6_flowinfo``, to reduce the size of the :c:struct:`nrf_sockaddr_in6` structure. The field was unsupported.

AT interface
============

* Added the :c:func:`nrf_modem_at_cfun_handler_set` function to set a callback for functional mode changes.
* Updated the custom AT commands to be case-insensitive.

GNSS interface
==============

* Added:

* The :c:macro:`NRF_MODEM_GNSS_DELETE_EKF` flag for the :c:func:`nrf_modem_gnss_nv_data_delete` function to delete Extended Kalman Filter (EKF) state data.
* The :c:macro:`NRF_MODEM_GNSS_PVT_FLAG_SCHED_DOWNLOAD` flag to indicate that the GNSS is running because of a scheduled download.

nrf_modem 2.5.0
***************

Expand Down
29 changes: 29 additions & 0 deletions nrf_modem/doc/at_interface.rst
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,35 @@ In this case, the application need not provide any intermediate buffers and can
Conversely, :c:func:`nrf_modem_at_cmd` is the only function in the AT interface that copies the whole response of the modem from the shared memory into the provided input buffer, which is owned by the application.
Therefore, this function can be used when the application needs the whole AT command response, as received from the modem, or in those cases when the stack requirements of :c:func:`nrf_modem_at_scanf` are too high for the calling thread, or when parsing the response using a :c:func:`scanf` format is hard.

CFUN handler
************

The Modem library allows the application to be notified on functional mode changes in the modem by adding a CFUN handler through the :c:func:`nrf_modem_at_cfun_handler_set` function.
The handler is called after a CFUN AT command is successfully processed by the modem.

.. note::
The CFUN handler is not supported with :c:func:`nrf_modem_at_cmd_async`.

The following code snippet shows how to define and set a CFUN handler:

.. code-block:: c
static void cfun_callback(int mode)
{
printk("CFUN changed to %d\n", mode);
if (mode == 0) {
/* Resubscribe to network registration status notifications. */
nrf_modem_at_printf("AT+CEREG=1");
}
}
nrf_modem_at_cfun_handler_set(cfun_callback);
.. important::
If you are building an |NCS| application, do not use the :c:func:`nrf_modem_at_cfun_handler_set` function to register your callback.
Instead, use the :c:macro:`NRF_MODEM_LIB_ON_CFUN` macro to register functional mode changes where you need them in your application, to ensure compatibility with other |NCS| libraries.

Custom AT commands
******************

Expand Down
6 changes: 3 additions & 3 deletions nrf_modem/doc/fault_handling.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ The application can reinitialize the modem by reinitializing the Modem library t
.. important::
If modem traces are enabled, the modem continues to output trace data (a coredump) in the event of a fault, even after signaling the fault to the application.
To make sure the application is able to retrieve the coredump correctly, the application must not re-initialize the modem until all the outstanding trace data has been processed.
The :c:func:`nrf_modem_trace_get()` function will return ``-ENODATA`` when all outstanding trace data has been processed by the application.
The :c:func:`nrf_modem_trace_get` function returns ``-NRF_ENODATA`` when all outstanding trace data has been processed by the application.

When the Modem library is used in |NCS|, the :ref:`nrf_modem_lib_readme` handles synchronizing modem re-initialization with tracing operations.

Expand All @@ -57,5 +57,5 @@ When the Modem library detects that a fault has occurred in the modem, it immedi

Following are the two categories of APIs in the Modem library and their behavior after a modem fault:

* Socket APIs - Exit immediately returning ``-1`` and sets errno to ``NRF_ESHUTDOWN``
* Non-Socket APIs - Exit immediately returning ``-NRF_ESHUTDOWN``
* Socket APIs - Exit immediately returning ``-1`` and sets errno to ``NRF_ESHUTDOWN``.
* Non-Socket APIs - Exit immediately returning ``-NRF_ESHUTDOWN``.
Loading

0 comments on commit 4155c17

Please sign in to comment.