HFCLKAUDIO peripheral driver.
More...
|
|
#define | NRFX_CLOCK_HFCLKAUDIO_EVT_HFCLKAUDIO_STARTED NRFX_BITMASK_TO_BITPOS(NRF_CLOCK_INT_HFAUDIO_STARTED_MASK) |
| | HFCLKAUDIO started event.
|
| |
|
|
typedef void(* | nrfx_clock_hfclkaudio_event_handler_t) (void) |
| | Clock event handler.
|
| |
HFCLKAUDIO peripheral driver.
◆ nrfx_clock_hfclkaudio_config_get()
| NRFX_STATIC_INLINE uint16_t nrfx_clock_hfclkaudio_config_get |
( |
void | | ) |
|
Function for getting the HFCLKAUDIO configuration.
The frequency of HFCLKAUDIO ranges from 10.666 MHz to 13.333 MHz in 40.7 Hz steps. To calculate frequency corresponding to the returned FREQ_VALUE, use the following equation: f_out = 32M * (4 + FREQ_VALUE * 2^(-16))/12
- Returns
- Current value of FREQ_VALUE for HFCLKAUDIO.
◆ nrfx_clock_hfclkaudio_config_set()
| NRFX_STATIC_INLINE void nrfx_clock_hfclkaudio_config_set |
( |
uint16_t | freq_value | ) |
|
Function for setting the HFCLKAUDIO configuration.
The frequency of HFCLKAUDIO ranges from 10.666 MHz to 13.333 MHz in 40.7 Hz steps. To calculate freq_value corresponding to the chosen frequency, use the following equation: FREQ_VALUE = 2^16 * ((12 * f_out / 32M) - 4)
- Warning
- Chosen frequency must fit in 11.176 MHz - 11.402 MHz or 12.165 MHz - 12.411 MHz frequency bands.
- Parameters
-
| [in] | freq_value | New FREQ_VALUE for HFCLKAUDIO. |
◆ nrfx_clock_hfclkaudio_init()
Function for initializing internal structures in the nrfx_clock module.
After initialization, the module is in power off state (clocks are not started).
- Parameters
-
| [in] | event_handler | Event handler provided by the user. If not provided, driver works in blocking mode. |
- Return values
-
| 0 | The procedure is successful. |
| -EALREADY | The driver is already initialized. |
◆ nrfx_clock_hfclkaudio_init_check()
| bool nrfx_clock_hfclkaudio_init_check |
( |
void | | ) |
|
Function for checking if the hfclkaudio driver is initialized.
- Return values
-
| true | Driver is already initialized. |
| false | Driver is not initialized. |
◆ nrfx_clock_hfclkaudio_running_check()
| NRFX_STATIC_INLINE bool nrfx_clock_hfclkaudio_running_check |
( |
void | | ) |
|
Function for checking the specified hfclkaudio clock.
- Return values
-
| true | The clock domain is running. |
| false | The clock domain is not running. |