
USB Basic Firmware <Short Sheet>
R01AN0495EJ0100 Rev.1.00 Page 25 of 32
Apr 15, 2011
(2) Register the HDCD
Figure.. 3.8 Example of coding a Host Application (2)
“r_usb2_HSMPL_apl.c”
void usb2_hstd_MainInit(void)
{
usb2_cstd_TargetInit(); /* Target initialize */
usb2_hstd_PrAplTitle(); /* Print title */
usb2_cstd_WaitUsbip(); /* Wait USB-H/W access enable */
usb2_cstd_AsspConfig(); /* Set ASSP pin_config */
usb2_cstd_SwReset();
usb2_cstd_InitialClock(); /* Start clock */
usb2_cstd_Pinconfig(); /* Set pin_config */
R_usb2_hstd_MgrOpen(); /* Manager open */
R_usb2_hstd_HcdOpen(); /* Hcd open */
R_usb2_hstd_SmplRegistration(); /* Registration */
Å Register the sample HDCD driver (*)
usb2_hstd_HubRegistAll(); /* Hub registration */
/* Condition compilation by the difference of the operating system */
#if USBC_FW_PP == USBC_FW_NONOS_PP
usbc_cstd_ScheInit(); /* Host scheduler init */
usb2_hstd_SetTaskPri();
#endif /* USBC_FW_PP == USBC_FW_NONOS_PP */
usb2_cstd_SetHwFunction(USBC_HOST);
}
*:You can also create/register the HDCD to fit your user system.
Comentarios a estos manuales