Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

net: doc: Minor improvements on enabling application libraries #66152

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions doc/_scripts/redirects.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
('application/index', 'develop/application/index'),
('boards/x86/ehl_crb/doc/index', 'boards/x86/intel_ehl/doc/index'),
('boards/x86/rpl_crb/doc/index', 'boards/x86/intel_rpl/doc/index'),
('connectivity/networking/networking-api-usage', 'connectivity/networking/api/index'),
('development_process/code_flow', 'project/code_flow'),
('development_process/index', 'project/index'),
('development_process/issues', 'project/issues'),
Expand Down
3 changes: 2 additions & 1 deletion doc/connectivity/networking/api/coap.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ that support CoAP's features. For more information about the protocol
itself, see `IETF RFC7252 The Constrained Application Protocol <https://tools.ietf.org/html/rfc7252>`_.

Zephyr provides a CoAP library which supports client and server roles.
The library is configurable as per user needs. The Zephyr CoAP library
The library can be enabled with :kconfig:option:`CONFIG_COAP` Kconfig option and
is configurable as per user needs. The Zephyr CoAP library
is implemented using plain buffers. Users of the API create sockets
for communication and pass the buffer to the library for parsing and other
purposes. The library itself doesn't create any sockets for users.
Expand Down
1 change: 1 addition & 0 deletions doc/connectivity/networking/api/coap_client.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Overview
********

The CoAP client library allows application to send CoAP requests and parse CoAP responses.
The library can be enabled with :kconfig:option:`CONFIG_COAP_CLIENT` Kconfig option.
The application is notified about the response via a callback that is provided to the API
in the request. The CoAP client handles the communication over sockets.
As the CoAP client doesn't create socket it is using, the application is responsible for creating
Expand Down
1 change: 1 addition & 0 deletions doc/connectivity/networking/api/http.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Overview
The HTTP client library allows you to send HTTP requests and
parse HTTP responses. The library communicates over the sockets
API but it does not create sockets on its own.
It can be enabled with :kconfig:option:`CONFIG_HTTP_CLIENT` Kconfig option.

The application must be responsible for creating a socket and passing it to the library.
Therefore, depending on the application's needs, the library can communicate over
Expand Down
11 changes: 11 additions & 0 deletions doc/connectivity/networking/api/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,17 @@
Networking APIs
###############

Zephyr provides support for the standard BSD socket APIs (defined in
:zephyr_file:`include/zephyr/net/socket.h`) for the applications to
use. See :ref:`BSD socket API <bsd_sockets_interface>` for more details.

Apart of the standard API, Zephyr provides a set of custom networking APIs and
libraries for the application to use. See the list below for details.

.. note::
The legacy connectivity API in :zephyr_file:`include/zephyr/net/net_context.h`
should not be used by applications.

.. toctree::
:maxdepth: 2

Expand Down
2 changes: 2 additions & 0 deletions doc/connectivity/networking/api/lwm2m.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ REST API to manage various interfaces with the client.
LwM2M uses a simple resource model with the core set of objects and resources
defined in the specification.

The LwM2M library can be enabled with :kconfig:option:`CONFIG_LWM2M` Kconfig option.

Example LwM2M object and resources: Device
******************************************

Expand Down
3 changes: 2 additions & 1 deletion doc/connectivity/networking/api/mqtt.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ publish/subscribe messaging transport for machine-to-machine communication.
For more information about the protocol itself, see http://mqtt.org/.

Zephyr provides an MQTT client library built on top of BSD sockets API. The
library is configurable at a per-client basis, with support for MQTT versions
library can be enabled with :kconfig:option:`CONFIG_MQTT_LIB` Kconfig option and
is configurable at a per-client basis, with support for MQTT versions
3.1.0 and 3.1.1. The Zephyr MQTT implementation can be used with either plain
sockets communicating over TCP, or with secure sockets communicating over
TLS. See :ref:`bsd_sockets_interface` for more information about Zephyr sockets.
Expand Down
3 changes: 2 additions & 1 deletion doc/connectivity/networking/api/mqtt_sn.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ over any message-based transport. Originally, it was mainly created with ZigBee
but others like Bluetooth, UDP or even a UART can be used just as well.

Zephyr provides an MQTT-SN client library built on top of BSD sockets API. The
library is configurable at a per-client basis, with support for MQTT-SN version
library can be enabled with :kconfig:option:`CONFIG_MQTT_SN_LIB` Kconfig option
and is configurable at a per-client basis, with support for MQTT-SN version
1.2. The Zephyr MQTT-SN implementation can be used with any message-based transport,
but support for UDP is already built-in.

Expand Down
4 changes: 4 additions & 0 deletions doc/connectivity/networking/api/sockets.rst
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@ there is a table mapping file descriptors to internal object pointers.
The file descriptor table is used by the BSD Sockets API even if the rest
of the POSIX subsystem (filesystem, stdin/stdout) is not enabled.

See :zephyr:code-sample:`sockets-echo-server` and :zephyr:code-sample:`sockets-echo-client`
sample applications to learn how to create a simple server or client BSD socket based
application.

.. _secure_sockets_interface:

Secure Sockets
Expand Down
6 changes: 6 additions & 0 deletions doc/connectivity/networking/api/tftp.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
TFTP
####

Zephyr provides a simple TFTP client library that can enabled with
:kconfig:option:`CONFIG_MQTT_SN_LIB` Kconfig option.

See :zephyr:code-sample:`TFTP client sample application <tftp-client>` for
more information about the library usage.

API Reference
*************

Expand Down
1 change: 0 additions & 1 deletion doc/connectivity/networking/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ operation of the stacks and how they were implemented.

overview.rst
net-stack-architecture.rst
networking-api-usage.rst
networking_with_host.rst
network_monitoring.rst
api/index.rst
Expand Down
16 changes: 0 additions & 16 deletions doc/connectivity/networking/networking-api-usage.rst
kartben marked this conversation as resolved.
Show resolved Hide resolved

This file was deleted.