Kconfig 6.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199
  1. #
  2. # For a description of the syntax of this configuration file,
  3. # see the file kconfig-language.txt in the NuttX tools repository.
  4. #
  5. menuconfig WIRELESS_IEEE802154
  6. bool "IEEE 802.15.4 Support"
  7. default n
  8. select MM_IOB
  9. depends on WIRELESS
  10. ---help---
  11. Enables a Media Access Controller for any IEEE802.15.4 radio
  12. device. This in turn can be used by higher layer entities
  13. such as 6lowpan.
  14. if WIRELESS_IEEE802154
  15. config IEEE802154_PRIMITIVE_PREALLOC
  16. int "Number of pre-allocated primitive structures"
  17. default 20
  18. ---help---
  19. This specifies the total number of preallocated primitive structures.
  20. A primitive is an abstracted data type that provides service information
  21. between the MAC layer and the next highest layer. These may be allocated
  22. from either from tasking logic or from interrupt level logic.
  23. config IEEE802154_PRIMITIVE_IRQRESERVE
  24. int "Reserved pre-allocated primitive structures"
  25. default 0
  26. depends on EXPERIMENTAL
  27. ---help---
  28. If primitives can be allocated from interrupt handlers, then this
  29. specifies the number of pre-allocated meta-data structures that are
  30. reserved for for use only by interrupt handlers. This may be zero to
  31. reserve no meta-data structures for interrupt handlers. In that case,
  32. the allocation will fail if tasking logic has allocated them all.
  33. Interrupt logic will first attempt to allocate from the general,
  34. pre-allocated structure pool that will contain up to (size
  35. CONFIG_IEEE802154_PRIMITIVE_PREALLOC - CONFIG_IEEE802154_PRIMITIVE_IRQRESERVE)
  36. entries. If that fails, then it will try to take a structure from
  37. the reserve (size CONFIG_IEEE802154_PRIMITIVE_IRQRESERVE).
  38. Non-interrupt logic will also first attempt to allocate from the
  39. general, pre-allocated structure pool. If that fails, it will
  40. dynamically allocate the primitive with an additional cost in performance.
  41. NOTE: Currently marked as experimental and with a default of zero
  42. because there are no interrupt level allocations performed by the
  43. current IEEE 802.15.4 MAC code.
  44. config IEEE802154_MAC
  45. bool "Software MAC layer"
  46. default n
  47. ---help---
  48. There are two types of IEEE 802.15.4 radios supported. Those that provide
  49. all MAC functionality equivalent to the MAC802154 software implementation,
  50. and radios that provide a lower half to the MAC802154 software layer.
  51. This option enables the software MAC layer that can interface with
  52. the lower-half radio drivers.
  53. if IEEE802154_MAC
  54. config MAC802154_NTXDESC
  55. int "Number or TX descriptors"
  56. default 5
  57. ---help---
  58. Configured number of Tx descriptors. Default: 3
  59. When used with 6LoWPAN, the descriptor allocator runs on a work
  60. and must avoid blocking if possible. Each frame will be provided in
  61. an IOB and each TX frame will need a TX descriptor. So the safe
  62. thing to do is set CONFIG_MAC802154_NTXDESC to CONFIG_IOB_NBUFFERS.
  63. Then there should be the maximum pre-allocated buffers for each
  64. possible TX frame.
  65. config MAC802154_NPANDESC
  66. int "Number of PAN descriptors"
  67. default 5
  68. ---help---
  69. Configured number of PAN descriptors Default: 5
  70. When performing a scan to find a suitable PAN, the MAC must store
  71. information for all unique beacons received. This is the number of unique
  72. descriptors that can be held before the scan cancels with LIMIT_REACHED.
  73. config MAC802154_SFEVENT_VERBOSE
  74. bool "Verbose logging related to superframe events"
  75. default n
  76. depends on DEBUG_WIRELESS_INFO
  77. ---help---
  78. Enable verbose logging of superframe events Default: false
  79. config MAC802154_LOCK_VERBOSE
  80. bool "Verbose logging related to MAC lock management"
  81. default n
  82. depends on DEBUG_WIRELESS_INFO
  83. ---help---
  84. Enable verbose logging of MAC lock management. Default: false
  85. config IEEE802154_MACDEV
  86. bool "Character driver for IEEE 802.15.4 MAC layer"
  87. default n
  88. depends on WIRELESS_IEEE802154
  89. ---help---
  90. Enable the device driver to expose the IEEE 802.15.4 MAC layer
  91. access to user space as IOCTLs
  92. if IEEE802154_MACDEV
  93. config IEEE802154_MACDEV_RECVRPRIO
  94. int "Priority of frame receiver registerd with the MAC layer"
  95. default 0
  96. ---help---
  97. When the MAC layer receives an incoming data frame, it passes the frame
  98. to registered receivers, in order of receiver priority, until one of the
  99. receivers claim the frame.
  100. An example case would be when 6LoWPAN and the MAC character driver are
  101. enabled. Both have receivers registered with the MAC. The 6LoWPAN layer
  102. should get assigned a higher priority than the character driver. In this
  103. case, the 6LoWPAN receiver will receive the frame first. If the frame is
  104. a 6LoWPAN frame, it will claim the frame and the MAC will not pass the
  105. frame to any additional receivers. If it does not claim the frame, the
  106. MAC layer will call the next highest priority receiver, in this case,
  107. the MAC character driver (which should always be lowest priority since
  108. it is a "catch-all" type receiver).
  109. endif # IEEE802154_MACDEV
  110. config IEEE802154_NETDEV
  111. bool "IEEE802154 6LoWPAN Network Device"
  112. default n
  113. depends on NET_6LOWPAN || NET_IEEE802154
  114. select ARCH_HAVE_NETDEV_STATISTICS
  115. ---help---
  116. Add support for the IEEE802.15.4 6LoWPAN network device built on
  117. the common IEEE802.15.4 MAC.
  118. if IEEE802154_NETDEV
  119. config IEEE802154_NETDEV_RECVRPRIO
  120. int "Priority of frame receiver registerd with the MAC layer"
  121. default 1
  122. ---help---
  123. When the MAC layer receives an incoming data frame, it passes the frame
  124. to registered receivers, in order of receiver priority, until one of the
  125. receivers claim the frame.
  126. An example case would be when 6LoWPAN and the MAC character driver are
  127. enabled. Both have receivers registered with the MAC. The 6LoWPAN layer
  128. should get assigned a higher priority than the character driver. In this
  129. case, the 6LoWPAN receiver will receive the frame first. If the frame is
  130. a 6LoWPAN frame, it will claim the frame and the MAC will not pass the
  131. frame to any additional receivers. If it does not claim the frame, the
  132. MAC layer will call the next highest priority receiver, in this case,
  133. the MAC character driver (which should always be lowest priority since
  134. it is a "catch-all" type receiver).
  135. config IEEE802154_NETDEV_DEFAULT_PREFIX_0
  136. hex "IPv6 Prefix 0"
  137. default 0xfe80
  138. ---help---
  139. First section of IPv6 Prefix
  140. config IEEE802154_NETDEV_DEFAULT_PREFIX_1
  141. hex "IPv6 Prefix 1"
  142. default 0x0000
  143. ---help---
  144. Second section of IPv6 Prefix
  145. config IEEE802154_NETDEV_DEFAULT_PREFIX_2
  146. hex "IPv6 Prefix 2"
  147. default 0x0000
  148. ---help---
  149. Third section of IPv6 Prefix
  150. config IEEE802154_NETDEV_DEFAULT_PREFIX_3
  151. hex "IPv6 Prefix 3"
  152. default 0x0000
  153. ---help---
  154. Fourth section of IPv6 Prefix
  155. endif # IEEE802154_NETDEV
  156. endif # IEEE802154_MACDEV
  157. config IEEE802154_LOOPBACK
  158. bool "IEEE802154 6LoWPAN Loopback"
  159. default n
  160. depends on NET_6LOWPAN || NET_IEEE802154
  161. select ARCH_HAVE_NETDEV_STATISTICS
  162. ---help---
  163. Add support for the IEEE802.15.4 6LoWPAN Loopback test device.
  164. if IEEE802154_LOOPBACK
  165. endif # IEEE802154_LOOPBACK
  166. endif # WIRELESS_IEEE802154