Atmel Evaluation Kit for AT32uC3A0512, 32-Bit AVR Microcontroller Atmel ATEVK1105 ATEVK1105 Data Sheet

Product codes
ATEVK1105
Page of 826
514
AT32UC3A
• The firmware may then set the RMWKUP bit to send an upstream resume to the host for a
remote wake-up. This will automatically be done by the controller after 5 ms of inactivity on the
USB bus.
• When the controller sends the upstream resume, the Upstream Resume interrupt (UPRSM) is
raised and SUSP is cleared by hardware.
• RMWKUP is cleared by hardware at the end of the upstream resume.
• If  the  controller  detects  a  valid  “End  of  Resume”  signal  from  the  host,  the  End  of  Resume
interrupt (EORSM) is raised.
30.7.2.10
STALL Request
For each endpoint, the STALL management is performed using:
•the STALL Request bit (STALLRQ) to initiate a STALL request;
•the STALLed interrupt (STALLEDI) raised when a STALL handshake has been sent.
To answer the next request with a STALL handshake, STALLRQ has to be set by setting the
STALLRQS bit. All following requests will be discarded (RXOUTI, etc. will not be set) and hand-
shaked with a STALL until the STALLRQ bit is cleared, what is done by hardware when a new
SETUP packet is received (for control endpoints) or when the STALLRQC bit is set.
Each time a STALL handshake is sent, the STALLEDI flag is set by the USB controller and the
EPXINT interrupt is raised.
30.7.2.10.1
Special Considerations for Control Endpoints
If a SETUP packet is received into a control endpoint for which a STALL is requested, the
Received SETUP interrupt (RXSTPI) is raised and STALLRQ and STALLEDI are cleared by
hardware. The SETUP has to be ACKed.
This management simplifies the enumeration process management. If a command is not sup-
ported or contains an error, the firmware requests a STALL and can return to the main task,
waiting for the next SETUP request.
30.7.2.10.2
STALL Handshake and Retry Mechanism
The retry mechanism has priority over the STALL handshake. A STALL handshake is sent if the
STALLRQ bit is set and if there is no retry required.
30.7.2.11
Management of Control Endpoints
30.7.2.11.1
Overview
A SETUP request is always ACKed. When a new SETUP packet is received, the Received
SETUP interrupt (RXSTPI) is raised, but not the Received OUT Data interrupt (RXOUTI).
The FIFOCON and RWALL bits are irrelevant for control endpoints. The firmware shall therefore
never use them on these endpoints. When read, their value is always 0.
Control endpoints are managed using:
•the  Received  SETUP  interrupt  (RXSTPI)  which  is  raised  when  a  new  SETUP  packet  is
received and which shall be cleared by firmware to acknowledge the packet and to free the
bank;
32058K
AVR32-01/12