aboutsummaryrefslogtreecommitdiffstats
path: root/Demos/Device
diff options
context:
space:
mode:
authorDean Camera <dean@fourwalledcubicle.com>2010-06-03 15:32:45 +0000
committerDean Camera <dean@fourwalledcubicle.com>2010-06-03 15:32:45 +0000
commitfc92f9969c1fcc2f952f0bd6d09a309a9b3ce02f (patch)
tree1dc0ae98a98bb0a0efa0a7d122b3e1ee63e9e7b2 /Demos/Device
parent9293de249151fb974325ebf8f39b28e0f32524ea (diff)
downloadlufa-fc92f9969c1fcc2f952f0bd6d09a309a9b3ce02f.tar.gz
lufa-fc92f9969c1fcc2f952f0bd6d09a309a9b3ce02f.tar.bz2
lufa-fc92f9969c1fcc2f952f0bd6d09a309a9b3ce02f.zip
Minor documentation cleanups.
Diffstat (limited to 'Demos/Device')
-rw-r--r--Demos/Device/ClassDriver/RNDISEthernet/Lib/ARP.h4
-rw-r--r--Demos/Device/ClassDriver/RNDISEthernet/Lib/DHCP.h32
-rw-r--r--Demos/Device/ClassDriver/RNDISEthernet/Lib/Ethernet.h14
-rw-r--r--Demos/Device/ClassDriver/RNDISEthernet/Lib/EthernetProtocols.h2
-rw-r--r--Demos/Device/ClassDriver/RNDISEthernet/Lib/ICMP.h12
-rw-r--r--Demos/Device/ClassDriver/RNDISEthernet/Lib/IP.h10
-rw-r--r--Demos/Device/ClassDriver/RNDISEthernet/Lib/TCP.h47
-rw-r--r--Demos/Device/ClassDriver/RNDISEthernet/Lib/UDP.h6
-rw-r--r--Demos/Device/Incomplete/Sideshow/Sideshow.h4
-rw-r--r--Demos/Device/LowLevel/Keyboard/Keyboard.h2
-rw-r--r--Demos/Device/LowLevel/MIDI/Descriptors.h8
-rw-r--r--Demos/Device/LowLevel/MIDI/MIDI.h6
-rw-r--r--Demos/Device/LowLevel/MassStorage/MassStorage.h2
-rw-r--r--Demos/Device/LowLevel/RNDISEthernet/Lib/ARP.h4
-rw-r--r--Demos/Device/LowLevel/RNDISEthernet/Lib/DHCP.h32
-rw-r--r--Demos/Device/LowLevel/RNDISEthernet/Lib/Ethernet.h16
-rw-r--r--Demos/Device/LowLevel/RNDISEthernet/Lib/EthernetProtocols.h4
-rw-r--r--Demos/Device/LowLevel/RNDISEthernet/Lib/ICMP.h12
-rw-r--r--Demos/Device/LowLevel/RNDISEthernet/Lib/IP.h10
-rw-r--r--Demos/Device/LowLevel/RNDISEthernet/Lib/RNDIS.h32
-rw-r--r--Demos/Device/LowLevel/RNDISEthernet/Lib/TCP.h47
-rw-r--r--Demos/Device/LowLevel/RNDISEthernet/Lib/UDP.h8
22 files changed, 156 insertions, 158 deletions
diff --git a/Demos/Device/ClassDriver/RNDISEthernet/Lib/ARP.h b/Demos/Device/ClassDriver/RNDISEthernet/Lib/ARP.h
index fce77969d..6ae9b7be3 100644
--- a/Demos/Device/ClassDriver/RNDISEthernet/Lib/ARP.h
+++ b/Demos/Device/ClassDriver/RNDISEthernet/Lib/ARP.h
@@ -45,10 +45,10 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** ARP header operation constant, indicating a request from a host for an address translation */
+ /** ARP header operation constant, indicating a request from a host for an address translation. */
#define ARP_OPERATION_REQUEST 1
- /** ARP header operation constant, indicating a reply from a host giving an address translation */
+ /** ARP header operation constant, indicating a reply from a host giving an address translation. */
#define ARP_OPERATION_REPLY 2
/* Type Defines: */
diff --git a/Demos/Device/ClassDriver/RNDISEthernet/Lib/DHCP.h b/Demos/Device/ClassDriver/RNDISEthernet/Lib/DHCP.h
index cacdd8ffd..2c8c4d884 100644
--- a/Demos/Device/ClassDriver/RNDISEthernet/Lib/DHCP.h
+++ b/Demos/Device/ClassDriver/RNDISEthernet/Lib/DHCP.h
@@ -45,52 +45,52 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** DHCP operation constant, indicating a request from a host to a DHCP server */
+ /** DHCP operation constant, indicating a request from a host to a DHCP server. */
#define DHCP_OP_BOOTREQUEST 0x01
- /** DHCP operation constant, indicating a reply from a DHCP server to a host */
+ /** DHCP operation constant, indicating a reply from a DHCP server to a host. */
#define DHCP_OP_BOOTREPLY 0x02
- /** Hardware type constant, indicating Ethernet as a carrier */
+ /** Hardware type constant, indicating Ethernet as a carrier. */
#define DHCP_HTYPE_ETHERNET 0x01
- /** Magic boot protocol "cookie", inserted into all BOOTP packets (BOOTP is the carrier of DHCP) */
+ /** Magic boot protocol "cookie", inserted into all BOOTP packets (BOOTP is the carrier of DHCP). */
#define DHCP_MAGIC_COOKIE 0x63825363
- /** DHCP option list entry header, indicating that a subnet mask will follow */
+ /** DHCP option list entry header, indicating that a subnet mask will follow. */
#define DHCP_OPTION_SUBNETMASK 1
- /** DHCP option list entry header, indicating that the DHCP message type constant will follow */
+ /** DHCP option list entry header, indicating that the DHCP message type constant will follow. */
#define DHCP_OPTION_MESSAGETYPE 53
- /** DHCP option list entry header, indicating that the IP address of the DHCP server will follow */
+ /** DHCP option list entry header, indicating that the IP address of the DHCP server will follow. */
#define DHCP_OPTION_DHCPSERVER 54
- /** DHCP option list entry header, used to pad out option data */
+ /** DHCP option list entry header, used to pad out option data. */
#define DHCP_OPTION_PAD 0
- /** DHCP option list entry header, indicating the end of option data */
+ /** DHCP option list entry header, indicating the end of option data. */
#define DHCP_OPTION_END 255
- /** Message type constant, used in the DHCP option data field, requesting that a DHCP server offer an IP address */
+ /** Message type constant, used in the DHCP option data field, requesting that a DHCP server offer an IP address. */
#define DHCP_MESSAGETYPE_DISCOVER 1
- /** Message type constant, used in the DHCP option data field, indicating that a DHCP server is offering an IP address */
+ /** Message type constant, used in the DHCP option data field, indicating that a DHCP server is offering an IP address. */
#define DHCP_MESSAGETYPE_OFFER 2
- /** Message type constant, used in the DHCP option data field, requesting that a DHCP server lease a given IP address */
+ /** Message type constant, used in the DHCP option data field, requesting that a DHCP server lease a given IP address. */
#define DHCP_MESSAGETYPE_REQUEST 3
- /** Message type constant, used in the DHCP option data field, declining an offered DHCP server IP address lease */
+ /** Message type constant, used in the DHCP option data field, declining an offered DHCP server IP address lease. */
#define DHCP_MESSAGETYPE_DECLINE 4
- /** Message type constant, used in the DHCP option data field, ACKing a host IP lease request */
+ /** Message type constant, used in the DHCP option data field, ACKing a host IP lease request. */
#define DHCP_MESSAGETYPE_ACK 5
- /** Message type constant, used in the DHCP option data field, NACKing a host IP lease request */
+ /** Message type constant, used in the DHCP option data field, NACKing a host IP lease request. */
#define DHCP_MESSAGETYPE_NACK 6
- /** Message type constant, used in the DHCP option data field, indicating that a host is releasing a leased IP address */
+ /** Message type constant, used in the DHCP option data field, indicating that a host is releasing a leased IP address. */
#define DHCP_MESSAGETYPE_RELEASE 7
/* Type Defines: */
diff --git a/Demos/Device/ClassDriver/RNDISEthernet/Lib/Ethernet.h b/Demos/Device/ClassDriver/RNDISEthernet/Lib/Ethernet.h
index d5e091c13..6e8798302 100644
--- a/Demos/Device/ClassDriver/RNDISEthernet/Lib/Ethernet.h
+++ b/Demos/Device/ClassDriver/RNDISEthernet/Lib/Ethernet.h
@@ -52,13 +52,13 @@
#include "IP.h"
/* Macros: */
- /** Physical MAC address of the USB RNDIS network adapter */
+ /** Physical MAC address of the USB RNDIS network adapter. */
#define ADAPTER_MAC_ADDRESS {0x02, 0x00, 0x02, 0x00, 0x02, 0x00}
- /** Physical MAC address of the virtual server on the network */
+ /** Physical MAC address of the virtual server on the network. */
#define SERVER_MAC_ADDRESS {0x00, 0x01, 0x00, 0x01, 0x00, 0x01}
- /** Physical MAC address of the network broadcast address */
+ /** Physical MAC address of the network broadcast address. */
#define BROADCAST_MAC_ADDRESS {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}
/** Performs a comparison between two MAC addresses, indicating if they are identical.
@@ -70,17 +70,17 @@
*/
#define MAC_COMPARE(MAC1, MAC2) (memcmp(MAC1, MAC2, sizeof(MAC_Address_t)) == 0)
- /** Minimum size of an Ethernet packet in bytes, to conform to the Ethernet V2 packet standard */
+ /** Minimum size of an Ethernet packet in bytes, to conform to the Ethernet V2 packet standard. */
#define ETHERNET_VER2_MINSIZE 0x0600
- /** Return value for all sub protocol handling routines, indicating that no response packet has been generated */
+ /** Return value for all sub protocol handling routines, indicating that no response packet has been generated. */
#define NO_RESPONSE 0
- /** Return value for all sub protocol handling routines, indicating that the packet has not yet been handled */
+ /** Return value for all sub protocol handling routines, indicating that the packet has not yet been handled. */
#define NO_PROCESS -1
/* Type Defines: */
- /** Type define for an Ethernet frame header */
+ /** Type define for an Ethernet frame header. */
typedef struct
{
MAC_Address_t Destination; /**< Physical MAC address of the packet recipient */
diff --git a/Demos/Device/ClassDriver/RNDISEthernet/Lib/EthernetProtocols.h b/Demos/Device/ClassDriver/RNDISEthernet/Lib/EthernetProtocols.h
index 6117fe13e..d5c93c695 100644
--- a/Demos/Device/ClassDriver/RNDISEthernet/Lib/EthernetProtocols.h
+++ b/Demos/Device/ClassDriver/RNDISEthernet/Lib/EthernetProtocols.h
@@ -72,7 +72,7 @@
#define PROTOCOL_SCTP 132
/* Type Defines: */
- /** Type define for a protocol IP address of a device on a network */
+ /** Type define for a protocol IP address of a device on a network. */
typedef struct
{
uint8_t Octets[4]; /**< Individual bytes of an IP address */
diff --git a/Demos/Device/ClassDriver/RNDISEthernet/Lib/ICMP.h b/Demos/Device/ClassDriver/RNDISEthernet/Lib/ICMP.h
index 6c2fbb134..4fe42957c 100644
--- a/Demos/Device/ClassDriver/RNDISEthernet/Lib/ICMP.h
+++ b/Demos/Device/ClassDriver/RNDISEthernet/Lib/ICMP.h
@@ -45,22 +45,22 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** ICMP message type constant, indicating an ICMP ECHO Reply message */
+ /** ICMP message type constant, indicating an ICMP ECHO Reply message. */
#define ICMP_TYPE_ECHOREPLY 0
- /** ICMP message type constant, indicating a packet destination is unreachable */
+ /** ICMP message type constant, indicating a packet destination is unreachable. */
#define ICMP_TYPE_DESTINATIONUNREACHABLE 3
- /** ICMP message type constant, indicating an ICMP Source Quench message */
+ /** ICMP message type constant, indicating an ICMP Source Quench message. */
#define ICMP_TYPE_SOURCEQUENCH 4
- /** ICMP message type constant, indicating an ICMP Redirect message */
+ /** ICMP message type constant, indicating an ICMP Redirect message. */
#define ICMP_TYPE_REDIRECTMESSAGE 5
- /** ICMP message type constant, indicating an ICMP ECHO Request message */
+ /** ICMP message type constant, indicating an ICMP ECHO Request message. */
#define ICMP_TYPE_ECHOREQUEST 8
- /** ICMP message type constant, indicating an ICMP Time Exceeded message */
+ /** ICMP message type constant, indicating an ICMP Time Exceeded message. */
#define ICMP_TYPE_TIMEEXCEEDED 11
/* Type Defines: */
diff --git a/Demos/Device/ClassDriver/RNDISEthernet/Lib/IP.h b/Demos/Device/ClassDriver/RNDISEthernet/Lib/IP.h
index 82f28e80e..ede537ace 100644
--- a/Demos/Device/ClassDriver/RNDISEthernet/Lib/IP.h
+++ b/Demos/Device/ClassDriver/RNDISEthernet/Lib/IP.h
@@ -45,16 +45,18 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** Protocol IP address of the host (client) machine, once assigned by DHCP */
+ /** Protocol IP address of the host (client) machine, once assigned by DHCP. */
#define CLIENT_IP_ADDRESS { 10, 0, 0, 1}
- /** Protocol IP address of the virtual server machine */
+ /** Protocol IP address of the virtual server machine. */
#define SERVER_IP_ADDRESS { 10, 0, 0, 2}
- /** Protocol IP address of the broadcast address */
+ /** Protocol IP address of the broadcast address. */
#define BROADCAST_IP_ADDRESS {0xFF, 0xFF, 0xFF, 0xFF}
- /** Default Time To Live (TTL) value for sent packets, indicating the maximum allowable hops until their destination is reached */
+ /** Default Time To Live (TTL) value for sent packets, indicating the maximum allowable hops until their destination
+ * is reached.
+ */
#define DEFAULT_TTL 128
/** Performs a comparison between two IP addresses, indicating if they are identical.
diff --git a/Demos/Device/ClassDriver/RNDISEthernet/Lib/TCP.h b/Demos/Device/ClassDriver/RNDISEthernet/Lib/TCP.h
index 4baa0898f..059f76dc5 100644
--- a/Demos/Device/ClassDriver/RNDISEthernet/Lib/TCP.h
+++ b/Demos/Device/ClassDriver/RNDISEthernet/Lib/TCP.h
@@ -45,46 +45,46 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** Maximum number of TCP ports which can be open at the one time */
+ /** Maximum number of TCP ports which can be open at the one time. */
#define MAX_OPEN_TCP_PORTS 1
- /** Maximum number of TCP connections which can be sustained at the one time */
+ /** Maximum number of TCP connections which can be sustained at the one time. */
#define MAX_TCP_CONNECTIONS 3
- /** TCP window size, giving the maximum number of bytes which can be buffered at the one time */
+ /** TCP window size, giving the maximum number of bytes which can be buffered at the one time. */
#define TCP_WINDOW_SIZE 512
- /** Port number for HTTP transmissions */
+ /** Port number for HTTP transmissions. */
#define TCP_PORT_HTTP SwapEndian_16(80)
- /** Data direction indicator for a TCP application buffer, indicating data from host-to-device */
+ /** Data direction indicator for a TCP application buffer, indicating data from host-to-device. */
#define TCP_PACKETDIR_IN false
- /** Data direction indicator for a TCP application buffer, indicating data from device-to-host */
+ /** Data direction indicator for a TCP application buffer, indicating data from device-to-host. */
#define TCP_PACKETDIR_OUT true
- /** Congestion Window Reduced TCP flag mask */
+ /** Congestion Window Reduced TCP flag mask. */
#define TCP_FLAG_CWR (1 << 7)
- /** Explicit Congestion Notification TCP flag mask */
+ /** Explicit Congestion Notification TCP flag mask. */
#define TCP_FLAG_ECE (1 << 6)
- /** Urgent TCP flag mask */
+ /** Urgent TCP flag mask. */
#define TCP_FLAG_URG (1 << 5)
- /** Data Acknowledge TCP flag mask */
+ /** Data Acknowledge TCP flag mask. */
#define TCP_FLAG_ACK (1 << 4)
- /** Data Push TCP flag mask */
+ /** Data Push TCP flag mask. */
#define TCP_FLAG_PSH (1 << 3)
- /** Reset TCP flag mask */
+ /** Reset TCP flag mask. */
#define TCP_FLAG_RST (1 << 2)
- /** Synchronize TCP flag mask */
+ /** Synchronize TCP flag mask. */
#define TCP_FLAG_SYN (1 << 1)
- /** Connection Finalize TCP flag mask */
+ /** Connection Finalize TCP flag mask. */
#define TCP_FLAG_FIN (1 << 0)
/** Application macro: Determines if the given application buffer contains a packet received from the host
@@ -147,14 +147,14 @@
#define TCP_APP_CLOSECONNECTION(Connection) MACROS{ Connection->State = TCP_Connection_Closing; }MACROE
/* Enums: */
- /** Enum for possible TCP port states */
+ /** Enum for possible TCP port states. */
enum TCP_PortStates_t
{
TCP_Port_Closed = 0, /**< TCP port closed, no connections to a host may be made on this port. */
TCP_Port_Open = 1, /**< TCP port open, connections to a host may be made on this port. */
};
- /** Enum for possible TCP connection states */
+ /** Enum for possible TCP connection states. */
enum TCP_ConnectionStates_t
{
TCP_Connection_Listen = 0, /**< Listening for a connection from a host */
@@ -171,7 +171,7 @@
};
/* Type Defines: */
- /** Type define for a TCP connection buffer structure, including size, data and direction */
+ /** Type define for a TCP connection buffer structure, including size, data and direction. */
typedef struct
{
uint16_t Length; /**< Length of data in the TCP application buffer */
@@ -180,10 +180,10 @@
bool Ready; /**< If data from host, indicates buffer ready to be read, otherwise indicates
* buffer ready to be sent to the host
*/
- bool InUse; /** Indicates if the buffer is locked to to the current direction, and cannot be changed */
+ bool InUse; /**< Indicates if the buffer is locked to to the current direction, and cannot be changed */
} TCP_ConnectionBuffer_t;
- /** Type define for a TCP connection information structure */
+ /** Type define for a TCP connection information structure. */
typedef struct
{
uint32_t SequenceNumberIn; /**< Current TCP sequence number for host-to-device */
@@ -191,7 +191,7 @@
TCP_ConnectionBuffer_t Buffer; /**< Connection application data buffer */
} TCP_ConnectionInfo_t;
- /** Type define for a complete TCP connection state */
+ /** Type define for a complete TCP connection state. */
typedef struct
{
uint16_t Port; /**< Connection port number on the device */
@@ -201,7 +201,7 @@
uint8_t State; /**< Current connection state, a value from the TCP_ConnectionStates_t enum */
} TCP_ConnectionState_t;
- /** Type define for a TCP port state */
+ /** Type define for a TCP port state. */
typedef struct
{
uint16_t Port; /**< TCP port number on the device */
@@ -210,7 +210,7 @@
TCP_ConnectionBuffer_t* Buffer); /**< Port application handler */
} TCP_PortState_t;
- /** Type define for a TCP packet header */
+ /** Type define for a TCP packet header. */
typedef struct
{
uint16_t SourcePort; /**< Source port of the TCP packet */
@@ -228,9 +228,6 @@
uint16_t UrgentPointer; /**< Urgent data pointer */
} TCP_Header_t;
- /* External Variables: */
- TCP_PortState_t PortStateTable[MAX_OPEN_TCP_PORTS];
-
/* Function Prototypes: */
void TCP_TCPTask(USB_ClassInfo_RNDIS_Device_t* RNDISInterfaceInfo);
void TCP_Init(void);
diff --git a/Demos/Device/ClassDriver/RNDISEthernet/Lib/UDP.h b/Demos/Device/ClassDriver/RNDISEthernet/Lib/UDP.h
index 73f7664f7..ee9052275 100644
--- a/Demos/Device/ClassDriver/RNDISEthernet/Lib/UDP.h
+++ b/Demos/Device/ClassDriver/RNDISEthernet/Lib/UDP.h
@@ -45,14 +45,14 @@
#include "DHCP.h"
/* Macros: */
- /** Source UDP port for a DHCP request */
+ /** Source UDP port for a DHCP request. */
#define UDP_PORT_DHCP_REQUEST 67
- /** Destination UDP port for a DHCP reply */
+ /** Destination UDP port for a DHCP reply. */
#define UDP_PORT_DHCP_REPLY 68
/* Type Defines: */
- /** Type define for a UDP packet header */
+ /** Type define for a UDP packet header. */
typedef struct
{
uint16_t SourcePort; /**< Packet source port */
diff --git a/Demos/Device/Incomplete/Sideshow/Sideshow.h b/Demos/Device/Incomplete/Sideshow/Sideshow.h
index 0f09e6489..9e4b06226 100644
--- a/Demos/Device/Incomplete/Sideshow/Sideshow.h
+++ b/Demos/Device/Incomplete/Sideshow/Sideshow.h
@@ -47,11 +47,11 @@
/* Macros: */
/** Device control request for used in the Microsoft OS Descriptor for retrieving the OS Feature
- * descriptors of the device
+ * descriptors of the device.
*/
#define REQ_GetOSFeatureDescriptor 0x01
- /** Descriptor index for a Microsoft Proprietary Extended Device Compatibility descriptor */
+ /** Descriptor index for a Microsoft Proprietary Extended Device Compatibility descriptor. */
#define EXTENDED_COMPAT_ID_DESCRIPTOR 0x0004
/** LED mask for the library LED driver, to indicate that the USB interface is not ready. */
diff --git a/Demos/Device/LowLevel/Keyboard/Keyboard.h b/Demos/Device/LowLevel/Keyboard/Keyboard.h
index d88b2def3..252d9be2f 100644
--- a/Demos/Device/LowLevel/Keyboard/Keyboard.h
+++ b/Demos/Device/LowLevel/Keyboard/Keyboard.h
@@ -54,7 +54,7 @@
#include <LUFA/Drivers/Board/LEDs.h>
/* Macros: */
- /** Idle period indicating that reports should be sent only when the inputs have changed */
+ /** Idle period indicating that reports should be sent only when the inputs have changed. */
#define HID_IDLE_CHANGESONLY 0
/** HID Class specific request to get the next HID report from the device. */
diff --git a/Demos/Device/LowLevel/MIDI/Descriptors.h b/Demos/Device/LowLevel/MIDI/Descriptors.h
index 672d08a01..70686102e 100644
--- a/Demos/Device/LowLevel/MIDI/Descriptors.h
+++ b/Demos/Device/LowLevel/MIDI/Descriptors.h
@@ -85,11 +85,11 @@
USB_Descriptor_Header_t Header; /**< Regular descriptor header containing the descriptor's type and length */
uint8_t Subtype; /**< Sub type value used to distinguish between audio class specific descriptors */
- uint16_t ACSpecification; /** Binary coded decimal value, indicating the supported Audio Class specification version */
- uint16_t TotalLength; /** Total length of the Audio class specific control descriptors, including this descriptor */
+ uint16_t ACSpecification; /**< Binary coded decimal value, indicating the supported Audio Class specification version */
+ uint16_t TotalLength; /**< Total length of the Audio class specific control descriptors, including this descriptor */
- uint8_t InCollection; /** Total number of audio class interfaces within this device */
- uint8_t InterfaceNumbers[1]; /** Interface numbers of each audio interface */
+ uint8_t InCollection; /**< Total number of audio class interfaces within this device */
+ uint8_t InterfaceNumbers[1]; /**< Interface numbers of each audio interface */
} USB_Audio_Interface_AC_t;
/** Type define for an Audio class specific MIDI streaming interface descriptor. This indicates to the host
diff --git a/Demos/Device/LowLevel/MIDI/MIDI.h b/Demos/Device/LowLevel/MIDI/MIDI.h
index 72512f706..75ac8458e 100644
--- a/Demos/Device/LowLevel/MIDI/MIDI.h
+++ b/Demos/Device/LowLevel/MIDI/MIDI.h
@@ -52,13 +52,13 @@
#include <LUFA/Drivers/Board/Buttons.h>
/* Macros: */
- /** MIDI command for a note on (activation) event */
+ /** MIDI command for a note on (activation) event. */
#define MIDI_COMMAND_NOTE_ON 0x90
- /** MIDI command for a note off (deactivation) event */
+ /** MIDI command for a note off (deactivation) event. */
#define MIDI_COMMAND_NOTE_OFF 0x80
- /** Standard key press velocity value used for all note events, as no pressure sensor is mounted */
+ /** Standard key press velocity value used for all note events, as no pressure sensor is mounted. */
#define MIDI_STANDARD_VELOCITY 64
/** Convenience macro. MIDI channels are numbered from 1-10 (natural numbers) however the logical channel
diff --git a/Demos/Device/LowLevel/MassStorage/MassStorage.h b/Demos/Device/LowLevel/MassStorage/MassStorage.h
index a0b23b979..0d05283f3 100644
--- a/Demos/Device/LowLevel/MassStorage/MassStorage.h
+++ b/Demos/Device/LowLevel/MassStorage/MassStorage.h
@@ -103,7 +103,7 @@
{
uint32_t Signature; /**< Command block signature, must be CBW_SIGNATURE to indicate a valid Command Block */
uint32_t Tag; /**< Unique command ID value, to associate a command block wrapper with its command status wrapper */
- uint32_t DataTransferLength; /** Length of the optional data portion of the issued command, in bytes */
+ uint32_t DataTransferLength; /**< Length of the optional data portion of the issued command, in bytes */
uint8_t Flags; /**< Command block flags, indicating command data direction */
uint8_t LUN; /**< Logical Unit number this command is issued to */
uint8_t SCSICommandLength; /**< Length of the issued SCSI command within the SCSI command data array */
diff --git a/Demos/Device/LowLevel/RNDISEthernet/Lib/ARP.h b/Demos/Device/LowLevel/RNDISEthernet/Lib/ARP.h
index fce77969d..6ae9b7be3 100644
--- a/Demos/Device/LowLevel/RNDISEthernet/Lib/ARP.h
+++ b/Demos/Device/LowLevel/RNDISEthernet/Lib/ARP.h
@@ -45,10 +45,10 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** ARP header operation constant, indicating a request from a host for an address translation */
+ /** ARP header operation constant, indicating a request from a host for an address translation. */
#define ARP_OPERATION_REQUEST 1
- /** ARP header operation constant, indicating a reply from a host giving an address translation */
+ /** ARP header operation constant, indicating a reply from a host giving an address translation. */
#define ARP_OPERATION_REPLY 2
/* Type Defines: */
diff --git a/Demos/Device/LowLevel/RNDISEthernet/Lib/DHCP.h b/Demos/Device/LowLevel/RNDISEthernet/Lib/DHCP.h
index cacdd8ffd..2c8c4d884 100644
--- a/Demos/Device/LowLevel/RNDISEthernet/Lib/DHCP.h
+++ b/Demos/Device/LowLevel/RNDISEthernet/Lib/DHCP.h
@@ -45,52 +45,52 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** DHCP operation constant, indicating a request from a host to a DHCP server */
+ /** DHCP operation constant, indicating a request from a host to a DHCP server. */
#define DHCP_OP_BOOTREQUEST 0x01
- /** DHCP operation constant, indicating a reply from a DHCP server to a host */
+ /** DHCP operation constant, indicating a reply from a DHCP server to a host. */
#define DHCP_OP_BOOTREPLY 0x02
- /** Hardware type constant, indicating Ethernet as a carrier */
+ /** Hardware type constant, indicating Ethernet as a carrier. */
#define DHCP_HTYPE_ETHERNET 0x01
- /** Magic boot protocol "cookie", inserted into all BOOTP packets (BOOTP is the carrier of DHCP) */
+ /** Magic boot protocol "cookie", inserted into all BOOTP packets (BOOTP is the carrier of DHCP). */
#define DHCP_MAGIC_COOKIE 0x63825363
- /** DHCP option list entry header, indicating that a subnet mask will follow */
+ /** DHCP option list entry header, indicating that a subnet mask will follow. */
#define DHCP_OPTION_SUBNETMASK 1
- /** DHCP option list entry header, indicating that the DHCP message type constant will follow */
+ /** DHCP option list entry header, indicating that the DHCP message type constant will follow. */
#define DHCP_OPTION_MESSAGETYPE 53
- /** DHCP option list entry header, indicating that the IP address of the DHCP server will follow */
+ /** DHCP option list entry header, indicating that the IP address of the DHCP server will follow. */
#define DHCP_OPTION_DHCPSERVER 54
- /** DHCP option list entry header, used to pad out option data */
+ /** DHCP option list entry header, used to pad out option data. */
#define DHCP_OPTION_PAD 0
- /** DHCP option list entry header, indicating the end of option data */
+ /** DHCP option list entry header, indicating the end of option data. */
#define DHCP_OPTION_END 255
- /** Message type constant, used in the DHCP option data field, requesting that a DHCP server offer an IP address */
+ /** Message type constant, used in the DHCP option data field, requesting that a DHCP server offer an IP address. */
#define DHCP_MESSAGETYPE_DISCOVER 1
- /** Message type constant, used in the DHCP option data field, indicating that a DHCP server is offering an IP address */
+ /** Message type constant, used in the DHCP option data field, indicating that a DHCP server is offering an IP address. */
#define DHCP_MESSAGETYPE_OFFER 2
- /** Message type constant, used in the DHCP option data field, requesting that a DHCP server lease a given IP address */
+ /** Message type constant, used in the DHCP option data field, requesting that a DHCP server lease a given IP address. */
#define DHCP_MESSAGETYPE_REQUEST 3
- /** Message type constant, used in the DHCP option data field, declining an offered DHCP server IP address lease */
+ /** Message type constant, used in the DHCP option data field, declining an offered DHCP server IP address lease. */
#define DHCP_MESSAGETYPE_DECLINE 4
- /** Message type constant, used in the DHCP option data field, ACKing a host IP lease request */
+ /** Message type constant, used in the DHCP option data field, ACKing a host IP lease request. */
#define DHCP_MESSAGETYPE_ACK 5
- /** Message type constant, used in the DHCP option data field, NACKing a host IP lease request */
+ /** Message type constant, used in the DHCP option data field, NACKing a host IP lease request. */
#define DHCP_MESSAGETYPE_NACK 6
- /** Message type constant, used in the DHCP option data field, indicating that a host is releasing a leased IP address */
+ /** Message type constant, used in the DHCP option data field, indicating that a host is releasing a leased IP address. */
#define DHCP_MESSAGETYPE_RELEASE 7
/* Type Defines: */
diff --git a/Demos/Device/LowLevel/RNDISEthernet/Lib/Ethernet.h b/Demos/Device/LowLevel/RNDISEthernet/Lib/Ethernet.h
index 4bae3c4df..e83bad85f 100644
--- a/Demos/Device/LowLevel/RNDISEthernet/Lib/Ethernet.h
+++ b/Demos/Device/LowLevel/RNDISEthernet/Lib/Ethernet.h
@@ -50,13 +50,13 @@
#include "IP.h"
/* Macros: */
- /** Physical MAC address of the USB RNDIS network adapter */
+ /** Physical MAC address of the USB RNDIS network adapter. */
#define ADAPTER_MAC_ADDRESS {0x02, 0x00, 0x02, 0x00, 0x02, 0x00}
- /** Physical MAC address of the virtual server on the network */
+ /** Physical MAC address of the virtual server on the network. */
#define SERVER_MAC_ADDRESS {0x00, 0x01, 0x00, 0x01, 0x00, 0x01}
- /** Physical MAC address of the network broadcast address */
+ /** Physical MAC address of the network broadcast address. */
#define BROADCAST_MAC_ADDRESS {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF}
/** Performs a comparison between two MAC addresses, indicating if they are identical.
@@ -68,16 +68,16 @@
*/
#define MAC_COMPARE(MAC1, MAC2) (memcmp(MAC1, MAC2, sizeof(MAC_Address_t)) == 0)
- /** Maximum size of an incoming or outgoing Ethernet frame in bytes */
+ /** Maximum size of an incoming or outgoing Ethernet frame in bytes. */
#define ETHERNET_FRAME_SIZE_MAX 1500
- /** Minimum size of an Ethernet packet in bytes, to conform to the Ethernet V2 packet standard */
+ /** Minimum size of an Ethernet packet in bytes, to conform to the Ethernet V2 packet standard. */
#define ETHERNET_VER2_MINSIZE 0x0600
- /** Return value for all sub protocol handling routines, indicating that no response packet has been generated */
+ /** Return value for all sub protocol handling routines, indicating that no response packet has been generated. */
#define NO_RESPONSE 0
- /** Return value for all sub protocol handling routines, indicating that the packet has not yet been handled */
+ /** Return value for all sub protocol handling routines, indicating that the packet has not yet been handled. */
#define NO_PROCESS -1
/* Type Defines: */
@@ -89,7 +89,7 @@
bool FrameInBuffer; /**< Indicates if a frame is currently stored in the buffer */
} Ethernet_Frame_Info_t;
- /** Type define for an Ethernet frame header */
+ /** Type define for an Ethernet frame header. */
typedef struct
{
MAC_Address_t Destination; /**< Physical MAC address of the packet recipient */
diff --git a/Demos/Device/LowLevel/RNDISEthernet/Lib/EthernetProtocols.h b/Demos/Device/LowLevel/RNDISEthernet/Lib/EthernetProtocols.h
index 665e110c4..014a441cf 100644
--- a/Demos/Device/LowLevel/RNDISEthernet/Lib/EthernetProtocols.h
+++ b/Demos/Device/LowLevel/RNDISEthernet/Lib/EthernetProtocols.h
@@ -72,13 +72,13 @@
#define PROTOCOL_SCTP 132
/* Type Defines: */
- /** Type define for a physical MAC address of a device on a network */
+ /** Type define for a physical MAC address of a device on a network. */
typedef struct
{
uint8_t Octets[6]; /**< Individual bytes of a MAC address */
} MAC_Address_t;
- /** Type define for a protocol IP address of a device on a network */
+ /** Type define for a protocol IP address of a device on a network. */
typedef struct
{
uint8_t Octets[4]; /**< Individual bytes of an IP address */
diff --git a/Demos/Device/LowLevel/RNDISEthernet/Lib/ICMP.h b/Demos/Device/LowLevel/RNDISEthernet/Lib/ICMP.h
index b43ce20f9..dfffae249 100644
--- a/Demos/Device/LowLevel/RNDISEthernet/Lib/ICMP.h
+++ b/Demos/Device/LowLevel/RNDISEthernet/Lib/ICMP.h
@@ -45,22 +45,22 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** ICMP message type constant, indicating an ICMP ECHO Reply message */
+ /** ICMP message type constant, indicating an ICMP ECHO Reply message. */
#define ICMP_TYPE_ECHOREPLY 0
- /** ICMP message type constant, indicating a packet destination is unreachable */
+ /** ICMP message type constant, indicating a packet destination is unreachable. */
#define ICMP_TYPE_DESTINATIONUNREACHABLE 3
- /** ICMP message type constant, indicating an ICMP Source Quench message */
+ /** ICMP message type constant, indicating an ICMP Source Quench message. */
#define ICMP_TYPE_SOURCEQUENCH 4
- /** ICMP message type constant, indicating an ICMP Redirect message */
+ /** ICMP message type constant, indicating an ICMP Redirect message. */
#define ICMP_TYPE_REDIRECTMESSAGE 5
- /** ICMP message type constant, indicating an ICMP ECHO Request message */
+ /** ICMP message type constant, indicating an ICMP ECHO Request message. */
#define ICMP_TYPE_ECHOREQUEST 8
- /** ICMP message type constant, indicating an ICMP Time Exceeded message */
+ /** ICMP message type constant, indicating an ICMP Time Exceeded message. */
#define ICMP_TYPE_TIMEEXCEEDED 11
/* Type Defines: */
diff --git a/Demos/Device/LowLevel/RNDISEthernet/Lib/IP.h b/Demos/Device/LowLevel/RNDISEthernet/Lib/IP.h
index 0db924a8c..b0a06b8d0 100644
--- a/Demos/Device/LowLevel/RNDISEthernet/Lib/IP.h
+++ b/Demos/Device/LowLevel/RNDISEthernet/Lib/IP.h
@@ -45,16 +45,18 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** Protocol IP address of the host (client) machine, once assigned by DHCP */
+ /** Protocol IP address of the host (client) machine, once assigned by DHCP. */
#define CLIENT_IP_ADDRESS { 10, 0, 0, 1}
- /** Protocol IP address of the virtual server machine */
+ /** Protocol IP address of the virtual server machine. */
#define SERVER_IP_ADDRESS { 10, 0, 0, 2}
- /** Protocol IP address of the broadcast address */
+ /** Protocol IP address of the broadcast address. */
#define BROADCAST_IP_ADDRESS {0xFF, 0xFF, 0xFF, 0xFF}
- /** Default Time To Live (TTL) value for sent packets, indicating the maximum allowable hops until their destination is reached */
+ /** Default Time To Live (TTL) value for sent packets, indicating the maximum allowable hops until their destination
+ * is reached.
+ */
#define DEFAULT_TTL 128
/** Performs a comparison between two IP addresses, indicating if they are identical.
diff --git a/Demos/Device/LowLevel/RNDISEthernet/Lib/RNDIS.h b/Demos/Device/LowLevel/RNDISEthernet/Lib/RNDIS.h
index f605158db..cabea97bb 100644
--- a/Demos/Device/LowLevel/RNDISEthernet/Lib/RNDIS.h
+++ b/Demos/Device/LowLevel/RNDISEthernet/Lib/RNDIS.h
@@ -45,16 +45,16 @@
#include "Ethernet.h"
/* Macros: */
- /** Implemented RNDIS Version Major */
+ /** Implemented RNDIS Version Major. */
#define REMOTE_NDIS_VERSION_MAJOR 0x01
- /** Implemented RNDIS Version Minor */
+ /** Implemented RNDIS Version Minor. */
#define REMOTE_NDIS_VERSION_MINOR 0x00
- /** RNDIS request to issue a host-to-device NDIS command */
+ /** RNDIS request to issue a host-to-device NDIS command. */
#define REQ_SendEncapsulatedCommand 0x00
- /** RNDIS request to issue a device-to-host NDIS response */
+ /** RNDIS request to issue a device-to-host NDIS response. */
#define REQ_GetEncapsulatedResponse 0x01
/* Enums: */
@@ -66,7 +66,7 @@
RNDIS_Data_Initialized = 2, /**< Adapter currently initialized and ready for data transfers */
};
- /** Enum for the NDIS hardware states */
+ /** Enum for the NDIS hardware states. */
enum NDIS_Hardware_Status_t
{
NdisHardwareStatusReady, /**< Hardware Ready to accept commands from the host */
@@ -77,14 +77,14 @@
};
/* Type Defines: */
- /** Type define for a RNDIS message header, sent before RNDIS messages */
+ /** Type define for a RNDIS message header, sent before RNDIS messages. */
typedef struct
{
uint32_t MessageType; /**< RNDIS message type, a REMOTE_NDIS_*_MSG constant */
uint32_t MessageLength; /**< Total length of the RNDIS message, in bytes */
} RNDIS_Message_Header_t;
- /** Type define for a RNDIS packet message, used to encapsulate Ethernet packets sent to and from the adapter */
+ /** Type define for a RNDIS packet message, used to encapsulate Ethernet packets sent to and from the adapter. */
typedef struct
{
uint32_t MessageType;
@@ -100,7 +100,7 @@
uint32_t Reserved;
} RNDIS_Packet_Message_t;
- /** Type define for a RNDIS Initialize command message */
+ /** Type define for a RNDIS Initialize command message. */
typedef struct
{
uint32_t MessageType;
@@ -112,7 +112,7 @@
uint32_t MaxTransferSize;
} RNDIS_Initialize_Message_t;
- /** Type define for a RNDIS Initialize complete response message */
+ /** Type define for a RNDIS Initialize complete response message. */
typedef struct
{
uint32_t MessageType;
@@ -131,7 +131,7 @@
uint32_t AFListSize;
} RNDIS_Initialize_Complete_t;
- /** Type define for a RNDIS Keepalive command message */
+ /** Type define for a RNDIS Keepalive command message. */
typedef struct
{
uint32_t MessageType;
@@ -139,7 +139,7 @@
uint32_t RequestId;
} RNDIS_KeepAlive_Message_t;
- /** Type define for a RNDIS Keepalive complete message */
+ /** Type define for a RNDIS Keepalive complete message. */
typedef struct
{
uint32_t MessageType;
@@ -148,7 +148,7 @@
uint32_t Status;
} RNDIS_KeepAlive_Complete_t;
- /** Type define for a RNDIS Reset complete message */
+ /** Type define for a RNDIS Reset complete message. */
typedef struct
{
uint32_t MessageType;
@@ -158,7 +158,7 @@
uint32_t AddressingReset;
} RNDIS_Reset_Complete_t;
- /** Type define for a RNDIS Set command message */
+ /** Type define for a RNDIS Set command message. */
typedef struct
{
uint32_t MessageType;
@@ -171,7 +171,7 @@
uint32_t DeviceVcHandle;
} RNDIS_Set_Message_t;
- /** Type define for a RNDIS Set complete response message */
+ /** Type define for a RNDIS Set complete response message. */
typedef struct
{
uint32_t MessageType;
@@ -180,7 +180,7 @@
uint32_t Status;
} RNDIS_Set_Complete_t;
- /** Type define for a RNDIS Query command message */
+ /** Type define for a RNDIS Query command message. */
typedef struct
{
uint32_t MessageType;
@@ -193,7 +193,7 @@
uint32_t DeviceVcHandle;
} RNDIS_Query_Message_t;
- /** Type define for a RNDIS Query complete response message */
+ /** Type define for a RNDIS Query complete response message. */
typedef struct
{
uint32_t MessageType;
diff --git a/Demos/Device/LowLevel/RNDISEthernet/Lib/TCP.h b/Demos/Device/LowLevel/RNDISEthernet/Lib/TCP.h
index 40b1a85e9..dcfc8407c 100644
--- a/Demos/Device/LowLevel/RNDISEthernet/Lib/TCP.h
+++ b/Demos/Device/LowLevel/RNDISEthernet/Lib/TCP.h
@@ -45,46 +45,46 @@
#include "ProtocolDecoders.h"
/* Macros: */
- /** Maximum number of TCP ports which can be open at the one time */
+ /** Maximum number of TCP ports which can be open at the one time. */
#define MAX_OPEN_TCP_PORTS 1
- /** Maximum number of TCP connections which can be sustained at the one time */
+ /** Maximum number of TCP connections which can be sustained at the one time. */
#define MAX_TCP_CONNECTIONS 3
- /** TCP window size, giving the maximum number of bytes which can be buffered at the one time */
+ /** TCP window size, giving the maximum number of bytes which can be buffered at the one time. */
#define TCP_WINDOW_SIZE 512
- /** Port number for HTTP transmissions */
+ /** Port number for HTTP transmissions. */
#define TCP_PORT_HTTP SwapEndian_16(80)
- /** Data direction indicator for a TCP application buffer, indicating data from host-to-device */
+ /** Data direction indicator for a TCP application buffer, indicating data from host-to-device. */
#define TCP_PACKETDIR_IN false
- /** Data direction indicator for a TCP application buffer, indicating data from device-to-host */
+ /** Data direction indicator for a TCP application buffer, indicating data from device-to-host. */
#define TCP_PACKETDIR_OUT true
- /** Congestion Window Reduced TCP flag mask */
+ /** Congestion Window Reduced TCP flag mask. */
#define TCP_FLAG_CWR (1 << 7)
- /** Explicit Congestion Notification TCP flag mask */
+ /** Explicit Congestion Notification TCP flag mask. */
#define TCP_FLAG_ECE (1 << 6)
- /** Urgent TCP flag mask */
+ /** Urgent TCP flag mask. */
#define TCP_FLAG_URG (1 << 5)
- /** Data Acknowledge TCP flag mask */
+ /** Data Acknowledge TCP flag mask. */
#define TCP_FLAG_ACK (1 << 4)
- /** Data Push TCP flag mask */
+ /** Data Push TCP flag mask. */
#define TCP_FLAG_PSH (1 << 3)
- /** Reset TCP flag mask */
+ /** Reset TCP flag mask. */
#define TCP_FLAG_RST (1 << 2)
- /** Synchronize TCP flag mask */
+ /** Synchronize TCP flag mask. */
#define TCP_FLAG_SYN (1 << 1)
- /** Connection Finalize TCP flag mask */
+ /** Connection Finalize TCP flag mask. */
#define TCP_FLAG_FIN (1 << 0)
/** Application macro: Determines if the given application buffer contains a packet received from the host
@@ -147,14 +147,14 @@
#define TCP_APP_CLOSECONNECTION(Connection) MACROS{ Connection->State = TCP_Connection_Closing; }MACROE
/* Enums: */
- /** Enum for possible TCP port states */
+ /** Enum for possible TCP port states. */
enum TCP_PortStates_t
{
TCP_Port_Closed = 0, /**< TCP port closed, no connections to a host may be made on this port. */
TCP_Port_Open = 1, /**< TCP port open, connections to a host may be made on this port. */
};
- /** Enum for possible TCP connection states */
+ /** Enum for possible TCP connection states. */
enum TCP_ConnectionStates_t
{
TCP_Connection_Listen = 0, /**< Listening for a connection from a host */
@@ -171,7 +171,7 @@
};
/* Type Defines: */
- /** Type define for a TCP connection buffer structure, including size, data and direction */
+ /** Type define for a TCP connection buffer structure, including size, data and direction. */
typedef struct
{
uint16_t Length; /**< Length of data in the TCP application buffer */
@@ -180,10 +180,10 @@
bool Ready; /**< If data from host, indicates buffer ready to be read, otherwise indicates
* buffer ready to be sent to the host
*/
- bool InUse; /** Indicates if the buffer is locked to to the current direction, and cannot be changed */
+ bool InUse; /**< Indicates if the buffer is locked to to the current direction, and cannot be changed */
} TCP_ConnectionBuffer_t;
- /** Type define for a TCP connection information structure */
+ /** Type define for a TCP connection information structure. */
typedef struct
{
uint32_t SequenceNumberIn; /**< Current TCP sequence number for host-to-device */
@@ -191,7 +191,7 @@
TCP_ConnectionBuffer_t Buffer; /**< Connection application data buffer */
} TCP_ConnectionInfo_t;
- /** Type define for a complete TCP connection state */
+ /** Type define for a complete TCP connection state. */
typedef struct
{
uint16_t Port; /**< Connection port number on the device */
@@ -201,7 +201,7 @@
uint8_t State; /**< Current connection state, a value from the TCP_ConnectionStates_t enum */
} TCP_ConnectionState_t;
- /** Type define for a TCP port state */
+ /** Type define for a TCP port state. */
typedef struct
{
uint16_t Port; /**< TCP port number on the device */
@@ -210,7 +210,7 @@
TCP_ConnectionBuffer_t* Buffer); /**< Port application handler */
} TCP_PortState_t;
- /** Type define for a TCP packet header */
+ /** Type define for a TCP packet header. */
typedef struct
{
uint16_t SourcePort; /**< Source port of the TCP packet */
@@ -228,9 +228,6 @@
uint16_t UrgentPointer; /**< Urgent data pointer */
} TCP_Header_t;
- /* External Variables: */
- TCP_PortState_t PortStateTable[MAX_OPEN_TCP_PORTS];
-
/* Function Prototypes: */
void TCP_Init(void);
void TCP_Task(void);
diff --git a/Demos/Device/LowLevel/RNDISEthernet/Lib/UDP.h b/Demos/Device/LowLevel/RNDISEthernet/Lib/UDP.h
index 25c33cf52..6cbc0b819 100644
--- a/Demos/Device/LowLevel/RNDISEthernet/Lib/UDP.h
+++ b/Demos/Device/LowLevel/RNDISEthernet/Lib/UDP.h
@@ -45,17 +45,17 @@
#include "DHCP.h"
/* Macros: */
- /** Source UDP port for a DHCP request */
+ /** Source UDP port for a DHCP request. */
#define UDP_PORT_DHCP_REQUEST 67
- /** Destination UDP port for a DHCP reply */
+ /** Destination UDP port for a DHCP reply. */
#define UDP_PORT_DHCP_REPLY 68
- /** Source UDP port for a DNS request/response */
+ /** Source UDP port for a DNS request/response. */
#define UDP_PORT_DNS 53
/* Type Defines: */
- /** Type define for a UDP packet header */
+ /** Type define for a UDP packet header. */
typedef struct
{
uint16_t SourcePort; /**< Packet source port */