![]() |
Ultibo API
C/C++ API for Ultibo Core
|
#include <dwcotg.h>
Data Fields | |
| USB_HOST | host |
| SPIN_HANDLE | lock |
| Host lock (Differs from lock in Host portion) (Spin lock due to use by interrupt handler). | |
| uint32_t | irq |
| The IRQ assigned to this host. | |
| uint32_t | powerid |
| The Power ID required to power on this host. | |
| DWC_REGISTERS * | registers |
| Memory mapped registers of the Synopsys DesignWare Hi-Speed USB 2.0 OTG Controller. | |
| uint32_t | channelcount |
| The number of channels available on this host. | |
| THREAD_HANDLE | schedulerthread |
| Thread ID of USB request scheduler thread. | |
| THREAD_HANDLE | completionthread |
| Thread ID of USB request completion thread. | |
| MAILSLOT_HANDLE | schedulermailslot |
| USB requests that have been submitted to the Host but not yet started on a channel. | |
| void * | dmabuffers [DWC_MAX_CHANNELS] |
| DMA buffers allocated for each hardware channel (4 byte aligned / 1 per channel). | |
| USB_REQUEST * | channelrequests [DWC_MAX_CHANNELS] |
| Current USB request pending on each hardware channel (or nil of no request is pending). | |
| uint32_t | channelfreemask |
| Bitmap of channel free (1) or used (0) status. | |
| MUTEX_HANDLE | channelfreelock |
| Lock for access to ChannelFreeMask. | |
| SEMAPHORE_HANDLE | channelfreewait |
| Number of free channels in ChannelFreeMask. | |
| uint32_t | startofframemask |
| Bitmap of channels waiting for Start of Frame. | |
| SPIN_HANDLE | startofframelock |
| Lock for access to StartOfFrameMask (Spin lock due to use by interrupt handler). | |
| uint32_t | lastframenumber |
| Frame Number at the last Start Of Frame interrupt. | |
| USB_HUB_STATUS * | hubstatus |
| Hub status for the root hub. | |
| USB_PORT_STATUS * | portstatus |
| Host port status for the root hub (Obtained from port interrupt due to status change). | |
| USB_DEVICE_STATUS * | devicestatus |
| Device status for the root hub. | |
| USB_HUB_DESCRIPTOR * | hubdescriptor |
| Hub descriptor for the root hub. | |
| USB_DEVICE_DESCRIPTOR * | devicedescriptor |
| Device descriptor for the root hub. | |
| DWC_ROOTHUB_CONFIGURATION * | hubconfiguration |
| Configuration, Interface and Endpoint descriptors for the root hub. | |
| USB_STRING_DESCRIPTOR * | hubstringtable [3] |
| String table for Language, Product and Manufacturer strings for the root hub. | |
| USB_STRING_DESCRIPTOR * | hubproductstring |
| Product identifier string for the root hub. | |
| USB_STRING_DESCRIPTOR * | hublanguagestring |
| Language identifier string for the root hub. | |
| USB_STRING_DESCRIPTOR * | hubmanufacturerstring |
| Manufacturer identifier string for the root hub. | |
| USB_REQUEST * | hubstatuschange |
| Status change request to the root hub interrupt endpoint (nil if no request is pending). | |
| uint32_t | interruptcount |
| Number of interrupt requests received by the host controller. | |
| uint32_t | portinterruptcount |
| Number of port interrupts received by the host controller. | |
| uint32_t | channelinterruptcount |
| Number of channel interrupts received by the host controller. | |
| uint32_t | startofframeinterruptcount |
| Number of start of frame interrupts received by the host controller. | |
| uint32_t | disconnectinterruptcount |
| Number of disconnect interrupts received by the host controller. | |
| uint32_t | resubmitcount |
| Number of requests resubmitted for later retry. | |
| uint32_t | startofframecount |
| Number of requests queued to wait for start of frame. | |
| uint32_t | dmabufferreadcount |
| Number of IN requests that required a DMA buffer copy. | |
| uint32_t | dmabufferwritecount |
| Number of OUT requests that required a DMA buffer copy. | |
| uint32_t | nakresponsecount |
| Number of NAK responses received by the host controller. | |
| uint32_t | nyetresponsecount |
| Number of NYET responses received by the host controller. | |
| uint32_t | stallresponsecount |
| Number of Stall responses received by the host controller. | |
| uint32_t | requestcancelcount |
| Number of requests Cancelled by the host controller. | |
| uint32_t | ahberrorcount |
| Number of AHB errors received by the host controller. | |
| uint32_t | transactionerrorcount |
| Number of transaction errors received by the host controller. | |
| uint32_t | babbleerrorcount |
| Number of babble errors received by the host controller. | |
| uint32_t | excesstransactioncount |
| Number of excess transaction errors received by the host controller. | |
| uint32_t | framelistrollovercount |
| Number of frame list rollover errors received by the host controller. | |
| uint32_t | datatoggleerrorcount |
| Number of data toggle errors received by the host controller. | |
| uint32_t | frameoverruncount |
| Number of frame overrun errors received by the host controller. | |
| uint32_t | shortattemptcount |
| Number of short attempts where transfer size was less than the request size. | |
| uint32_t | startsplitcount |
| Number of start split transactions. | |
| uint32_t | completesplitcount |
| Number of complete split transactions. | |
| uint32_t | completesplitrestartcount |
| Number of times a complete split transaction has been restarted at start split due to errors. | |
| uint32_t | transferrestartcount |
| Number of times a transfer is restarted to continue or retry the transfer. | |
| uint32_t | transactionrestartcount |
| Number of times a transaction is restarted to continue or complete the transfer. | |
| uint32_t | nochannelcompletedcount |
| Number of times the channel completed interrupt bit was not set when a request completed. | |
| uint32_t | nopacketstransferredcount |
| Number of times no packets were transferred but no error occured when a channel halted. | |
| USB_HOST host |
| SPIN_HANDLE lock |
Host lock (Differs from lock in Host portion) (Spin lock due to use by interrupt handler).
| uint32_t irq |
The IRQ assigned to this host.
| uint32_t powerid |
The Power ID required to power on this host.
| DWC_REGISTERS* registers |
Memory mapped registers of the Synopsys DesignWare Hi-Speed USB 2.0 OTG Controller.
| uint32_t channelcount |
The number of channels available on this host.
| THREAD_HANDLE schedulerthread |
Thread ID of USB request scheduler thread.
| THREAD_HANDLE completionthread |
Thread ID of USB request completion thread.
| MAILSLOT_HANDLE schedulermailslot |
USB requests that have been submitted to the Host but not yet started on a channel.
| void* dmabuffers[DWC_MAX_CHANNELS] |
DMA buffers allocated for each hardware channel (4 byte aligned / 1 per channel).
| USB_REQUEST* channelrequests[DWC_MAX_CHANNELS] |
Current USB request pending on each hardware channel (or nil of no request is pending).
| uint32_t channelfreemask |
Bitmap of channel free (1) or used (0) status.
| MUTEX_HANDLE channelfreelock |
Lock for access to ChannelFreeMask.
| SEMAPHORE_HANDLE channelfreewait |
Number of free channels in ChannelFreeMask.
| uint32_t startofframemask |
Bitmap of channels waiting for Start of Frame.
| SPIN_HANDLE startofframelock |
Lock for access to StartOfFrameMask (Spin lock due to use by interrupt handler).
| uint32_t lastframenumber |
Frame Number at the last Start Of Frame interrupt.
| USB_HUB_STATUS* hubstatus |
Hub status for the root hub.
| USB_PORT_STATUS* portstatus |
Host port status for the root hub (Obtained from port interrupt due to status change).
| USB_DEVICE_STATUS* devicestatus |
Device status for the root hub.
| USB_HUB_DESCRIPTOR* hubdescriptor |
Hub descriptor for the root hub.
| USB_DEVICE_DESCRIPTOR* devicedescriptor |
Device descriptor for the root hub.
| DWC_ROOTHUB_CONFIGURATION* hubconfiguration |
Configuration, Interface and Endpoint descriptors for the root hub.
| USB_STRING_DESCRIPTOR* hubstringtable[3] |
String table for Language, Product and Manufacturer strings for the root hub.
| USB_STRING_DESCRIPTOR* hubproductstring |
Product identifier string for the root hub.
| USB_STRING_DESCRIPTOR* hublanguagestring |
Language identifier string for the root hub.
| USB_STRING_DESCRIPTOR* hubmanufacturerstring |
Manufacturer identifier string for the root hub.
| USB_REQUEST* hubstatuschange |
Status change request to the root hub interrupt endpoint (nil if no request is pending).
| uint32_t interruptcount |
Number of interrupt requests received by the host controller.
| uint32_t portinterruptcount |
Number of port interrupts received by the host controller.
| uint32_t channelinterruptcount |
Number of channel interrupts received by the host controller.
| uint32_t startofframeinterruptcount |
Number of start of frame interrupts received by the host controller.
| uint32_t disconnectinterruptcount |
Number of disconnect interrupts received by the host controller.
| uint32_t resubmitcount |
Number of requests resubmitted for later retry.
| uint32_t startofframecount |
Number of requests queued to wait for start of frame.
| uint32_t dmabufferreadcount |
Number of IN requests that required a DMA buffer copy.
| uint32_t dmabufferwritecount |
Number of OUT requests that required a DMA buffer copy.
| uint32_t nakresponsecount |
Number of NAK responses received by the host controller.
| uint32_t nyetresponsecount |
Number of NYET responses received by the host controller.
| uint32_t stallresponsecount |
Number of Stall responses received by the host controller.
| uint32_t requestcancelcount |
Number of requests Cancelled by the host controller.
| uint32_t ahberrorcount |
Number of AHB errors received by the host controller.
| uint32_t transactionerrorcount |
Number of transaction errors received by the host controller.
| uint32_t babbleerrorcount |
Number of babble errors received by the host controller.
| uint32_t excesstransactioncount |
Number of excess transaction errors received by the host controller.
| uint32_t framelistrollovercount |
Number of frame list rollover errors received by the host controller.
| uint32_t datatoggleerrorcount |
Number of data toggle errors received by the host controller.
| uint32_t frameoverruncount |
Number of frame overrun errors received by the host controller.
| uint32_t shortattemptcount |
Number of short attempts where transfer size was less than the request size.
| uint32_t startsplitcount |
Number of start split transactions.
| uint32_t completesplitcount |
Number of complete split transactions.
| uint32_t completesplitrestartcount |
Number of times a complete split transaction has been restarted at start split due to errors.
| uint32_t transferrestartcount |
Number of times a transfer is restarted to continue or retry the transfer.
| uint32_t transactionrestartcount |
Number of times a transaction is restarted to continue or complete the transfer.
| uint32_t nochannelcompletedcount |
Number of times the channel completed interrupt bit was not set when a request completed.
| uint32_t nopacketstransferredcount |
Number of times no packets were transferred but no error occured when a channel halted.