|
| 1 | +.. _log_rpc: |
| 2 | + |
| 3 | +Logging Remote Procedure Call |
| 4 | +############################# |
| 5 | + |
| 6 | +.. contents:: |
| 7 | + :local: |
| 8 | + :depth: 2 |
| 9 | + |
| 10 | +The Logging Remote Procedure Call (RPC) library enables receiving and managing log messages from a remote device or processor. |
| 11 | + |
| 12 | +Overview |
| 13 | +******** |
| 14 | + |
| 15 | +The library supports the following main features: |
| 16 | + |
| 17 | + * Log streaming, which allows for receiving log messages over RPC in real-time as they are generated by the remote device. |
| 18 | + * Log history, which allows for saving log messages in a ring buffer in RAM or persistent memory, and retrieving them over RPC when needed. |
| 19 | + |
| 20 | +The library also supports retrieving a core dump stored in the remote device's memory, and setting the current time used for log timestamping. |
| 21 | + |
| 22 | +Implementation |
| 23 | +============== |
| 24 | + |
| 25 | +The logging RPC consists of the following components: |
| 26 | + |
| 27 | +* Zephyr's :ref:`zephyr:logging_api` backend that implements sending log messages using :ref:`nrf_rpc`. |
| 28 | + It also accepts RPC commands for managing the logging backend. |
| 29 | +* A log forwarder, which implements receiving log messages from a remote device and passing them to the local logging subsystem. |
| 30 | + It also implements RPC commands for managing the logging backend on the remote device. |
| 31 | + |
| 32 | +Configuration |
| 33 | +************* |
| 34 | + |
| 35 | +To enable the logging RPC backend, set the :kconfig:option:`CONFIG_LOG_BACKEND_RPC` Kconfig option. |
| 36 | + |
| 37 | +To enable the logging RPC forwarder, set the :kconfig:option:`CONFIG_LOG_FORWARDER_RPC` Kconfig option. |
| 38 | + |
| 39 | +Samples using the library |
| 40 | +************************* |
| 41 | + |
| 42 | +The following |NCS| samples use this library: |
| 43 | + |
| 44 | +* :ref:`nrf_rpc_protocols_serialization_client` |
| 45 | +* :ref:`nrf_rpc_protocols_serialization_server` |
| 46 | + |
| 47 | +Dependencies |
| 48 | +************ |
| 49 | + |
| 50 | +The library has the following dependencies: |
| 51 | + |
| 52 | + * :ref:`nrf_rpc` |
| 53 | + * :ref:`zephyr:logging_api` |
| 54 | + |
| 55 | +.. _log_rpc_api: |
| 56 | + |
| 57 | +API documentation |
| 58 | +***************** |
| 59 | + |
| 60 | +| Header file: :file:`include/logging/log_rpc.h` |
| 61 | +| Source files: :file:`subsys/logging` |
| 62 | +
|
| 63 | +.. doxygengroup:: log_rpc |
0 commit comments