Fix for x86_64 build fail
[platform/upstream/connectedhomeip.git] / third_party / pigweed / repo / pw_chrono_threadx / docs.rst
1 .. _module-pw_chrono_threadx:
2
3 -=---------------
4 pw_chrono_threadx
5 -----------------
6 ``pw_chrono_threadx`` is a collection of ``pw_chrono`` backends that are
7 implemented using ThreadX.
8
9 .. warning::
10   This module is under construction, not ready for use, and the documentation
11   is incomplete.
12
13 SystemClock backend
14 -------------------
15 The ThreadX based ``system_clock`` backend implements the
16 ``pw_chrono:system_clock`` facade by using ``tx_time_get()``. Before the global
17 singleton SystemClock's SpinLock is constructed the raw result is returned,
18 after the overflows are managed in a thread and IRQ safe manner to produce a
19 signed 64 bit timestamp.
20
21 The ``SystemClock::now()`` must be used more than once per overflow of the
22 native ThreadX ``tx_time_get()`` overflow. Note that this duration may vary if
23 ``tx_time_set()`` is used.
24
25 .. warning::
26 Note that this is not compatible with TX_NO_TIMER as this disables
27 ``tx_time_get()``.
28
29 Build targets
30 -------------
31 The GN build for ``pw_chrono_threadx`` has one target: ``system_clock``.
32 The ``system_clock`` target provides the
33 ``pw_chrono_backend/system_clock_config.h`` and ``pw_chrono_threadx/config.h``
34 headers and the backend for the ``pw_chrono:system_clock``.