The Low-power functions provide an API to implement Low-power callback at the application level.
◆ Cy_USBFS_Dev_Drv_CheckActivity()
__STATIC_INLINE bool Cy_USBFS_Dev_Drv_CheckActivity |
( |
USBFS_Type * |
base | ) |
|
Returns the activity status of the bus.
It clears the hardware status to provide an updated status on the next call of this function. This function is useful to determine whether there is any USB bus activity between function calls. A typical use case is to determine whether the USB suspend conditions are met.
- Parameters
-
base | The pointer to the USBFS instance. |
- Returns
- The bus activity since the last call.
◆ Cy_USBFS_Dev_Drv_Force()
Forces a USB J, K, or SE0 state on the USB lines.
A typical use case is to signal a Remote Wakeup condition on the USB bus.
- Parameters
-
◆ Cy_USBFS_Dev_Drv_Suspend()
Prepares the USBFS component to enter Deep Sleep mode.
- Parameters
-
base | The pointer to the USBFS instance. |
context | The pointer to the context structure cy_stc_usbfs_dev_drv_context_t allocated by the user. The structure is used during the USBFS Device operation for internal configuration and data retention. The user must not modify anything in this structure. |
- Note
- After entering low-power mode, the data that is left in the IN or OUT endpoint buffers is not restored after a wakeup, and is lost. Therefore, it should be stored in the SRAM for OUT endpoint or read by the host for the IN endpoint before entering low-power mode.
◆ Cy_USBFS_Dev_Drv_Resume()
Prepares the USBFS component for operation after exiting Deep Sleep mode.
- Parameters
-
base | The pointer to the USBFS instance. |
context | The pointer to the context structure cy_stc_usbfs_dev_drv_context_t allocated by the user. The structure is used during the USBFS Device operation for internal configuration and data retention. The user must not modify anything in this structure. |