Pipe Packet Management
[Pipe Management]

Functions

static bool Pipe_IsReadWriteAllowed (void)
static bool Pipe_IsINReceived (void)
static bool Pipe_IsOUTReady (void)
static bool Pipe_IsSETUPSent (void)
static void Pipe_ClearSETUP (void)
static void Pipe_ClearIN (void)
static void Pipe_ClearOUT (void)
static bool Pipe_IsNAKReceived (void)
static void Pipe_ClearNAKReceived (void)
static bool Pipe_IsStalled (void)
static void Pipe_ClearStall (void)

Detailed Description

Functions, macros, variables, enums and types related to packet management of pipes.


Function Documentation

static void Pipe_ClearIN ( void   )  [inline, static]

Acknowledges the reception of a setup IN request from the attached device on the currently selected pipe, freeing the bank ready for the next packet.

static void Pipe_ClearNAKReceived ( void   )  [inline, static]

Clears the NAK condition on the currently selected pipe.

See also:
Pipe_IsNAKReceived() for more details.
static void Pipe_ClearOUT ( void   )  [inline, static]

Sends the currently selected pipe's contents to the device as an OUT packet on the selected pipe, freeing the bank ready for the next packet.

static void Pipe_ClearSETUP ( void   )  [inline, static]

Sends the currently selected CONTROL type pipe's contents to the device as a SETUP packet.

static void Pipe_ClearStall ( void   )  [inline, static]

Clears the STALL condition detection flag on the currently selected pipe, but does not clear the STALL condition itself (this must be done via a ClearFeature control request to the device).

static bool Pipe_IsINReceived ( void   )  [inline, static]

Determines if an IN request has been received on the currently selected pipe.

Returns:
Boolean true if the current pipe has received an IN packet, false otherwise.
static bool Pipe_IsNAKReceived ( void   )  [inline, static]

Determines if the device sent a NAK (Negative Acknowledge) in response to the last sent packet on the currently selected pipe. This occurs when the host sends a packet to the device, but the device is not currently ready to handle the packet (i.e. its endpoint banks are full). Once a NAK has been received, it must be cleared using Pipe_ClearNAKReceived() before the previous (or any other) packet can be re-sent.

Returns:
Boolean true if an NAK has been received on the current pipe, false otherwise
static bool Pipe_IsOUTReady ( void   )  [inline, static]

Determines if the currently selected pipe is ready to send an OUT request.

Returns:
Boolean true if the current pipe is ready for an OUT packet, false otherwise.
static bool Pipe_IsReadWriteAllowed ( void   )  [inline, static]

Determines if the currently selected pipe may be read from (if data is waiting in the pipe bank and the pipe is an IN direction, or if the bank is not yet full if the pipe is an OUT direction). This function will return false if an error has occurred in the pipe, or if the pipe is an IN direction and no packet (or an empty packet) has been received, or if the pipe is an OUT direction and the pipe bank is full.

Note:
This function is not valid on CONTROL type pipes.
Returns:
Boolean true if the currently selected pipe may be read from or written to, depending on its direction
static bool Pipe_IsSETUPSent ( void   )  [inline, static]

Determines if no SETUP request is currently being sent to the attached device on the selected CONTROL type pipe.

Returns:
Boolean true if the current pipe is ready for a SETUP packet, false otherwise.
static bool Pipe_IsStalled ( void   )  [inline, static]

Determines if the currently selected pipe has had the STALL condition set by the attached device.

Returns:
Boolean true if the current pipe has been stalled by the attached device, false otherwise
Generated by  doxygen 1.6.3