| Electronic Components Datasheet Search |
|
SEC2410 Datasheet(PDF) 167 Page - Microchip Technology |
|
|
|||||||||||||||||||||||||||||
SEC2410 Datasheet(HTML) 167 Page - Microchip Technology |
|
167 / 283 page ![]() 2013 - 2014 Microchip Technology Inc. DS00001587C-page 167 SEC2410/SEC4410 If only a single buffer has been posted, a buffer is available for transfer for EP2_READ if the following condition is met: 1. The buffer at the head of the queue is smaller or equal to the pre-fetch size, and has the last bit set, the whole buffer must be pre-fetched before the endpoint can be enabled. 2. If the buffer at the head of the queue is bigger than the pre-fetch buffer, but less than or equal to an MTU, and has the last bit set, the pre-fetch buffer must be filled before the endpoint can be enabled. If an IN comes in, an AMBA read request is made for the remainder of the data. 3. If the buffer at the head of the queue is bigger then an MTU, the pre-fetch buffer must be filled before the endpoint can be enabled. If an IN comes in, an AMBA read request is made for the remainder of the data in the MTU. Once an MTU’s worth of data has gone, the available buffer is decremented by an MTU size. The remaining buffer is available for the next transfer. If the buffer at the head of the queue has the last bit set, the previous set of conditions apply regardless of the number of buffers posted. If the last bit is not set, and two or more buffers have been posted, a buffer is available for transfer for EP2_READ if the following condition is met: 1. If the sum of the lengths of the top two buffers is less than or equal to the pre-fetch buffer size, both buffers must be pre-fetched before the endpoint can be enabled. 2. If the buffer at the top is smaller than the pre-fetch buffer, and the sum of the top two buffers is greater than the pre-fetch size, the first buffer must be pre-fetched, and enough of the second buffer to fill the pre-fetch buffer. When an IN occurs, the remainder of the second buffer up to an MTU size is fetched. 3. If the buffer at the top is bigger than the pre-fetch buffer, then enough of the buffer is fetched to fill the pre-fetch buffer. When an IN occurs, the remainder of the first buffer is fetched immediately followed by enough of the sec- ond buffer to fulfill an MTU. If more than four buffers are posted to EP2_READ or EP2_WRITE, it is an error with unpredictable results. The MTU size for EP2_READ and EP2_WRITE can be programmed to any valid value. The value in the Endpoint MTU register must exactly match the value in the UDC20 configuration for that endpoint. WR_COUNT for EP2_READ is the number of elements in EP2_READ work queue, and correspondingly WR_COUNT for EP2_WRITE is the number of elements in EP2_WRITE work queue. This number is not affected by the number of CNs pending. 16.1.7.4 Controlling EP3 EP3 in SEC2410/SEC4410 is a Bulk endpoint, with DMA capability. It can operate in Continuous mode or DMA (Block Transfer) mode. EP3_READ and EP3_WRITE should be programmed the same for normal operation, but there is no restriction about programming them differently. If both CONT_MODE and BLK_XFER_EN are set to ‘0’, the endpoint is disabled. In Continuous mode, CONT_MODE is set to ‘1’ and BLK_XFER_EN is set to ‘0’. If there is a buffer available, the trans- port interface will “ACK” an endpoint data request. If there is no buffer available, endpoint data requests will be NAKed. In DMA mode, CONT_MODE is set to ‘0’ and BLK_XFER_EN is set to ‘1’. BLK_XFER_EN must be enabled after setting the EP_CNT for the endpoint to the length of the transfer. If there is a buffer available, the transport interface will “ACK” an endpoint data request. If there is no buffer available, endpoint data requests will be NAKed. During a DMA transfer EP_CNT is reduced by the packet size after each transfer. The reduction can only be done after getting an “good” status from the VCI bus for that transfer. When the count goes down to zero, BLK_XFER_EN is cleared, and BLK_XFER_- COMPLETE is set. If the last reduction results in EP_CNT going less than zero, it is an error, and the OVERFLOW bit is set. A DMA transfer can be terminated prematurely by the following events: 1. If the DMA is to the USB host, (EP3_READ active) and a buffer arrives with the LAST bit set, it will terminate the transfer. If EP_CNT does not go to zero, then the RESIDUAL interrupt is set, indicating an error. 2. If the DMA is from the USB host (EP3_WRITE active), and the host sends a short packet, it will terminate the transfer. If EP_CNT does not go to zero, then the RESIDUAL interrupt is set, indicating an error. 3. If the DMA is from the USB host (EP3_WRITE active), and the host sends a ZLP, it will terminate the transfer. The ZLP interrupt is set, and the RESIDUAL interrupt is set, indicating an error. At the end of each successful packet, the hardware must readjust the WR addresses and length, and issue CNs as appropriate. |
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |