samples: drivers: clock_control_litex: clean up use of c domain roles

Simplify how the code sample refers to C objects to be less dependant on
Breathe.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
This commit is contained in:
Benjamin Cabé 2024-06-04 10:01:22 +02:00 committed by Fabio Baltieri
parent 47a0813561
commit f2227bbd51

View File

@ -45,12 +45,9 @@ This configuration defines 2 clock outputs: ``clk0`` and ``clk1`` with default f
Driver Usage
************
The driver is interfaced with the :ref:`Clock Control API <clock_control_api>` function ``clock_control_on()`` and a LiteX driver specific structure:
The driver is interfaced with the :ref:`Clock Control API <clock_control_api>` function ``clock_control_on()`` and a LiteX driver specific structure (:c:struct:`litex_clk_setup`).
.. doxygenstruct:: litex_clk_setup
:project: Zephyr
| To change clock parameter it is needed to cast a pointer to structure ``litex_clk_setup`` onto ``clock_control_subsys_t`` and use it with ``clock_control_on()``.
| To change clock parameter it is needed to cast a pointer to structure :c:struct:`litex_clk_setup` onto :c:type:`clock_control_subsys_t` and use it with :c:func:`clock_control_on()`.
| This code will try to set on ``clk0`` frequency 50MHz, 90 degrees of phase offset and 75% duty cycle.
.. code-block:: c