Keyboard firmwares for Atmel AVR and Cortex-M
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. /*
  2. LUFA Library
  3. Copyright (C) Dean Camera, 2014.
  4. dean [at] fourwalledcubicle [dot] com
  5. www.lufa-lib.org
  6. */
  7. /*
  8. Copyright 2014 Dean Camera (dean [at] fourwalledcubicle [dot] com)
  9. Permission to use, copy, modify, distribute, and sell this
  10. software and its documentation for any purpose is hereby granted
  11. without fee, provided that the above copyright notice appear in
  12. all copies and that both that the copyright notice and this
  13. permission notice and warranty disclaimer appear in supporting
  14. documentation, and that the name of the author not be used in
  15. advertising or publicity pertaining to distribution of the
  16. software without specific, written prior permission.
  17. The author disclaims all warranties with regard to this
  18. software, including all implied warranties of merchantability
  19. and fitness. In no event shall the author be liable for any
  20. special, indirect or consequential damages or any damages
  21. whatsoever resulting from loss of use, data or profits, whether
  22. in an action of contract, negligence or other tortious action,
  23. arising out of or in connection with the use or performance of
  24. this software.
  25. */
  26. /** \file
  27. * \brief Hardware Serial USART driver.
  28. *
  29. * This file is the master dispatch header file for the device-specific USART driver, for microcontrollers
  30. * containing a hardware USART.
  31. *
  32. * User code should include this file, which will in turn include the correct ADC driver header file for the
  33. * currently selected architecture and microcontroller model.
  34. */
  35. /** \ingroup Group_PeripheralDrivers
  36. * \defgroup Group_Serial Serial USART Driver - LUFA/Drivers/Peripheral/Serial.h
  37. * \brief Hardware Serial USART driver.
  38. *
  39. * \section Sec_Serial_Dependencies Module Source Dependencies
  40. * The following files must be built with any user project that uses this module:
  41. * - LUFA/Drivers/Peripheral/<i>ARCH</i>/Serial_<i>ARCH</i>.c <i>(Makefile source module name: LUFA_SRC_SERIAL)</i>
  42. *
  43. * \section Sec_Serial_ModDescription Module Description
  44. * Hardware serial USART driver. This module provides an easy to use driver for the setup and transfer
  45. * of data over the selected architecture and microcontroller model's USART port.
  46. *
  47. * \note The exact API for this driver may vary depending on the target used - see
  48. * individual target module documentation for the API specific to your target processor.
  49. */
  50. #ifndef __SERIAL_H__
  51. #define __SERIAL_H__
  52. /* Macros: */
  53. #define __INCLUDE_FROM_SERIAL_H
  54. /* Includes: */
  55. #include "../../Common/Common.h"
  56. /* Includes: */
  57. #if (ARCH == ARCH_AVR8)
  58. #include "AVR8/Serial_AVR8.h"
  59. #elif (ARCH == ARCH_XMEGA)
  60. #include "XMEGA/Serial_XMEGA.h"
  61. #else
  62. #error The Serial peripheral driver is not currently available for your selected architecture.
  63. #endif
  64. #endif