3.2.4.2 USB_HOST_Status Function

C

SYS_STATUS USB_HOST_Status(
    SYS_MODULE_OBJ usbHostObject
);

Summary

This routine provides the current status of the USB Host Layer.

Description

Description of the function.

Precondition

Function USB_HOST_Initialize should have been called before calling this function.

Parameters

Parameters Description
usbHostObject USB Host Layer object handle, returned from the USB_HOST_Initialize routine

Returns

SYS_STATUS_READY - Indicates that the USB Host layer is ready for operations.

SYS_STATUS_BUSY - The initialization is in progress.

SYS_STATUS_DEINITIALIZED - Indicates that the driver has been deinitialized.

Example

SYS_MODULE_OBJ      object;     // Returned from USB_HOST_Initialize
SYS_STATUS          status;

status = USB_HOST_Status(object);
if (SYS_STATUS_READY == status)
{
    // The USB Host system is ready and is running.
}

Remarks

This function is typically called by the MPLAB Harmony System to check the system status of the USB Host Layer. This function is not intended to be called directly by the application tasks routine.