rtx_os.h 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489
  1. /*
  2. * Copyright (c) 2013-2023 Arm Limited. All rights reserved.
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. *
  6. * Licensed under the Apache License, Version 2.0 (the License); you may
  7. * not use this file except in compliance with the License.
  8. * You may obtain a copy of the License at
  9. *
  10. * www.apache.org/licenses/LICENSE-2.0
  11. *
  12. * Unless required by applicable law or agreed to in writing, software
  13. * distributed under the License is distributed on an AS IS BASIS, WITHOUT
  14. * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. * See the License for the specific language governing permissions and
  16. * limitations under the License.
  17. *
  18. * -----------------------------------------------------------------------------
  19. *
  20. * Project: CMSIS-RTOS RTX
  21. * Title: RTX OS definitions
  22. *
  23. * -----------------------------------------------------------------------------
  24. */
  25. #ifndef RTX_OS_H_
  26. #define RTX_OS_H_
  27. #include <stdint.h>
  28. #include <stddef.h>
  29. #include "cmsis_os2.h"
  30. #include "rtx_def.h"
  31. #ifdef __cplusplus
  32. extern "C"
  33. {
  34. #endif
  35. /// Kernel Information
  36. #define osRtxVersionAPI 20020000 ///< API version (2.2.0)
  37. #define osRtxVersionKernel 50070000 ///< Kernel version (5.7.0)
  38. #define osRtxKernelId "RTX V5.7.0" ///< Kernel identification string
  39. // ==== Common definitions ====
  40. /// Object Identifier definitions
  41. #define osRtxIdInvalid 0x00U
  42. #define osRtxIdThread 0xF1U
  43. #define osRtxIdTimer 0xF2U
  44. #define osRtxIdEventFlags 0xF3U
  45. #define osRtxIdMutex 0xF5U
  46. #define osRtxIdSemaphore 0xF6U
  47. #define osRtxIdMemoryPool 0xF7U
  48. #define osRtxIdMessage 0xF9U
  49. #define osRtxIdMessageQueue 0xFAU
  50. /// Object Flags definitions
  51. #define osRtxFlagSystemObject 0x01U
  52. #define osRtxFlagSystemMemory 0x02U
  53. /// Object Attribute Class definitions
  54. #define osRtxAttrClass_Pos 4U
  55. #define osRtxAttrClass_Msk 0xF0U
  56. // ==== Kernel definitions ====
  57. /// Kernel State definitions
  58. #define osRtxKernelInactive ((uint8_t)osKernelInactive)
  59. #define osRtxKernelReady ((uint8_t)osKernelReady)
  60. #define osRtxKernelRunning ((uint8_t)osKernelRunning)
  61. #define osRtxKernelLocked ((uint8_t)osKernelLocked)
  62. #define osRtxKernelSuspended ((uint8_t)osKernelSuspended)
  63. /// Kernel Protect definitions
  64. #define osRtxKernelProtectPrivileged 0x01U
  65. #define osRtxKernelProtectClass_Pos 4U
  66. #define osRtxKernelProtectClass_Msk 0xF0U
  67. // ==== Thread definitions ====
  68. /// Thread State definitions (extending osThreadState)
  69. #define osRtxThreadStateMask 0x0FU
  70. #define osRtxThreadInactive ((uint8_t)osThreadInactive)
  71. #define osRtxThreadReady ((uint8_t)osThreadReady)
  72. #define osRtxThreadRunning ((uint8_t)osThreadRunning)
  73. #define osRtxThreadBlocked ((uint8_t)osThreadBlocked)
  74. #define osRtxThreadTerminated ((uint8_t)osThreadTerminated)
  75. #define osRtxThreadWaitingDelay ((uint8_t)(osRtxThreadBlocked | 0x10U))
  76. #define osRtxThreadWaitingJoin ((uint8_t)(osRtxThreadBlocked | 0x20U))
  77. #define osRtxThreadWaitingThreadFlags ((uint8_t)(osRtxThreadBlocked | 0x30U))
  78. #define osRtxThreadWaitingEventFlags ((uint8_t)(osRtxThreadBlocked | 0x40U))
  79. #define osRtxThreadWaitingMutex ((uint8_t)(osRtxThreadBlocked | 0x50U))
  80. #define osRtxThreadWaitingSemaphore ((uint8_t)(osRtxThreadBlocked | 0x60U))
  81. #define osRtxThreadWaitingMemoryPool ((uint8_t)(osRtxThreadBlocked | 0x70U))
  82. #define osRtxThreadWaitingMessageGet ((uint8_t)(osRtxThreadBlocked | 0x80U))
  83. #define osRtxThreadWaitingMessagePut ((uint8_t)(osRtxThreadBlocked | 0x90U))
  84. /// Thread Flags definitions
  85. #define osRtxThreadFlagDefStack 0x10U ///< Default Stack flag
  86. /// Stack Marker definitions
  87. #define osRtxStackMagicWord 0xE25A2EA5U ///< Stack Magic Word (Stack Base)
  88. #define osRtxStackFillPattern 0xCCCCCCCCU ///< Stack Fill Pattern
  89. /// Thread Control Block
  90. typedef struct osRtxThread_s {
  91. uint8_t id; ///< Object Identifier
  92. uint8_t state; ///< Object State
  93. uint8_t flags; ///< Object Flags
  94. uint8_t attr; ///< Object Attributes
  95. const char *name; ///< Object Name
  96. struct osRtxThread_s *thread_next; ///< Link pointer to next Thread in Object list
  97. struct osRtxThread_s *thread_prev; ///< Link pointer to previous Thread in Object list
  98. struct osRtxThread_s *delay_next; ///< Link pointer to next Thread in Delay list
  99. struct osRtxThread_s *delay_prev; ///< Link pointer to previous Thread in Delay list
  100. struct osRtxThread_s *thread_join; ///< Thread waiting to Join
  101. uint32_t delay; ///< Delay Time/Round Robin Time Tick
  102. int8_t priority; ///< Thread Priority
  103. int8_t priority_base; ///< Base Priority
  104. uint8_t stack_frame; ///< Stack Frame (EXC_RETURN[7..0])
  105. uint8_t flags_options; ///< Thread/Event Flags Options
  106. uint32_t wait_flags; ///< Waiting Thread/Event Flags
  107. uint32_t thread_flags; ///< Thread Flags
  108. struct osRtxMutex_s *mutex_list; ///< Link pointer to list of owned Mutexes
  109. void *stack_mem; ///< Stack Memory
  110. uint32_t stack_size; ///< Stack Size
  111. uint32_t sp; ///< Current Stack Pointer
  112. uint32_t thread_addr; ///< Thread entry address
  113. uint32_t tz_memory; ///< TrustZone Memory Identifier
  114. uint8_t zone; ///< Thread Zone
  115. uint8_t reserved[3];
  116. struct osRtxThread_s *wdog_next; ///< Link pointer to next Thread in Watchdog list
  117. uint32_t wdog_tick; ///< Watchdog tick counter
  118. } osRtxThread_t;
  119. // ==== Timer definitions ====
  120. /// Timer State definitions
  121. #define osRtxTimerInactive 0x00U ///< Timer Inactive
  122. #define osRtxTimerStopped 0x01U ///< Timer Stopped
  123. #define osRtxTimerRunning 0x02U ///< Timer Running
  124. /// Timer attribute definitions
  125. #define osRtxTimerPeriodic 0x01U ///< Timer Periodic mode
  126. /// Timer Function Information
  127. typedef struct {
  128. osTimerFunc_t func; ///< Function Pointer
  129. void *arg; ///< Function Argument
  130. } osRtxTimerFinfo_t;
  131. /// Timer Control Block
  132. typedef struct osRtxTimer_s {
  133. uint8_t id; ///< Object Identifier
  134. uint8_t state; ///< Object State
  135. uint8_t flags; ///< Object Flags
  136. uint8_t attr; ///< Object Attributes
  137. const char *name; ///< Object Name
  138. struct osRtxTimer_s *prev; ///< Pointer to previous active Timer
  139. struct osRtxTimer_s *next; ///< Pointer to next active Timer
  140. uint32_t tick; ///< Timer current Tick
  141. uint32_t load; ///< Timer Load value
  142. osRtxTimerFinfo_t finfo; ///< Timer Function Info
  143. } osRtxTimer_t;
  144. // ==== Event Flags definitions ====
  145. /// Event Flags Control Block
  146. typedef struct {
  147. uint8_t id; ///< Object Identifier
  148. uint8_t reserved_state; ///< Object State (not used)
  149. uint8_t flags; ///< Object Flags
  150. uint8_t attr; ///< Object Attributes
  151. const char *name; ///< Object Name
  152. osRtxThread_t *thread_list; ///< Waiting Threads List
  153. uint32_t event_flags; ///< Event Flags
  154. } osRtxEventFlags_t;
  155. // ==== Mutex definitions ====
  156. /// Mutex Control Block
  157. typedef struct osRtxMutex_s {
  158. uint8_t id; ///< Object Identifier
  159. uint8_t reserved_state; ///< Object State (not used)
  160. uint8_t flags; ///< Object Flags
  161. uint8_t attr; ///< Object Attributes
  162. const char *name; ///< Object Name
  163. osRtxThread_t *thread_list; ///< Waiting Threads List
  164. osRtxThread_t *owner_thread; ///< Owner Thread
  165. struct osRtxMutex_s *owner_prev; ///< Pointer to previous owned Mutex
  166. struct osRtxMutex_s *owner_next; ///< Pointer to next owned Mutex
  167. uint8_t lock; ///< Lock counter
  168. uint8_t padding[3];
  169. } osRtxMutex_t;
  170. // ==== Semaphore definitions ====
  171. /// Semaphore Control Block
  172. typedef struct {
  173. uint8_t id; ///< Object Identifier
  174. uint8_t reserved_state; ///< Object State (not used)
  175. uint8_t flags; ///< Object Flags
  176. uint8_t attr; ///< Object Attributes
  177. const char *name; ///< Object Name
  178. osRtxThread_t *thread_list; ///< Waiting Threads List
  179. uint16_t tokens; ///< Current number of tokens
  180. uint16_t max_tokens; ///< Maximum number of tokens
  181. } osRtxSemaphore_t;
  182. // ==== Memory Pool definitions ====
  183. /// Memory Pool Information
  184. typedef struct {
  185. uint32_t max_blocks; ///< Maximum number of Blocks
  186. uint32_t used_blocks; ///< Number of used Blocks
  187. uint32_t block_size; ///< Block Size
  188. void *block_base; ///< Block Memory Base Address
  189. void *block_lim; ///< Block Memory Limit Address
  190. void *block_free; ///< First free Block Address
  191. } osRtxMpInfo_t;
  192. /// Memory Pool Control Block
  193. typedef struct {
  194. uint8_t id; ///< Object Identifier
  195. uint8_t reserved_state; ///< Object State (not used)
  196. uint8_t flags; ///< Object Flags
  197. uint8_t attr; ///< Object Attributes
  198. const char *name; ///< Object Name
  199. osRtxThread_t *thread_list; ///< Waiting Threads List
  200. osRtxMpInfo_t mp_info; ///< Memory Pool Info
  201. } osRtxMemoryPool_t;
  202. // ==== Message Queue definitions ====
  203. /// Message Control Block
  204. typedef struct osRtxMessage_s {
  205. uint8_t id; ///< Object Identifier
  206. uint8_t reserved_state; ///< Object State (not used)
  207. uint8_t flags; ///< Object Flags
  208. uint8_t priority; ///< Message Priority
  209. struct osRtxMessage_s *prev; ///< Pointer to previous Message
  210. struct osRtxMessage_s *next; ///< Pointer to next Message
  211. } osRtxMessage_t;
  212. /// Message Queue Control Block
  213. typedef struct {
  214. uint8_t id; ///< Object Identifier
  215. uint8_t reserved_state; ///< Object State (not used)
  216. uint8_t flags; ///< Object Flags
  217. uint8_t attr; ///< Object Attributes
  218. const char *name; ///< Object Name
  219. osRtxThread_t *thread_list; ///< Waiting Threads List
  220. osRtxMpInfo_t mp_info; ///< Memory Pool Info
  221. uint32_t msg_size; ///< Message Size
  222. uint32_t msg_count; ///< Number of queued Messages
  223. osRtxMessage_t *msg_first; ///< Pointer to first Message
  224. osRtxMessage_t *msg_last; ///< Pointer to last Message
  225. } osRtxMessageQueue_t;
  226. // ==== Generic Object definitions ====
  227. /// Generic Object Control Block
  228. typedef struct {
  229. uint8_t id; ///< Object Identifier
  230. uint8_t state; ///< Object State
  231. uint8_t flags; ///< Object Flags
  232. uint8_t attr; ///< Object Attributes
  233. const char *name; ///< Object Name
  234. osRtxThread_t *thread_list; ///< Threads List
  235. } osRtxObject_t;
  236. // ==== OS Runtime Information definitions ====
  237. /// OS Runtime Information structure
  238. typedef struct {
  239. const char *os_id; ///< OS Identification
  240. uint32_t version; ///< OS Version
  241. struct { ///< Kernel Info
  242. uint8_t state; ///< State
  243. volatile uint8_t blocked; ///< Blocked
  244. uint8_t pendSV; ///< Pending SV
  245. uint8_t protect; ///< Protect options
  246. uint32_t tick; ///< Tick counter
  247. } kernel;
  248. int32_t tick_irqn; ///< Tick Timer IRQ Number
  249. struct { ///< Thread Info
  250. struct { ///< Thread Run Info
  251. osRtxThread_t *curr; ///< Current running Thread
  252. osRtxThread_t *next; ///< Next Thread to Run
  253. } run;
  254. osRtxObject_t ready; ///< Ready List Object
  255. osRtxThread_t *idle; ///< Idle Thread
  256. osRtxThread_t *delay_list; ///< Delay List
  257. osRtxThread_t *wait_list; ///< Wait List (no Timeout)
  258. osRtxThread_t *terminate_list; ///< Terminate Thread List
  259. osRtxThread_t *wdog_list; ///< Watchdog List
  260. struct { ///< Thread Round Robin Info
  261. osRtxThread_t *thread; ///< Round Robin Thread
  262. uint32_t timeout; ///< Round Robin Timeout
  263. } robin;
  264. } thread;
  265. struct { ///< Timer Info
  266. osRtxTimer_t *list; ///< Active Timer List
  267. osRtxThread_t *thread; ///< Timer Thread
  268. osRtxMessageQueue_t *mq; ///< Timer Message Queue
  269. void (*tick)(void); ///< Timer Tick Function
  270. } timer;
  271. struct { ///< ISR Post Processing Queue
  272. uint16_t max; ///< Maximum Items
  273. uint16_t cnt; ///< Item Count
  274. uint16_t in; ///< Incoming Item Index
  275. uint16_t out; ///< Outgoing Item Index
  276. void **data; ///< Queue Data
  277. } isr_queue;
  278. struct { ///< ISR Post Processing functions
  279. void (*thread)(osRtxThread_t*); ///< Thread Post Processing function
  280. void (*event_flags)(osRtxEventFlags_t*); ///< Event Flags Post Processing function
  281. void (*semaphore)(osRtxSemaphore_t*); ///< Semaphore Post Processing function
  282. void (*memory_pool)(osRtxMemoryPool_t*); ///< Memory Pool Post Processing function
  283. void (*message)(osRtxMessage_t*); ///< Message Post Processing function
  284. } post_process;
  285. struct { ///< Memory Pools (Variable Block Size)
  286. void *stack; ///< Stack Memory
  287. void *mp_data; ///< Memory Pool Data Memory
  288. void *mq_data; ///< Message Queue Data Memory
  289. void *common; ///< Common Memory
  290. } mem;
  291. struct { ///< Memory Pools (Fixed Block Size)
  292. osRtxMpInfo_t *stack; ///< Stack for Threads
  293. osRtxMpInfo_t *thread; ///< Thread Control Blocks
  294. osRtxMpInfo_t *timer; ///< Timer Control Blocks
  295. osRtxMpInfo_t *event_flags; ///< Event Flags Control Blocks
  296. osRtxMpInfo_t *mutex; ///< Mutex Control Blocks
  297. osRtxMpInfo_t *semaphore; ///< Semaphore Control Blocks
  298. osRtxMpInfo_t *memory_pool; ///< Memory Pool Control Blocks
  299. osRtxMpInfo_t *message_queue; ///< Message Queue Control Blocks
  300. } mpi;
  301. } osRtxInfo_t;
  302. extern osRtxInfo_t osRtxInfo; ///< OS Runtime Information
  303. /// OS Runtime Object Memory Usage structure
  304. typedef struct {
  305. uint32_t cnt_alloc; ///< Counter for alloc
  306. uint32_t cnt_free; ///< Counter for free
  307. uint32_t max_used; ///< Maximum used
  308. } osRtxObjectMemUsage_t;
  309. /// OS Runtime Object Memory Usage variables
  310. extern osRtxObjectMemUsage_t osRtxThreadMemUsage;
  311. extern osRtxObjectMemUsage_t osRtxTimerMemUsage;
  312. extern osRtxObjectMemUsage_t osRtxEventFlagsMemUsage;
  313. extern osRtxObjectMemUsage_t osRtxMutexMemUsage;
  314. extern osRtxObjectMemUsage_t osRtxSemaphoreMemUsage;
  315. extern osRtxObjectMemUsage_t osRtxMemoryPoolMemUsage;
  316. extern osRtxObjectMemUsage_t osRtxMessageQueueMemUsage;
  317. // ==== OS API definitions ====
  318. // Object Limits definitions
  319. #define osRtxThreadFlagsLimit 31U ///< number of Thread Flags available per thread
  320. #define osRtxEventFlagsLimit 31U ///< number of Event Flags available per object
  321. #define osRtxMutexLockLimit 255U ///< maximum number of recursive mutex locks
  322. #define osRtxSemaphoreTokenLimit 65535U ///< maximum number of tokens per semaphore
  323. // Control Block sizes
  324. #define osRtxThreadCbSize sizeof(osRtxThread_t)
  325. #define osRtxTimerCbSize sizeof(osRtxTimer_t)
  326. #define osRtxEventFlagsCbSize sizeof(osRtxEventFlags_t)
  327. #define osRtxMutexCbSize sizeof(osRtxMutex_t)
  328. #define osRtxSemaphoreCbSize sizeof(osRtxSemaphore_t)
  329. #define osRtxMemoryPoolCbSize sizeof(osRtxMemoryPool_t)
  330. #define osRtxMessageQueueCbSize sizeof(osRtxMessageQueue_t)
  331. /// Memory size in bytes for Memory Pool storage.
  332. /// \param block_count maximum number of memory blocks in memory pool.
  333. /// \param block_size memory block size in bytes.
  334. #define osRtxMemoryPoolMemSize(block_count, block_size) \
  335. (4*(block_count)*(((block_size)+3)/4))
  336. /// Memory size in bytes for Message Queue storage.
  337. /// \param msg_count maximum number of messages in queue.
  338. /// \param msg_size maximum message size in bytes.
  339. #define osRtxMessageQueueMemSize(msg_count, msg_size) \
  340. (4*(msg_count)*(3+(((msg_size)+3)/4)))
  341. // ==== OS External Functions ====
  342. // OS Error Codes
  343. #define osRtxErrorStackUnderflow 1U ///< \deprecated Superseded by \ref osRtxErrorStackOverflow.
  344. #define osRtxErrorStackOverflow 1U ///< Stack overflow, i.e. stack pointer below its lower memory limit for descending stacks.
  345. #define osRtxErrorISRQueueOverflow 2U ///< ISR Queue overflow detected when inserting object.
  346. #define osRtxErrorTimerQueueOverflow 3U ///< User Timer Callback Queue overflow detected for timer.
  347. #define osRtxErrorClibSpace 4U ///< Standard C/C++ library libspace not available: increase \c OS_THREAD_LIBSPACE_NUM.
  348. #define osRtxErrorClibMutex 5U ///< Standard C/C++ library mutex initialization failed.
  349. #define osRtxErrorSVC 6U ///< Invalid SVC function called.
  350. /// OS Error Callback function
  351. extern uint32_t osRtxErrorNotify (uint32_t code, void *object_id);
  352. extern uint32_t osRtxKernelErrorNotify (uint32_t code, void *object_id);
  353. /// OS Idle Thread
  354. extern void osRtxIdleThread (void *argument);
  355. /// OS Exception handlers
  356. extern void SVC_Handler (void);
  357. extern void PendSV_Handler (void);
  358. extern void SysTick_Handler (void);
  359. // ==== OS External Configuration ====
  360. /// OS Configuration flags
  361. #define osRtxConfigPrivilegedMode (1UL<<0) ///< Threads in Privileged mode
  362. #define osRtxConfigStackCheck (1UL<<1) ///< Stack overrun checking
  363. #define osRtxConfigStackWatermark (1UL<<2) ///< Stack usage Watermark
  364. #define osRtxConfigSafetyFeatures (1UL<<3) ///< Safety features enabled
  365. #define osRtxConfigSafetyClass (1UL<<4) ///< Safety Class feature enabled
  366. #define osRtxConfigExecutionZone (1UL<<5) ///< Execution Zone enabled
  367. #define osRtxConfigThreadWatchdog (1UL<<6) ///< Thread Watchdog enabled
  368. #define osRtxConfigObjPtrCheck (1UL<<7) ///< Object Pointer Checking enabled
  369. #define osRtxConfigSVCPtrCheck (1UL<<8) ///< SVC Pointer Checking enabled
  370. /// OS Configuration structure
  371. typedef struct {
  372. uint32_t flags; ///< OS Configuration Flags
  373. uint32_t tick_freq; ///< Kernel Tick Frequency
  374. uint32_t robin_timeout; ///< Round Robin Timeout Tick
  375. struct { ///< ISR Post Processing Queue
  376. void **data; ///< Queue Data
  377. uint16_t max; ///< Maximum Items
  378. uint16_t padding;
  379. } isr_queue;
  380. struct { ///< Memory Pools (Variable Block Size)
  381. void *stack_addr; ///< Stack Memory Address
  382. uint32_t stack_size; ///< Stack Memory Size
  383. void *mp_data_addr; ///< Memory Pool Memory Address
  384. uint32_t mp_data_size; ///< Memory Pool Memory Size
  385. void *mq_data_addr; ///< Message Queue Data Memory Address
  386. uint32_t mq_data_size; ///< Message Queue Data Memory Size
  387. void *common_addr; ///< Common Memory Address
  388. uint32_t common_size; ///< Common Memory Size
  389. } mem;
  390. struct { ///< Memory Pools (Fixed Block Size)
  391. osRtxMpInfo_t *stack; ///< Stack for Threads
  392. osRtxMpInfo_t *thread; ///< Thread Control Blocks
  393. osRtxMpInfo_t *timer; ///< Timer Control Blocks
  394. osRtxMpInfo_t *event_flags; ///< Event Flags Control Blocks
  395. osRtxMpInfo_t *mutex; ///< Mutex Control Blocks
  396. osRtxMpInfo_t *semaphore; ///< Semaphore Control Blocks
  397. osRtxMpInfo_t *memory_pool; ///< Memory Pool Control Blocks
  398. osRtxMpInfo_t *message_queue; ///< Message Queue Control Blocks
  399. } mpi;
  400. uint32_t thread_stack_size; ///< Default Thread Stack Size
  401. const
  402. osThreadAttr_t *idle_thread_attr; ///< Idle Thread Attributes
  403. const
  404. osThreadAttr_t *timer_thread_attr; ///< Timer Thread Attributes
  405. void (*timer_thread)(void *); ///< Timer Thread Function
  406. int32_t (*timer_setup)(void); ///< Timer Setup Function
  407. const
  408. osMessageQueueAttr_t *timer_mq_attr; ///< Timer Message Queue Attributes
  409. uint32_t timer_mq_mcnt; ///< Timer Message Queue maximum Messages
  410. } osRtxConfig_t;
  411. extern const osRtxConfig_t osRtxConfig; ///< OS Configuration
  412. #ifdef __cplusplus
  413. }
  414. #endif
  415. #endif // RTX_OS_H_