Functions | |
cy_en_syspm_status_t | Cy_SCB_EZI2C_DeepSleepCallback (cy_stc_syspm_callback_params_t *callbackParams, cy_en_syspm_callback_mode_t mode) |
This function handles the transition of the EZI2C SCB into and out of Deep Sleep mode. More... | |
__STATIC_INLINE void | Cy_SCB_EZI2C_RegisterDSClockConfig (CySCB_Type const *base, cy_cb_scb_ezi2c_handle_deep_sleep_mode_t callback, cy_stc_scb_ezi2c_context_t *context) |
Registers a callback function that will occur in Cy_SCB_EZI2C_DeepSleepCallback when the EZI2C goes into deepsleep. More... | |
cy_en_syspm_status_t Cy_SCB_EZI2C_DeepSleepCallback | ( | cy_stc_syspm_callback_params_t * | callbackParams, |
cy_en_syspm_callback_mode_t | mode | ||
) |
This function handles the transition of the EZI2C SCB into and out of Deep Sleep mode.
It prevents the device from entering Deep Sleep mode if the EZI2C slave is actively communicating. The following behavior of the EZI2C depends on whether the SCB block is configured as enable-wakeup or not:
This function must be called during execution of Cy_SysPm_CpuEnterDeepSleep. To do this, register this function as a callback before calling Cy_SysPm_CpuEnterDeepSleep : specify CY_SYSPM_DEEPSLEEP as the callback type and call Cy_SysPm_RegisterCallback.
callbackParams | The pointer to the callback parameters structure. cy_stc_syspm_callback_params_t. |
mode | Callback mode, see cy_en_syspm_callback_mode_t |
__STATIC_INLINE void Cy_SCB_EZI2C_RegisterDSClockConfig | ( | CySCB_Type const * | base, |
cy_cb_scb_ezi2c_handle_deep_sleep_mode_t | callback, | ||
cy_stc_scb_ezi2c_context_t * | context | ||
) |
Registers a callback function that will occur in Cy_SCB_EZI2C_DeepSleepCallback when the EZI2C goes into deepsleep.
In the configurator if Deep Sleep Callback is enabled a callback function will be supplied. The function will disable the clock divider when going into deepsleep and enable the clock divider when coming out of deepsleep. If Deep Sleep Callback is not enabled a user defined function must enable and disable the clock dividers.
base | The pointer to the EZI2C SCB instance. |
callback | The pointer to a callback function that will enable and disable the EZI2C clock divider when going into and out of deepsleep. |
context | The pointer to context structure cy_stc_scb_ezi2c_context_t allocated by the user. The structure is used during the EZI2C operation for internal configuration and data retention. The user should not modify anything in this structure. |