mirror of
https://github.com/zephyrproject-rtos/zephyr
synced 2025-09-14 07:41:56 +00:00
Use the new code-sample directive and roles to document the networking samples so that they show up as "Related samples" when browsing the various relevant networking APIs. Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
17 lines
681 B
ReStructuredText
17 lines
681 B
ReStructuredText
.. _networking_api_usage:
|
|
|
|
Network Connectivity API
|
|
########################
|
|
|
|
Applications should use the BSD socket API defined in
|
|
:zephyr_file:`include/zephyr/net/socket.h` to create a connection, send or receive data,
|
|
and close a connection. The same API can be used when working with UDP or
|
|
TCP data. See :ref:`BSD socket API <bsd_sockets_interface>` for more details.
|
|
|
|
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.
|
|
|
|
The legacy connectivity API in :zephyr_file:`include/zephyr/net/net_context.h` should not be
|
|
used by applications.
|