<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>MQX Software SolutionsのトピックRe: Editing the task template when using Processor Expert</title>
    <link>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451561#M15128</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The task template list, which is a list of task templates (TASK_TEMPLATE_STRUCT), defines an initial set of templates that are used to create tasks on the processor if the MQX_CUSTOM_MAIN is not set.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;At initialization, MQX RTOS creates one instance of each task, whose template defines it as an autostart task. In addition, while an application is running, it can create other tasks using a task template that either the task template list defines or the application defines dynamically. The end of the task template list is a zero-filled task template.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;You can assign any combination of the following attributes to a task:&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;• Autostart - when MQX RTOS starts, it creates one instance of the task.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;• DSP - MQX RTOS saves the DSP co-processor registers as part of the task's context.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;• Floating point - MQX RTOS saves floating-point registers as part of the task's context.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;• Time slice - MQX RTOS uses round robin scheduling for the task (the default is FIFO scheduling).&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;For example:&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;TASK_TEMPLATE_STRUCT MQX_template_list[] =&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{ MAIN_TASK, world_task, 0x2000, 5, "world_task",&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;MQX_AUTO_START_TASK, 0L, 0},&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{ HELLO, hello_task, 0x2000, 5, "hello_task",&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;MQX_TIME_SLICE_TASK, 0L, 100},&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{ FLOAT, float_task, 0x2000, 5, "Float_task",&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;MQX_AUTO_START_TASK | MQX_FLOATING_POINT_TASK, 0L, 0},&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{ 0, 0, 0, 0, 0, 0, 0L, 0 }&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;};&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="font-size: 12.0pt;"&gt;world_task&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;The world_task is an autostart task. So, at initialization, MQX RTOS creates one instance of the task with a creation parameter of zero. The application defines the task template index (MAIN_TASK). The task is of priority five. The function world_task() is the code-entry point for the task. The stack size is 0x2000 single-addressable units.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="font-size: 12.0pt;"&gt;hello_task&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;The hello_task task is a time-slice task with a time slice of 100, in milliseconds, if the default compile-time configuration options are used.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="font-size: 12.0pt;"&gt;Float_task&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;The Float_task task is both a floating-point task and an autostart task.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;Multiple tasks, created from the same task template can coexist, and each task is a unique instance.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;You can also create, manage, and terminate tasks, while the application runs.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;Any task (creator) can create another task (child) by calling either the create_task(), _task_create(), _task_create_at() or the _task_create_blocked(), and passing the processor number, a task template index, and a task-creation parameter. The application defines one creation parameter, which is normally used to provide initialization information to the child.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;I suggest to check the following docs.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-103405"&gt;https://community.freescale.com/docs/DOC-103405&lt;/A&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-102663"&gt;https://community.freescale.com/docs/DOC-102663&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In addition, please check the attachment.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Sol&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 21 Aug 2015 00:09:25 GMT</pubDate>
    <dc:creator>soledad</dc:creator>
    <dc:date>2015-08-21T00:09:25Z</dc:date>
    <item>
      <title>Editing the task template when using Processor Expert</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451558#M15125</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm new to MQX. I am using the Kinetis tools to create software using MQX. I have auto generated software using the Processor Expert. The task template is created automatically in the auto generated code folder. I would like to have the freedom to create tasks myself without the help of Processor Expert, but the file containing the task template will get stepped on every time I use PE for other things. Do you have to use the task template to create tasks? If so how do you tell it the stack size etc. without the template? It would be nice to use the template to tell a task to autostart etc, but the auto-generated&amp;nbsp; is not supposed to be edited.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Aug 2015 21:15:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451558#M15125</guid>
      <dc:creator>georgejoseph</dc:creator>
      <dc:date>2015-08-19T21:15:09Z</dc:date>
    </item>
    <item>
      <title>Re: Editing the task template when using Processor Expert</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451559#M15126</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello George, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Which MQX version are you using&amp;nbsp; (traditional MQX RTOS; MQX Lite; or MQX RTOS for Kinetis SDK)??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sol&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2015 17:01:36 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451559#M15126</guid>
      <dc:creator>soledad</dc:creator>
      <dc:date>2015-08-20T17:01:36Z</dc:date>
    </item>
    <item>
      <title>Re: Editing the task template when using Processor Expert</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451560#M15127</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have to assume we are using MQX RTOS for Kinetis SDK.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2015 22:19:51 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451560#M15127</guid>
      <dc:creator>georgejoseph</dc:creator>
      <dc:date>2015-08-20T22:19:51Z</dc:date>
    </item>
    <item>
      <title>Re: Editing the task template when using Processor Expert</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451561#M15128</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The task template list, which is a list of task templates (TASK_TEMPLATE_STRUCT), defines an initial set of templates that are used to create tasks on the processor if the MQX_CUSTOM_MAIN is not set.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;At initialization, MQX RTOS creates one instance of each task, whose template defines it as an autostart task. In addition, while an application is running, it can create other tasks using a task template that either the task template list defines or the application defines dynamically. The end of the task template list is a zero-filled task template.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;You can assign any combination of the following attributes to a task:&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;• Autostart - when MQX RTOS starts, it creates one instance of the task.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;• DSP - MQX RTOS saves the DSP co-processor registers as part of the task's context.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;• Floating point - MQX RTOS saves floating-point registers as part of the task's context.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;• Time slice - MQX RTOS uses round robin scheduling for the task (the default is FIFO scheduling).&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;For example:&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;TASK_TEMPLATE_STRUCT MQX_template_list[] =&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{ MAIN_TASK, world_task, 0x2000, 5, "world_task",&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;MQX_AUTO_START_TASK, 0L, 0},&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{ HELLO, hello_task, 0x2000, 5, "hello_task",&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;MQX_TIME_SLICE_TASK, 0L, 100},&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{ FLOAT, float_task, 0x2000, 5, "Float_task",&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;MQX_AUTO_START_TASK | MQX_FLOATING_POINT_TASK, 0L, 0},&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;{ 0, 0, 0, 0, 0, 0, 0L, 0 }&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 9.0pt; font-family: CourierStd; color: black;"&gt;};&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="font-size: 12.0pt;"&gt;world_task&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;The world_task is an autostart task. So, at initialization, MQX RTOS creates one instance of the task with a creation parameter of zero. The application defines the task template index (MAIN_TASK). The task is of priority five. The function world_task() is the code-entry point for the task. The stack size is 0x2000 single-addressable units.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="font-size: 12.0pt;"&gt;hello_task&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;The hello_task task is a time-slice task with a time slice of 100, in milliseconds, if the default compile-time configuration options are used.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="font-size: 12.0pt;"&gt;Float_task&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;The Float_task task is both a floating-point task and an autostart task.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;Multiple tasks, created from the same task template can coexist, and each task is a unique instance.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;You can also create, manage, and terminate tasks, while the application runs.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;Any task (creator) can create another task (child) by calling either the create_task(), _task_create(), _task_create_at() or the _task_create_blocked(), and passing the processor number, a task template index, and a task-creation parameter. The application defines one creation parameter, which is normally used to provide initialization information to the child.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;I suggest to check the following docs.&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-103405"&gt;https://community.freescale.com/docs/DOC-103405&lt;/A&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-102663"&gt;https://community.freescale.com/docs/DOC-102663&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In addition, please check the attachment.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Sol&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 00:09:25 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451561#M15128</guid>
      <dc:creator>soledad</dc:creator>
      <dc:date>2015-08-21T00:09:25Z</dc:date>
    </item>
    <item>
      <title>Re: Editing the task template when using Processor Expert</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451562#M15129</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Soledad. I think I understand how to create a task using the template. My problem is I don’t have access to the template. You mentioned that you can create a task dynamically. The &lt;U&gt;task&lt;/U&gt;create()&lt;/P&gt;&lt;P&gt;Has only 3 parameters, and I have read that the index parameter is set to zero if not using MQX_template_list[]. How do you define the task this way (name, priority, function..)? The 3rd parameter is called “parameter”. I think this eventually refers to a template. Would this be a template of my creation (not MQX_template_list[])? Can I create a task template and use it?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 13:09:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451562#M15129</guid>
      <dc:creator>georgejoseph</dc:creator>
      <dc:date>2015-08-21T13:09:40Z</dc:date>
    </item>
    <item>
      <title>Re: Editing the task template when using Processor Expert</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451563#M15130</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If the jpg images are a reply I see nothing when I open them.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Aug 2015 14:53:21 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451563#M15130</guid>
      <dc:creator>georgejoseph</dc:creator>
      <dc:date>2015-08-28T14:53:21Z</dc:date>
    </item>
    <item>
      <title>Re: Editing the task template when using Processor Expert</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451564#M15131</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;GJ, did you get a solution to this? I'm trying to solve the exact same problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;NDBill&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Oct 2015 08:52:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/Editing-the-task-template-when-using-Processor-Expert/m-p/451564#M15131</guid>
      <dc:creator>billnd</dc:creator>
      <dc:date>2015-10-14T08:52:33Z</dc:date>
    </item>
  </channel>
</rss>

