[an error occurred while processing this directive]
|
Не могу никак завести USB в tms320vc5509. Ну не заходит он в прерывание... У дайте пожайлуста рабочий пример.
Для почты : digi (закорючка) front.ru
/* Config Structures */
USB_EpObj endptObj0 = {
USB_OUT_EP0, /* Endpoint Number */
USB_CTRL, /* Transfer type value */
0x0040, /* Maximum Packet Size Supported by EP */
0x0181, /* Event Mask */
USB_EvISR_handle, /* Pointer to USB event ISR */
0x0000, /* Data Flags */
0x0000, /* Status */
0x6782, /* Endpoint descriptor reg block start addr */
0x6680, /* DMA reg block start addr */
0x0000, /* Total byte count */
0x0000, /* Number of bytes in the active node of the linked list */
NULL, /* Pointer to store the number of bytes moved in (out) */
NULL, /* Active data buffer pointer */
NULL, /* Pointer to NEXT Buffer */
0x0000 /* Event Flag */
void CSL_cfgInit()
{
cfgArray[_cslUsbIndex_++] = &endptObj0;
cfgArray[_cslUsbIndex_++] = &endptObj1;
cfgArray[_cslUsbIndex_] = NULL;
USB_setAPIVectorAddress();
USB_initPLL(12, 48, 0);
USB_init(USB0, cfgArray, 0x0);
}
void main()
{
CSL_cfgInit();
IRQ_globalEnable();
/*
old_intm = IRQ_globalDisable();
IRQ_plug(IRQ_EVT_USB, &Endpt0EvHndler);
IRQ_enable(IRQ_EVT_USB );
IRQ_map(IRQ_EVT_USB);
IRQ_globalRestore(old_intm);
*/
USB_setDevAddr (USB0, 0x03);
USB_stallEndpt (&endptObj0);
USB_connectDev(USB0);
....
}
E-mail: info@telesys.ru