X-Git-Url: http://git.linex4red.de/pub/lufa.git/blobdiff_plain/cb779e3d7d32d7c43e0a45bb526de0a04135b0c7..64fe1cd0b2be01fd7b377736a85c1bd88a5fd429:/LUFA/Drivers/Peripheral/Serial.h diff --git a/LUFA/Drivers/Peripheral/Serial.h b/LUFA/Drivers/Peripheral/Serial.h index 2fca02b96..549448d92 100644 --- a/LUFA/Drivers/Peripheral/Serial.h +++ b/LUFA/Drivers/Peripheral/Serial.h @@ -41,10 +41,25 @@ * The following files must be built with any user project that uses this module: * - LUFA/Drivers/Peripheral/Serial.c (Makefile source module name: LUFA_SRC_SERIAL) * - * \section Module Description + * \section Sec_ModDescription Module Description * Hardware serial USART driver. This module provides an easy to use driver for * the setup of and transfer of data over the AVR's USART port. * + * \section Sec_ExampleUsage Example Usage + * The following snippet is an example of how this module may be used within a typical + * application. + * + * \code + * // Initialise the serial USART driver before first use, with 9600 baud (and no double-speed mode) + * Serial_Init(9600, false); + * + * // Send a string through the USART + * Serial_TxString("Test String\r\n"); + * + * // Receive a byte through the USART + * uint8_t DataByte = Serial_RxByte(); + * \endcode + * * @{ */