テスト用のあれこれ共用フォルダ
Revision | 78946eebd430f8866e5a45965d6cb68dc313c842 (tree) |
---|---|
Time | 2019-02-03 19:38:26 |
Author | takemasa <suikan@user...> |
Commiter | takemasa |
Added doxygen comment
@@ -12,8 +12,8 @@ | ||
12 | 12 | <targetDefinitions> |
13 | 13 | <board id="nucleo-f746zg"> |
14 | 14 | <name>NUCLEO-F746ZG</name> |
15 | - <dbgIF>SWD</dbgIF> | |
16 | 15 | <dbgIF>JTAG</dbgIF> |
16 | + <dbgIF>SWD</dbgIF> | |
17 | 17 | <dbgDEV>ST-Link</dbgDEV> |
18 | 18 | <mcuId>stm32f746zgtx</mcuId> |
19 | 19 | </board> |
@@ -18,19 +18,39 @@ namespace murasaki { | ||
18 | 18 | * This class is handy class to encapsulate the task creation without inheriting. |
19 | 19 | * A task can be created easy like : |
20 | 20 | * @code |
21 | + * // For demonstration of FreeRTOS task. | |
22 | + * murasaki::platform.task1 = new murasaki::Task( | |
23 | + * "Master", | |
24 | + * 256, | |
25 | + * (( configMAX_PRIORITIES > 1) ? 1 : 0), | |
26 | + * nullptr, | |
27 | + * &TaskBodyFunction | |
28 | + * ); | |
29 | + * @endcode | |
30 | + * | |
31 | + * Then, task you can call Start() member function to run. | |
21 | 32 | * |
33 | + * @code | |
34 | + * murasaki::platform.task1->Start(); | |
22 | 35 | * @endcode |
23 | 36 | * |
24 | 37 | */ |
25 | 38 | class Task : public murasaki::AbstractTask { |
26 | 39 | public: |
27 | 40 | /** |
41 | + * @brief Ease to use task class. | |
42 | + * @param task_name A name of task. This is relevant to the FreeRTOS's API manner. | |
43 | + * @param stack_depth Task stack size by byte. | |
44 | + * @param task_priority The task priority. Max priority is defined by configMAX_PRIOIRTIES in FreeRTOSConfig.h | |
45 | + * @param task_parameter A pointer to the parameter passed to task. | |
46 | + * @param task_body_func A pointer to the task body function. | |
47 | + * @details | |
48 | + * Create an task object. Given parameters are stored internally. And then passed to the | |
49 | + * FreeRTOS API when task is started by Start() member function. | |
50 | + * | |
51 | + * A task parameter can be passed to task through the task_parameter. This pointer is simply passed | |
52 | + * to the task body function without modification. | |
28 | 53 | * |
29 | - * @param task_name | |
30 | - * @param stack_depth | |
31 | - * @param task_priority | |
32 | - * @param task_parameter | |
33 | - * @param task_body_func | |
34 | 54 | */ |
35 | 55 | Task( |
36 | 56 | const char * task_name, |
@@ -41,15 +61,18 @@ class Task : public murasaki::AbstractTask { | ||
41 | 61 | |
42 | 62 | protected: |
43 | 63 | /** |
44 | - * | |
45 | - * @param ptr | |
64 | + * @brief Task member function. | |
65 | + * @param ptr The task_parameter parameter of the constructor is passed to this parameter. | |
66 | + * @details | |
67 | + * This member function runs as task. In this function, the function passed thorough task_body_func parameter | |
68 | + * is invoked as actual task body. | |
46 | 69 | */ |
47 | 70 | virtual void TaskBody(const void * ptr); |
48 | 71 | |
49 | 72 | private: |
50 | 73 | /** |
51 | 74 | * |
52 | - * @param | |
75 | + * @brief A storage for the pointer to the task body function. | |
53 | 76 | */ |
54 | 77 | void (*task_body_func_)(const void *); |
55 | 78 | }; |