tinyusb
ehci.h File Reference
#include "common/common.h"

Go to the source code of this file.

Data Structures

union  ehci_link_t
 Link pointer. More...
 
struct  ehci_qtd_t
 Queue Element Transfer Descriptor (section 3.5) More...
 
struct  ehci_qhd_t
 Queue Head (section 3.6) More...
 
struct  ehci_itd_t
 Highspeed Isochronous Transfer Descriptor (section 3.3) More...
 
struct  ehci_sitd_t
 Split (Full-Speed) Isochronous Transfer Descriptor. More...
 
struct  ehci_registers_t
 
struct  ehci_data_t
 
#define HOST_HCD_XFER_INTERRUPT
 
#define EHCI_PERIODIC_LIST   (defined HOST_HCD_XFER_INTERRUPT || defined HOST_HCD_XFER_ISOCHRONOUS)
 
#define EHCI_MAX_QHD   8
 
#define EHCI_MAX_QTD   20
 
#define EHCI_MAX_ITD   4
 
#define EHCI_MAX_SITD   16
 
#define EHCI_CFG_FRAMELIST_SIZE_BITS   7
 
#define EHCI_FRAMELIST_SIZE   (1024 >> EHCI_CFG_FRAMELIST_SIZE_BITS)
 
enum  ehci_queue_element_type_ { EHCI_QUEUE_ELEMENT_ITD = 0, EHCI_QUEUE_ELEMENT_QHD, EHCI_QUEUE_ELEMENT_SITD, EHCI_QUEUE_ELEMENT_FSTN }
 
enum  tusb_pid_ { EHCI_PID_OUT = 0, EHCI_PID_IN, EHCI_PID_SETUP }
 EHCI PID.
 
enum  ehci_interrupt_mask_ {
  EHCI_INT_MASK_USB = BIT_(0), EHCI_INT_MASK_ERROR = BIT_(1), EHCI_INT_MASK_PORT_CHANGE = BIT_(2), EHCI_INT_MASK_FRAMELIST_ROLLOVER = BIT_(3),
  EHCI_INT_MASK_PCI_HOST_SYSTEM_ERROR = BIT_(4), EHCI_INT_MASK_ASYNC_ADVANCE = BIT_(5), EHCI_INT_MASK_NXP_SOF = BIT_(7), EHCI_INT_MASK_NXP_ASYNC = BIT_(18),
  EHCI_INT_MASK_NXP_PERIODIC = BIT_(19), EHCI_INT_MASK_ALL
}
 
enum  ehci_usbcmd_pos_ {
  EHCI_USBCMD_POS_RUN_STOP = 0, EHCI_USBCMD_POS_FRAMELIST_SZIE = 2, EHCI_USBCMD_POS_PERIOD_ENABLE = 4, EHCI_USBCMD_POS_ASYNC_ENABLE = 5,
  EHCI_USBCMD_POS_NXP_FRAMELIST_SIZE_MSB = 15, EHCI_USBCMD_POS_INTERRUPT_THRESHOLD = 16
}
 
enum  ehci_portsc_change_mask_ { EHCI_PORTSC_MASK_CONNECT_STATUS_CHANGE = BIT_(1), EHCI_PORTSC_MASK_PORT_ENABLE_CHAGNE = BIT_(3), EHCI_PORTSC_MASK_OVER_CURRENT_CHANGE = BIT_(5), EHCI_PORTSC_MASK_ALL }
 
 STATIC_ASSERT (sizeof(ehci_qtd_t)==32,"size is not correct")
 
 STATIC_ASSERT (sizeof(ehci_qhd_t)==64,"size is not correct")
 
 STATIC_ASSERT (sizeof(ehci_itd_t)==64,"size is not correct")
 
 STATIC_ASSERT (sizeof(ehci_sitd_t)==32,"size is not correct")
 

Detailed Description

Author
hathach (tinyusb.org)

LICENSE

Software License Agreement (BSD License)

Copyright (c) 2013, hathach (tinyusb.org) All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
  3. Neither the name of the copyright holders nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT INCLUDING NEGLIGENCE OR OTHERWISE ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

This file is part of the tinyusb stack.