Browse Source

lm4f: Add doxygen documentation for the USB driver

Add minimal documentation for the USB driver. The internal functions and
structs are excluded.

Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com>
pull/149/head
Alexandru Gagniuc 12 years ago
parent
commit
ad048f7d5a
  1. 19
      include/libopencm3/lm4f/usb.h
  2. 35
      lib/lm4f/usb_lm4f.c

19
include/libopencm3/lm4f/usb.h

@ -17,9 +17,27 @@
* along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
/** @defgroup usb_defines USB Controller
*
* @brief <b>Defined Constants and Types for the LM4F USB Controller</b>
*
* @ingroup LM4Fxx_defines
*
* @version 1.0.0
*
* @author @htmlonly &copy; @endhtmlonly 2013 Alexandru Gagniuc <mr.nuke.me@gmail.com>
*
* @date 15 May 2013
*
* LGPL License Terms @ref lgpl_license
*/
#ifndef LIBOPENCM3_LM4F_USB_H
#define LIBOPENCM3_LM4F_USB_H
/**@{*/
#include <libopencm3/lm4f/memorymap.h>
#include <libopencm3/cm3/common.h>
@ -364,5 +382,6 @@
/** Controller type */
#define USB_PP_TYPE_MASK (0x0F << 0)
/**@}*/
#endif /* LIBOPENCM3_LM4F_USB_H */

35
lib/lm4f/usb_lm4f.c

@ -17,6 +17,32 @@
* along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* @defgroup usb_file USB
*
* @ingroup LM4Fxx
*
* @author @htmlonly &copy; @endhtmlonly 2013 Alexandru Gagniuc <mr.nuke.me@gmail.com>
*
* \brief <b>libopencm3 LM4F Universal Serial Bus controller </b>
*
* The LM4F USB driver is integrated with the libopencm3 USB stack. You should
* use the generic stack.
*
* To use this driver, tell the linker to look for it:
* @code{.c}
* extern usbd_driver lm4f_usb_driver;
* @endcode
*
* And pass this driver as an argument when initializing the USB stack:
* @code{.c}
* usbd_device *usbd_dev;
* usbd_dev = usbd_init(&lm4f_usb_driver, ...);
* @endcode
*
* @{
*/
/*
* TODO list:
*
@ -44,6 +70,9 @@
const struct _usbd_driver lm4f_usb_driver;
/**
* @cond private
*/
static inline void lm4f_usb_soft_disconnect(void)
{
USB_POWER &= ~USB_POWER_SOFTCONN;
@ -476,4 +505,10 @@ const struct _usbd_driver lm4f_usb_driver = {
.set_address_before_status = false,
.rx_fifo_size = RX_FIFO_SIZE,
};
/**
* @endcond
*/
/**
* @}
*/

Loading…
Cancel
Save