Selects the source of the LFCLK.
- Parameters
-
- Returns
- Error / status code cy_en_sysclk_status_t :
CY_SYSCLK_SUCCESS - the source is successfully set;
CY_SYSCLK_INVALID_STATE - the selected clock source is not enabled or does not working;
CY_SYSCLK_BAD_PARAM - the source parameter is invalid.
- Note
- Applicable to PSOC4 HVMS/PA only.
- Warning
- The Watchdog timer should be unlocked before set source of the LFCLK. Call the Cy_WDT_Unlock() API to unlock the WDT.
- Note
- It takes about (3 + 1) LF clock cycles of the new selected clock to switch away from the old clock to the new clock. Do not disable the original clock during this time.
-
If a clock source is disabled while selected, then the clock merely stops to all sources that receive it. In such a scenario, the disabled clock must be re-enabled, prior to switching FROM this clock source.
-
This function is not re-entrant.
- Function Usage