<?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>topic Re: GRAM in CodeWarrior Development Tools</title>
    <link>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801178#M7008</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi. Thx for your answer. Yes, i can make this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am work FreeRTOS.&amp;nbsp;&lt;/P&gt;&lt;P&gt;It's&amp;nbsp;FreeRTOSv9.0.0 from site Free RTOS. I make my project basic on Demo CodeWarrior and add my tasks.&lt;/P&gt;&lt;P&gt;I put file from this project ( menager memory RTOS ) heap_5. In portable file project i see:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;typedef struct HeapRegion&lt;BR /&gt;{&lt;BR /&gt; uint8_t * __far pucStartAddress;&lt;BR /&gt; size_t xSizeInBytes;&lt;BR /&gt;} HeapRegion_t;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In file heap_5 :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;* Usage notes:&lt;BR /&gt; *&lt;BR /&gt; * vPortDefineHeapRegions() ***must*** be called before pvPortMalloc().&lt;BR /&gt; * pvPortMalloc() will be called if any task objects (tasks, queues, event&lt;BR /&gt; * groups, etc.) are created, therefore vPortDefineHeapRegions() ***must*** be&lt;BR /&gt; * called before any other objects are defined.&lt;BR /&gt; *&lt;BR /&gt; * vPortDefineHeapRegions() takes a single parameter. The parameter is an array&lt;BR /&gt; * of HeapRegion_t structures. HeapRegion_t is defined in portable.h as&lt;BR /&gt; *&lt;BR /&gt; * typedef struct HeapRegion&lt;BR /&gt; * {&lt;BR /&gt; * uint8_t *pucStartAddress; &amp;lt;&amp;lt; Start address of a block of memory that will be part of the heap.&lt;BR /&gt; * size_t xSizeInBytes; &amp;lt;&amp;lt; Size of the block of memory.&lt;BR /&gt; * } HeapRegion_t;&lt;BR /&gt; *&lt;BR /&gt; * The array is terminated using a NULL zero sized region definition, and the&lt;BR /&gt; * memory regions defined in the array ***must*** appear in address order from&lt;BR /&gt; * low address to high address. So the following is a valid example of how&lt;BR /&gt; * to use the function.&lt;BR /&gt; *&lt;BR /&gt; * HeapRegion_t xHeapRegions[] =&lt;BR /&gt; * {&lt;BR /&gt; * { ( uint8_t * ) 0x80000000UL, 0x10000 }, &amp;lt;&amp;lt; Defines a block of 0x10000 bytes starting at address 0x80000000&lt;BR /&gt; * { ( uint8_t * ) 0x90000000UL, 0xa0000 }, &amp;lt;&amp;lt; Defines a block of 0xa0000 bytes starting at address of 0x90000000&lt;BR /&gt; * { NULL, 0 } &amp;lt;&amp;lt; Terminates the array.&lt;BR /&gt; * };&lt;BR /&gt; *&lt;BR /&gt; * vPortDefineHeapRegions( xHeapRegions ); &amp;lt;&amp;lt; Pass the array into vPortDefineHeapRegions().&lt;BR /&gt; *&lt;BR /&gt; * Note 0x80000000 is the lower address so appears in the array first.&lt;BR /&gt; *&lt;BR /&gt; */&lt;/P&gt;&lt;P&gt;I can't&amp;nbsp; equate&amp;nbsp;&lt;SPAN&gt;pucStartAddress = start address page RAM (&amp;nbsp; RAM_FA, RAM_FB, RAM_FC ) .&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I first variant -&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;static HeapRegion_t xHeapRegions[] =&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ ( uint8_t * __far)(0x0FA000), 0x1000 },&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ ( uint8_t * __far)(0x0FB000), 0x1000 },&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ ( uint8_t * __far)(0x0FC000), 0x1000 },&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ NULL, 0 }&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;};&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Not work...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I am add :&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;#pragma push&lt;BR /&gt; &lt;BR /&gt;#pragma DATA_SEG __GPAGE_SEG PAGED_G_RAM&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;static HeapRegion_t xHeapRegions[] =&lt;BR /&gt;{&lt;BR /&gt; { ( uint8_t * __far)(0x0FA000), 0x1000 },&lt;BR /&gt; { ( uint8_t * __far)(0x0FB000), 0x1000 },&lt;BR /&gt; { ( uint8_t * __far)(0x0FC000), 0x1000 },&lt;BR /&gt; { NULL, 0 } &lt;BR /&gt;};&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;#pragma pop&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I am stop...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 03 Aug 2018 11:15:01 GMT</pubDate>
    <dc:creator>dlp</dc:creator>
    <dc:date>2018-08-03T11:15:01Z</dc:date>
    <item>
      <title>GRAM</title>
      <link>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801174#M7004</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi. I am work with MCU 9S12XEP100. My project include Free RTOS. Help me, please. I need setting heap RTOS into&amp;nbsp;&lt;/P&gt;&lt;P&gt;paged RAM. It's must addres global. I don't know what this make...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 31 Jul 2018 12:48:36 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801174#M7004</guid>
      <dc:creator>dlp</dc:creator>
      <dc:date>2018-07-31T12:48:36Z</dc:date>
    </item>
    <item>
      <title>Re: GRAM</title>
      <link>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801175#M7005</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Under CW 5.x install folder, there is demo code&lt;/P&gt;&lt;P&gt;..\(CodeWarrior_Examples)\HCS12X\GlobalAddressing&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;open this project and see function RAM_Demo(). it is about how to allocate data in global address in RAM.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Jennie Zhang&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>Thu, 02 Aug 2018 08:30:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801175#M7005</guid>
      <dc:creator>ZhangJennie</dc:creator>
      <dc:date>2018-08-02T08:30:57Z</dc:date>
    </item>
    <item>
      <title>Re: GRAM</title>
      <link>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801176#M7006</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thx for your answer. But i can work with Global RAM. I work with FreeRTOS. If i set heap_5 - I need define 1-3 paged of RAM. I don't understand what change in RTOS files... If I set this - CPU not change page and software crash...&lt;/P&gt;&lt;P&gt;If i set heap_1 - software is work. But next time i need more free RAM in tasks...&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards, Pavel.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Aug 2018 15:15:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801176#M7006</guid>
      <dc:creator>dlp</dc:creator>
      <dc:date>2018-08-02T15:15:35Z</dc:date>
    </item>
    <item>
      <title>Re: GRAM</title>
      <link>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801177#M7007</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Can you please narrow down your problem and send me a demo project of your problem?&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;Jennie.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Aug 2018 07:40:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801177#M7007</guid>
      <dc:creator>ZhangJennie</dc:creator>
      <dc:date>2018-08-03T07:40:33Z</dc:date>
    </item>
    <item>
      <title>Re: GRAM</title>
      <link>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801178#M7008</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi. Thx for your answer. Yes, i can make this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am work FreeRTOS.&amp;nbsp;&lt;/P&gt;&lt;P&gt;It's&amp;nbsp;FreeRTOSv9.0.0 from site Free RTOS. I make my project basic on Demo CodeWarrior and add my tasks.&lt;/P&gt;&lt;P&gt;I put file from this project ( menager memory RTOS ) heap_5. In portable file project i see:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;typedef struct HeapRegion&lt;BR /&gt;{&lt;BR /&gt; uint8_t * __far pucStartAddress;&lt;BR /&gt; size_t xSizeInBytes;&lt;BR /&gt;} HeapRegion_t;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In file heap_5 :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;* Usage notes:&lt;BR /&gt; *&lt;BR /&gt; * vPortDefineHeapRegions() ***must*** be called before pvPortMalloc().&lt;BR /&gt; * pvPortMalloc() will be called if any task objects (tasks, queues, event&lt;BR /&gt; * groups, etc.) are created, therefore vPortDefineHeapRegions() ***must*** be&lt;BR /&gt; * called before any other objects are defined.&lt;BR /&gt; *&lt;BR /&gt; * vPortDefineHeapRegions() takes a single parameter. The parameter is an array&lt;BR /&gt; * of HeapRegion_t structures. HeapRegion_t is defined in portable.h as&lt;BR /&gt; *&lt;BR /&gt; * typedef struct HeapRegion&lt;BR /&gt; * {&lt;BR /&gt; * uint8_t *pucStartAddress; &amp;lt;&amp;lt; Start address of a block of memory that will be part of the heap.&lt;BR /&gt; * size_t xSizeInBytes; &amp;lt;&amp;lt; Size of the block of memory.&lt;BR /&gt; * } HeapRegion_t;&lt;BR /&gt; *&lt;BR /&gt; * The array is terminated using a NULL zero sized region definition, and the&lt;BR /&gt; * memory regions defined in the array ***must*** appear in address order from&lt;BR /&gt; * low address to high address. So the following is a valid example of how&lt;BR /&gt; * to use the function.&lt;BR /&gt; *&lt;BR /&gt; * HeapRegion_t xHeapRegions[] =&lt;BR /&gt; * {&lt;BR /&gt; * { ( uint8_t * ) 0x80000000UL, 0x10000 }, &amp;lt;&amp;lt; Defines a block of 0x10000 bytes starting at address 0x80000000&lt;BR /&gt; * { ( uint8_t * ) 0x90000000UL, 0xa0000 }, &amp;lt;&amp;lt; Defines a block of 0xa0000 bytes starting at address of 0x90000000&lt;BR /&gt; * { NULL, 0 } &amp;lt;&amp;lt; Terminates the array.&lt;BR /&gt; * };&lt;BR /&gt; *&lt;BR /&gt; * vPortDefineHeapRegions( xHeapRegions ); &amp;lt;&amp;lt; Pass the array into vPortDefineHeapRegions().&lt;BR /&gt; *&lt;BR /&gt; * Note 0x80000000 is the lower address so appears in the array first.&lt;BR /&gt; *&lt;BR /&gt; */&lt;/P&gt;&lt;P&gt;I can't&amp;nbsp; equate&amp;nbsp;&lt;SPAN&gt;pucStartAddress = start address page RAM (&amp;nbsp; RAM_FA, RAM_FB, RAM_FC ) .&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I first variant -&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;static HeapRegion_t xHeapRegions[] =&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ ( uint8_t * __far)(0x0FA000), 0x1000 },&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ ( uint8_t * __far)(0x0FB000), 0x1000 },&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ ( uint8_t * __far)(0x0FC000), 0x1000 },&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{ NULL, 0 }&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;};&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Not work...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I am add :&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;#pragma push&lt;BR /&gt; &lt;BR /&gt;#pragma DATA_SEG __GPAGE_SEG PAGED_G_RAM&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;static HeapRegion_t xHeapRegions[] =&lt;BR /&gt;{&lt;BR /&gt; { ( uint8_t * __far)(0x0FA000), 0x1000 },&lt;BR /&gt; { ( uint8_t * __far)(0x0FB000), 0x1000 },&lt;BR /&gt; { ( uint8_t * __far)(0x0FC000), 0x1000 },&lt;BR /&gt; { NULL, 0 } &lt;BR /&gt;};&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;#pragma pop&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I am stop...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Aug 2018 11:15:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801178#M7008</guid>
      <dc:creator>dlp</dc:creator>
      <dc:date>2018-08-03T11:15:01Z</dc:date>
    </item>
    <item>
      <title>Re: GRAM</title>
      <link>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801179#M7009</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Pavel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unless&amp;nbsp;there&amp;nbsp;is&amp;nbsp;common typedef for pointer in your&amp;nbsp;far RAM, which you could modify with __far keyword,&amp;nbsp;I guess you need to modify FreeRTOS heap??.c seriously, modifying nearly every&amp;nbsp;pointer with __far keyword...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edward&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 04 Aug 2018 09:40:07 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-Development-Tools/GRAM/m-p/801179#M7009</guid>
      <dc:creator>kef2</dc:creator>
      <dc:date>2018-08-04T09:40:07Z</dc:date>
    </item>
  </channel>
</rss>

