README.txt 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191
  1. README
  2. ^^^^^^
  3. This directory contains various device drivers -- both block and
  4. character drivers as well as other more specialized drivers.
  5. Contents:
  6. - Files in this directory
  7. - Subdirectories of this directory
  8. - Skeleton files
  9. Files in this directory
  10. ^^^^^^^^^^^^^^^^^^^^^^^
  11. dev_null.c and dev_zero.c
  12. These files provide the standard /dev/null and /dev/zero devices. See
  13. include/nuttx/drivers/driers.h for prototypes of functions that should
  14. be called if you want to register these devices (devnull_register()
  15. and devzero_register()).
  16. ramdisk.c
  17. Can be used to set up a block of memory or (read-only) FLASH as
  18. a block driver that can be mounted as a file system. See
  19. include/nuttx/drivers/ramdisk.h.
  20. rwbuffer.c
  21. A facility that can be used by any block driver in-order to add
  22. writing buffering and read-ahead buffering.
  23. Subdirectories of this directory:
  24. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  25. analog/
  26. This directory holds implementations of analog device drivers.
  27. This includes drivers for Analog to Digital Conversion (ADC) as
  28. well as drivers for Digital to Analog Conversion (DAC).
  29. See include/nuttx/analog/*.h for registration information.
  30. audio/
  31. Audio device drivers. See include/nuttx/audio/audio.h for interface
  32. definitions. See also the audio subsystem at nuttx/audio/.
  33. bch/
  34. Contains logic that may be used to convert a block driver into
  35. a character driver. This is the complementary conversion as that
  36. performed by loop.c. See include/nuttx/fs/fs.h for registration
  37. information.
  38. can/
  39. This is the CAN drivers and logic support. See include/nuttx/can/can.h
  40. for usage information.
  41. contactless/
  42. Contactless devices are related to wireless devices. They are not
  43. communication devices with other similar peers, but couplers/interfaces
  44. to contactless cards and tags.
  45. crypto/
  46. Contains crypto drivers and support logic, including the /dev/urandom
  47. device.
  48. eeprom/
  49. An EEPROM is a form of Memory Technology Device (see drivers/mtd).
  50. EEPROMs are non-volatile memory like FLASH, but differ in underlying
  51. memory technology and differ in usage in many respects: They may not
  52. be organized into blocks (at least from the standpoint of the user)
  53. and it is not necessary to erase the EEPROM memory before re-writing
  54. it. In addition, EEPROMs tend to be much smaller than FLASH parts,
  55. usually only a few kilobytes vs megabytes for FLASH. EEPROM tends to
  56. be used to retain a small amount of device configuration information;
  57. FLASH tends to be used for program or massive data storage. For these
  58. reasons, it may not be convenient to use the more complex MTD
  59. interface but instead use the simple character interface provided by
  60. the EEPROM drivers.
  61. i2c/
  62. I2C drivers and support logic. See include/nuttx/i2c/i2c_master.h
  63. i2s/
  64. I2S drivers and support logic. See include/nuttx/audio/i2s.h
  65. input/
  66. This directory holds implementations of human input device (HID)
  67. drivers. This includes such things as mouse, touchscreen, joystick,
  68. keyboard and keypad drivers. See include/nuttx/input/*.h for
  69. registration information.
  70. Note that USB HID devices are treated differently. These can be
  71. found under usbdev/ or usbhost/.
  72. lcd/
  73. Drivers for parallel and serial LCD and OLED type devices. These
  74. drivers support interfaces as defined in include/nuttx/lcd/lcd.h
  75. leds/
  76. Various LED-related drivers including discrete as well as PWM-
  77. driven LEDs.
  78. loop/
  79. Supports the standard loop device that can be used to export a
  80. file (or character device) as a block device. See losetup() and
  81. loteardown() in include/nuttx/fs/fs.h.
  82. mmcsd/
  83. Support for MMC/SD block drivers. MMC/SD block drivers based on
  84. SPI and SDIO/MCI interfaces are supported. See include/nuttx/mmcsd.h
  85. and include/nuttx/sdio.h for further information.
  86. mtd/
  87. Memory Technology Device (MTD) drivers. Some simple drivers for
  88. memory technologies like FLASH, EEPROM, NVRAM, etc. See
  89. include/nuttx/mtd/mtd.h
  90. (Note: This is a simple memory interface and should not be
  91. confused with the "real" MTD developed at infradead.org. This
  92. logic is unrelated; I just used the name MTD because I am not
  93. aware of any other common way to refer to this class of devices).
  94. net/
  95. Network interface drivers. See also include/nuttx/net/net.h
  96. pipes/
  97. FIFO and named pipe drivers. Standard interfaces are declared
  98. in include/unistd.h
  99. power/
  100. Power management (PM) driver interfaces. These interfaces are used
  101. to manage power usage of a platform by monitoring driver activity
  102. and by placing drivers into reduce power usage modes when the
  103. drivers are not active.
  104. pwm/
  105. Provides the "upper half" of a pulse width modulation (PWM) driver.
  106. The "lower half" of the PWM driver is provided by device-specific
  107. logic. See include/nuttx/timers/pwm.h for usage information.
  108. sensors/
  109. Drivers for various sensors. A sensor driver differs little from
  110. other types of drivers other than they are use to provide measurements
  111. of things in environment like temperature, orientation, acceleration,
  112. altitude, direction, position, etc.
  113. DACs might fit this definition of a sensor driver as well since they
  114. measure and convert voltage levels. DACs, however, are retained in
  115. the analog/ sub-directory.
  116. serial/
  117. Front-end character drivers for chip-specific UARTs. This provide
  118. some TTY-like functionality and are commonly used (but not required for)
  119. the NuttX system console. See also include/nuttx/serial/serial.h
  120. spi/
  121. SPI drivers and support logic. See include/nuttx/spi/spi.h
  122. syslog/
  123. System logging devices. See include/syslog.h and include/nuttx/syslog/syslog.h
  124. timers/
  125. Includes support for various timer devices including:
  126. - An "upper half" for a generic timer driver. See
  127. include/nuttx/timers/timer.h for more information.
  128. - An "upper half" for a generic watchdog driver. See
  129. include/nuttx/timers/watchdog.h for more information.
  130. - RTC drivers
  131. usbdev/
  132. USB device drivers. See also include/nuttx/usb/usbdev.h
  133. usbhost/
  134. USB host drivers. See also include/nuttx/usb/usbhost.h
  135. video/
  136. Video-related drivers. See include/nuttx/video/.
  137. wireless/
  138. Drivers for various wireless devices.
  139. Skeleton Files
  140. ^^^^^^^^^^^^^^
  141. Skeleton files are "empty" frameworks for NuttX drivers. They are provided to
  142. give you a good starting point if you want to create a new NuttX driver.
  143. The following skeleton files are available:
  144. drivers/lcd/skeleton.c -- Skeleton LCD driver
  145. drivers/mtd/skeleton.c -- Skeleton memory technology device drivers
  146. drivers/net/skeleton.c -- Skeleton network/Ethernet drivers
  147. drivers/usbhost/usbhost_skeleton.c -- Skeleton USB host class driver