nrfxlib API 3.3.99
Loading...
Searching...
No Matches

◆ mpsl_clock_hfclk_src_request()

int32_t mpsl_clock_hfclk_src_request ( mpsl_clock_hfclk_src_t src,
mpsl_clock_hfclk_request_callback_t hfclk_started_callback )

#include <mpsl/include/mpsl_clock.h>

Request a high frequency clock with a given source.

Will start the high frequency clock with a given source, the startup time of the clock varies and the mpsl_clock_hfclk_src_is_running function can be polled to check if it has started.

Note
Don't use this API if the integration layer of MPSL provides a driver that uses this function. This is the case for applications in the nRF Connect SDK where there is a clock control driver with a corresponding on/off manager.
This API is not supported when an external clock driver has been registered. See also mpsl_clock_ctrl_source_register().
See also
mpsl_clock_hfclk_src_is_running
mpsl_clock_hfclk_src_release
Parameters
[in]srcThe high frequency clock source requested.
[in]hfclk_started_callbackThe callback to be called when the high frequency clock is started. If the function is called multiple times before the clock is started, the callback will be superseded by the last callback.
Return values
0Success, negative value in case of failure.
Note
On nRF54L series SoCs the callback is called when the clock has started and is stable (EVENT_XOTUNED has occurred). The callback will be executed in the context as mpsl_low_priority_process.