rtdevice.h 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165
  1. /*****************************************************************************
  2. * Copyright (c) 2019, Nations Technologies Inc.
  3. *
  4. * All rights reserved.
  5. * ****************************************************************************
  6. *
  7. * Redistribution and use in source and binary forms, with or without
  8. * modification, are permitted provided that the following conditions are met:
  9. *
  10. * - Redistributions of source code must retain the above copyright notice,
  11. * this list of conditions and the disclaimer below.
  12. *
  13. * Nations' name may not be used to endorse or promote products derived from
  14. * this software without specific prior written permission.
  15. *
  16. * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY NATIONS "AS IS" AND ANY EXPRESS OR
  17. * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  18. * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE
  19. * DISCLAIMED. IN NO EVENT SHALL NATIONS BE LIABLE FOR ANY DIRECT, INDIRECT,
  20. * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  21. * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
  22. * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
  23. * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
  24. * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  25. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  26. * ****************************************************************************/
  27. /**
  28. * @file rtdevice.h
  29. * @author Nations
  30. * @version v1.0.0
  31. *
  32. * @copyright Copyright (c) 2019, Nations Technologies Inc. All rights reserved.
  33. */
  34. #ifndef __RT_DEVICE_H__
  35. #define __RT_DEVICE_H__
  36. #include <rtthread.h>
  37. //#include "ipc/ringbuffer.h"
  38. //#include "ipc/completion.h"
  39. //#include "ipc/dataqueue.h"
  40. //#include "ipc/workqueue.h"
  41. //#include "ipc/waitqueue.h"
  42. //#include "ipc/pipe.h"
  43. //#include "ipc/poll.h"
  44. //#include "ipc/ringblk_buf.h"
  45. #ifdef __cplusplus
  46. extern "C" {
  47. #endif
  48. #define RT_DEVICE(device) ((rt_device_t)device)
  49. #ifdef RT_USING_RTC
  50. #include "rtc.h"
  51. #ifdef RT_USING_ALARM
  52. #include "alarm.h"
  53. #endif
  54. #endif /* RT_USING_RTC */
  55. #ifdef RT_USING_SPI
  56. #include "spi.h"
  57. #endif /* RT_USING_SPI */
  58. #ifdef RT_USING_MTD_NOR
  59. #include "mtd_nor.h"
  60. #endif /* RT_USING_MTD_NOR */
  61. #ifdef RT_USING_MTD_NAND
  62. #include "mtd_nand.h"
  63. #endif /* RT_USING_MTD_NAND */
  64. #ifdef RT_USING_USB_DEVICE
  65. #include "usb_device.h"
  66. #endif /* RT_USING_USB_DEVICE */
  67. #ifdef RT_USING_USB_HOST
  68. #include "usb_host.h"
  69. #endif /* RT_USING_USB_HOST */
  70. #ifdef RT_USING_SERIAL
  71. #include "serial.h"
  72. #endif /* RT_USING_SERIAL */
  73. #ifdef RT_USING_I2C
  74. #include "i2c.h"
  75. #include "i2c_dev.h"
  76. #ifdef RT_USING_I2C_BITOPS
  77. #include "i2c-bit-ops.h"
  78. #endif /* RT_USING_I2C_BITOPS */
  79. #endif /* RT_USING_I2C */
  80. #ifdef RT_USING_SDIO
  81. #include "mmcsd_core.h"
  82. #include "sd.h"
  83. #include "sdio.h"
  84. #endif
  85. #ifdef RT_USING_WDT
  86. #include "watchdog.h"
  87. #endif
  88. #ifdef RT_USING_PIN
  89. #include "pin.h"
  90. #endif
  91. #ifdef RT_USING_CAN
  92. #include "can.h"
  93. #endif
  94. #ifdef RT_USING_HWTIMER
  95. #include "hwtimer.h"
  96. #endif
  97. #ifdef RT_USING_AUDIO
  98. #include "audio.h"
  99. #endif
  100. #ifdef RT_USING_CPUTIME
  101. #include "cputime.h"
  102. #endif
  103. #ifdef RT_USING_ADC
  104. #include "adc.h"
  105. #endif
  106. #ifdef RT_USING_PWM
  107. #include "rt_drv_pwm.h"
  108. #endif
  109. #ifdef RT_USING_PM
  110. #include "pm.h"
  111. #endif
  112. #ifdef RT_USING_WIFI
  113. #include "wlan.h"
  114. #endif
  115. #ifdef MTD_USING_NOR
  116. #include "mtdnor.h"
  117. #endif
  118. #ifdef MTD_USING_NAND
  119. #include "mtdnand.h"
  120. #endif
  121. #ifdef RT_USING_HWCRYPTO
  122. #include "crypto.h"
  123. #endif
  124. #ifdef RT_USING_PULSE_ENCODER
  125. #include "pulse_encoder.h"
  126. #endif
  127. #ifdef RT_USING_INPUT_CAPTURE
  128. #include "rt_inputcapture.h"
  129. #endif
  130. #ifdef __cplusplus
  131. }
  132. #endif
  133. #endif /* __RT_DEVICE_H__ */