Minor documentation improvements.

This commit is contained in:
Dean Camera 2011-01-08 11:47:20 +00:00
parent d126146887
commit 7dc3d3a68f
48 changed files with 329 additions and 324 deletions

View file

@ -107,12 +107,12 @@
/** \name ADC Result Adjustment Configuration Masks */
//@{
/** Left-adjusts the 10-bit ADC result, so that the upper 8 bits of the value returned by the
* ADC_GetResult() macro contain the 8 most significant bits of the result.
* \ref ADC_GetResult() macro contain the 8 most significant bits of the result.
*/
#define ADC_LEFT_ADJUSTED (1 << ADLAR)
/** Right-adjusts the 10-bit ADC result, so that the lower 8 bits of the value returned by the
* ADC_GetResult() macro contain the 8 least significant bits of the result.
* \ref ADC_GetResult() macro contain the 8 least significant bits of the result.
*/
#define ADC_RIGHT_ADJUSTED (0 << ADLAR)
//@}
@ -156,80 +156,80 @@
/** \name ADC MUX Masks */
//@{
/** MUX mask define for the ADC0 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading. */
/** MUX mask define for the ADC0 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading(). */
#define ADC_CHANNEL0 (0x00 << MUX0)
/** MUX mask define for the ADC1 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading. */
/** MUX mask define for the ADC1 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading(). */
#define ADC_CHANNEL1 (0x01 << MUX0)
#if !(defined(__AVR_ATmega16U4__) || defined(__AVR_ATmega32U4__) || defined(__DOXYGEN__))
/** MUX mask define for the ADC2 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading.
/** MUX mask define for the ADC2 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading().
*
* \note Not available on all AVR models.
*/
#define ADC_CHANNEL2 (0x02 << MUX0)
/** MUX mask define for the ADC3 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading.
/** MUX mask define for the ADC3 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading().
*
* \note Not available on all AVR models.
*/
#define ADC_CHANNEL3 (0x03 << MUX0)
#endif
/** MUX mask define for the ADC4 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading. */
/** MUX mask define for the ADC4 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading(). */
#define ADC_CHANNEL4 (0x04 << MUX0)
/** MUX mask define for the ADC5 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading. */
/** MUX mask define for the ADC5 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading(). */
#define ADC_CHANNEL5 (0x05 << MUX0)
/** MUX mask define for the ADC6 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading. */
/** MUX mask define for the ADC6 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading(). */
#define ADC_CHANNEL6 (0x06 << MUX0)
/** MUX mask define for the ADC7 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading. */
#define ADC_CHANNEL7 (0x07 << MUX0)
/** MUX mask define for the internal 1.1V bandgap channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading. */
/** MUX mask define for the internal 1.1V bandgap channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading(). */
#define ADC_1100MV_BANDGAP (0x1E << MUX0)
#if (defined(__AVR_ATmega16U4__) || defined(__AVR_ATmega32U4__) || defined(__DOXYGEN__))
/** MUX mask define for the ADC8 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading.
/** MUX mask define for the ADC8 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading().
*
* \note Not available on all AVR models.
*/
#define ADC_CHANNEL8 ((1 << 8) | (0x00 << MUX0))
/** MUX mask define for the ADC9 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading.
/** MUX mask define for the ADC9 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading().
*
* \note Not available on all AVR models.
*/
#define ADC_CHANNEL9 ((1 << 8) | (0x01 << MUX0))
/** MUX mask define for the ADC10 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading.
/** MUX mask define for the ADC10 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading().
*
* \note Not available on all AVR models.
*/
#define ADC_CHANNEL10 ((1 << 8) | (0x02 << MUX0))
/** MUX mask define for the ADC11 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading.
/** MUX mask define for the ADC11 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading().
*
* \note Not available on all AVR models.
*/
#define ADC_CHANNEL11 ((1 << 8) | (0x03 << MUX0))
/** MUX mask define for the ADC12 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading.
/** MUX mask define for the ADC12 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading().
*
* \note Not available on all AVR models.
*/
#define ADC_CHANNEL12 ((1 << 8) | (0x04 << MUX0))
/** MUX mask define for the ADC13 channel of the ADC. See \ref ADC_StartReading and \ref ADC_GetChannelReading.
/** MUX mask define for the ADC13 channel of the ADC. See \ref ADC_StartReading() and \ref ADC_GetChannelReading().
*
* \note Not available on all AVR models.
*/
#define ADC_CHANNEL13 ((1 << 8) | (0x05 << MUX0))
/** MUX mask define for the internal temperature sensor channel of the ADC. See \ref ADC_StartReading and
* \ref ADC_GetChannelReading.
/** MUX mask define for the internal temperature sensor channel of the ADC. See \ref ADC_StartReading() and
* \ref ADC_GetChannelReading().
*
* \note Not available on all AVR models.
*/
@ -246,7 +246,7 @@
* pin of the AVR, denoted by its special alternative function ADCx.
* \n\n
*
* \note The channel number must be specified as an integer, and NOT a ADC_CHANNELx mask.
* \note The channel number must be specified as an integer, and <b>not</b> a \c ADC_CHANNEL* mask.
*
* \param[in] ChannelIndex ADC channel number to set up for conversions.
*/
@ -289,7 +289,7 @@
* pin of the AVR, denoted by its special alternative function ADCx.
* \n\n
*
* \note The channel number must be specified as an integer, and NOT a ADC_CHANNELx mask.
* \note The channel number must be specified as an integer, and <b>not</b> a \c ADC_CHANNEL* mask.
*
* \param[in] ChannelIndex ADC channel number to set up for conversions.
*/
@ -413,7 +413,7 @@
/** Indicates if the ADC is currently enabled.
*
* \return Boolean true if the ADC subsystem is currently enabled, false otherwise.
* \return Boolean \c true if the ADC subsystem is currently enabled, \c false otherwise.
*/
static inline bool ADC_GetStatus(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
static inline bool ADC_GetStatus(void)

View file

@ -145,7 +145,7 @@
*
* \param[in] Byte Byte to send to the currently addressed device
*
* \return Boolean true if the recipient ACKed the byte, false otherwise
* \return Boolean \c true if the recipient ACKed the byte, \c false otherwise
*/
static inline bool TWI_SendByte(const uint8_t Byte)
{
@ -161,7 +161,7 @@
* \param[in] Byte Location where the read byte is to be stored
* \param[in] LastByte Indicates if the byte should be ACKed if false, NAKed if true
*
* \return Boolean true if the byte reception successfully completed, false otherwise
* \return Boolean \c true if the byte reception successfully completed, \c false otherwise
*/
static inline bool TWI_ReceiveByte(uint8_t* const Byte,
const bool LastByte)
@ -184,7 +184,7 @@
* \param[in] SlaveAddress Address of the slave TWI device to communicate with
* \param[in] TimeoutMS Timeout period within which the slave must respond, in milliseconds
*
* \return Boolean true if the device is ready for data, false otherwise
* \return Boolean \c true if the device is ready for data, \c false otherwise
*/
bool TWI_StartTransmission(const uint8_t SlaveAddress,
const uint8_t TimeoutMS);

View file

@ -92,61 +92,61 @@
/* Macros: */
/** \name SPI Prescaler Configuration Masks */
//@{
/** SPI prescaler mask for SPI_Init(). Divides the system clock by a factor of 2. */
/** SPI prescaler mask for \c SPI_Init(). Divides the system clock by a factor of 2. */
#define SPI_SPEED_FCPU_DIV_2 SPI_USE_DOUBLESPEED
/** SPI prescaler mask for SPI_Init(). Divides the system clock by a factor of 4. */
/** SPI prescaler mask for \c SPI_Init(). Divides the system clock by a factor of 4. */
#define SPI_SPEED_FCPU_DIV_4 0
/** SPI prescaler mask for SPI_Init(). Divides the system clock by a factor of 8. */
/** SPI prescaler mask for \c SPI_Init(). Divides the system clock by a factor of 8. */
#define SPI_SPEED_FCPU_DIV_8 (SPI_USE_DOUBLESPEED | (1 << SPR0))
/** SPI prescaler mask for SPI_Init(). Divides the system clock by a factor of 16. */
/** SPI prescaler mask for \c SPI_Init(). Divides the system clock by a factor of 16. */
#define SPI_SPEED_FCPU_DIV_16 (1 << SPR0)
/** SPI prescaler mask for SPI_Init(). Divides the system clock by a factor of 32. */
/** SPI prescaler mask for \c SPI_Init(). Divides the system clock by a factor of 32. */
#define SPI_SPEED_FCPU_DIV_32 (SPI_USE_DOUBLESPEED | (1 << SPR1))
/** SPI prescaler mask for SPI_Init(). Divides the system clock by a factor of 64. */
/** SPI prescaler mask for \c SPI_Init(). Divides the system clock by a factor of 64. */
#define SPI_SPEED_FCPU_DIV_64 (SPI_USE_DOUBLESPEED | (1 << SPR1) | (1 << SPR0))
/** SPI prescaler mask for SPI_Init(). Divides the system clock by a factor of 128. */
/** SPI prescaler mask for \c SPI_Init(). Divides the system clock by a factor of 128. */
#define SPI_SPEED_FCPU_DIV_128 ((1 << SPR1) | (1 << SPR0))
//@}
/** \name SPI SCK Polarity Configuration Masks */
//@{
/** SPI clock polarity mask for SPI_Init(). Indicates that the SCK should lead on the rising edge. */
/** SPI clock polarity mask for \c SPI_Init(). Indicates that the SCK should lead on the rising edge. */
#define SPI_SCK_LEAD_RISING (0 << CPOL)
/** SPI clock polarity mask for SPI_Init(). Indicates that the SCK should lead on the falling edge. */
/** SPI clock polarity mask for \c SPI_Init(). Indicates that the SCK should lead on the falling edge. */
#define SPI_SCK_LEAD_FALLING (1 << CPOL)
//@}
/** \name SPI Sample Edge Configuration Masks */
//@{
/** SPI data sample mode mask for SPI_Init(). Indicates that the data should sampled on the leading edge. */
/** SPI data sample mode mask for \c SPI_Init(). Indicates that the data should sampled on the leading edge. */
#define SPI_SAMPLE_LEADING (0 << CPHA)
/** SPI data sample mode mask for SPI_Init(). Indicates that the data should be sampled on the trailing edge. */
/** SPI data sample mode mask for \c SPI_Init(). Indicates that the data should be sampled on the trailing edge. */
#define SPI_SAMPLE_TRAILING (1 << CPHA)
//@}
/** \name SPI Data Ordering Configuration Masks */
//@{
/** SPI data order mask for SPI_Init(). Indicates that data should be shifted out MSB first. */
/** SPI data order mask for \c SPI_Init(). Indicates that data should be shifted out MSB first. */
#define SPI_ORDER_MSB_FIRST (0 << DORD)
/** SPI data order mask for SPI_Init(). Indicates that data should be shifted out MSB first. */
/** SPI data order mask for \c SPI_Init(). Indicates that data should be shifted out MSB first. */
#define SPI_ORDER_LSB_FIRST (1 << DORD)
//@}
/** \name SPI Mode Configuration Masks */
//@{
/** SPI mode mask for SPI_Init(). Indicates that the SPI interface should be initialized into slave mode. */
/** SPI mode mask for \c SPI_Init(). Indicates that the SPI interface should be initialized into slave mode. */
#define SPI_MODE_SLAVE (0 << MSTR)
/** SPI mode mask for SPI_Init(). Indicates that the SPI interface should be initialized into master mode. */
/** SPI mode mask for \c SPI_Init(). Indicates that the SPI interface should be initialized into master mode. */
#define SPI_MODE_MASTER (1 << MSTR)
//@}
@ -154,8 +154,8 @@
/** Initialises the SPI subsystem, ready for transfers. Must be called before calling any other
* SPI routines.
*
* \param[in] SPIOptions SPI Options, a mask consisting of one of each of the SPI_SPEED_*,
* SPI_SCK_*, SPI_SAMPLE_*, SPI_ORDER_* and SPI_MODE_* masks.
* \param[in] SPIOptions SPI Options, a mask consisting of one of each of the \c SPI_SPEED_*,
* \c SPI_SCK_*, \c SPI_SAMPLE_*, \c SPI_ORDER_* and \c SPI_MODE_* masks.
*/
static inline void SPI_Init(const uint8_t SPIOptions)
{

View file

@ -139,7 +139,7 @@
/** Indicates whether a character has been received through the USART.
*
* \return Boolean true if a character has been received, false otherwise.
* \return Boolean \c true if a character has been received, \c false otherwise.
*/
static inline bool Serial_IsCharReceived(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
static inline bool Serial_IsCharReceived(void)

View file

@ -32,8 +32,8 @@
* \brief Standard avr-libc character stream driver for the USART.
*
* Serial stream driver for the USART subsystem on supported USB AVRs. This makes use of the functions in the
* regular USART driver (see \ref Group_Serial), but allows the avr-libc standard stream functions (printf,
* puts, etc.) to work with the
* regular USART driver (see \ref Group_Serial), but allows the avr-libc standard stream functions (\c printf,
* \c puts, etc.) to work with the
* USART.
*/
@ -46,9 +46,9 @@
*
* \section Sec_ModDescription Module Description
* Serial stream driver for the USART subsystem on supported USB AVRs. This makes use of the functions in the
* regular USART driver (see \ref Group_Serial), but allows the avr-libc standard stream functions (printf,
* puts, etc.) to work with the USART. Upon configuration, this will redirect the standard input and output
* streams to the USART.
* regular USART driver (see \ref Group_Serial), but allows the avr-libc standard stream functions (\c printf,
* \c puts, etc.) to work with the USART. Upon configuration, this will redirect the \c stdin standard input
* and \c stdout output streams to the USART.
*
* \section Sec_ExampleUsage Example Usage
* The following snippet is an example of how this module may be used within a typical