<?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: Debugging an array of pointers to structures in Kinetis Design Studio</title>
    <link>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701383#M9174</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Erich,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My structures were a lot more complicated.&amp;nbsp; I ended up declaring &lt;/P&gt;&lt;P&gt;individual array pointers and assigning them the same values in the &lt;/P&gt;&lt;P&gt;array.&amp;nbsp; This way I was able to examine the selected structures I needed &lt;/P&gt;&lt;P&gt;in debug.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mike H.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 24 Aug 2017 08:03:15 GMT</pubDate>
    <dc:creator>michaelhuslig</dc:creator>
    <dc:date>2017-08-24T08:03:15Z</dc:date>
    <item>
      <title>Debugging an array of pointers to structures</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701378#M9169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have an array of structure points which is working in my code (struct userst * user_ptr[MAXUSERS]).&amp;nbsp; What I want to do in debug is hover over the declaration to see what is there.&amp;nbsp; What I am getting now is just:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Expression&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Type&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Value&lt;/P&gt;&lt;P&gt;user_ptr&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; struct userst *[]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [0]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using the memory browser I can see I have entries, and my code sees them properly too.&amp;nbsp; It would be nice to see the pointers in debug, even better to see the structures.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is KDS3.2 with the latest updates using a MK22FX512&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Aug 2017 05:58:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701378#M9169</guid>
      <dc:creator>michaelhuslig</dc:creator>
      <dc:date>2017-08-18T05:58:34Z</dc:date>
    </item>
    <item>
      <title>Re: Debugging an array of pointers to structures</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701379#M9170</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello ,&lt;/P&gt;&lt;P&gt;Could you please show your project to let's see your code in detail .&lt;/P&gt;&lt;P&gt;Then I can debug it on my side to check .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BR&lt;/P&gt;&lt;P&gt;Alice&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Aug 2017 07:36:05 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701379#M9170</guid>
      <dc:creator>Alice_Yang</dc:creator>
      <dc:date>2017-08-18T07:36:05Z</dc:date>
    </item>
    <item>
      <title>Re: Debugging an array of pointers to structures</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701380#M9171</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Alice,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I forgot to mention that I am using PE micro's Multilink Universal.&amp;nbsp; Is &lt;/P&gt;&lt;P&gt;this something to do with the gdb server?&amp;nbsp; How much of my project would &lt;/P&gt;&lt;P&gt;you need.&amp;nbsp; Wouldn't you need my custom board in order to see what I am &lt;/P&gt;&lt;P&gt;seeing?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mike H.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Aug 2017 21:18:38 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701380#M9171</guid>
      <dc:creator>michaelhuslig</dc:creator>
      <dc:date>2017-08-18T21:18:38Z</dc:date>
    </item>
    <item>
      <title>Re: Debugging an array of pointers to structures</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701381#M9172</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&amp;nbsp; Michael,&lt;/P&gt;&lt;P&gt;I just want to know detail what information you want to see.&lt;/P&gt;&lt;P&gt;Usually we check variable on ''Expressions " view of KDS you also mentioned :&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_2.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/27384i3E3F44BC956A52E9/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_2.png" alt="pastedImage_2.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;If you want to check variable when the program on board is running, you can refer to this thread :&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://mcuoneclipse.com/2015/07/14/automatic-variable-expression-and-memory-display-with-gdb-and-eclipse/" title="https://mcuoneclipse.com/2015/07/14/automatic-variable-expression-and-memory-display-with-gdb-and-eclipse/"&gt;Automatic Variable, Expression and Memory Display with GDB and Eclipse | MCU on Eclipse&lt;/A&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;TIC&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>Mon, 21 Aug 2017 02:44:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701381#M9172</guid>
      <dc:creator>Alice_Yang</dc:creator>
      <dc:date>2017-08-21T02:44:46Z</dc:date>
    </item>
    <item>
      <title>Re: Debugging an array of pointers to structures</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701382#M9173</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Michael,&lt;/P&gt;&lt;P&gt;which debug probe you are using should not be relevant.&lt;/P&gt;&lt;P&gt;I tried to reproduce your problem, but works for me:&lt;/P&gt;&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper" image-alt="pastedImage_1.png"&gt;&lt;IMG alt="pastedImage_1.png" src="https://community.nxp.com/t5/image/serverpage/image-id/26922iD4E7159D29A0E035/image-size/large?v=v2&amp;amp;px=999" title="pastedImage_1.png" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I used the following:&lt;/P&gt;&lt;PRE class="language-c line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="property macro token"&gt;#define MAXUSERS 3&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;typedef&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;struct&lt;/SPAN&gt; userst &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
&amp;nbsp; &lt;SPAN class="keyword token"&gt;int&lt;/SPAN&gt; a&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt; userst&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;struct&lt;/SPAN&gt; userst a&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; b&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; c&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;struct&lt;/SPAN&gt; userst&lt;SPAN class="operator token"&gt;*&lt;/SPAN&gt; user_ptr&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;MAXUSERS&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;What is really needed is a piece of code to reproduce what you see.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this helps,&lt;/P&gt;&lt;P&gt;Erich&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Nov 2020 14:00:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701382#M9173</guid>
      <dc:creator>BlackNight</dc:creator>
      <dc:date>2020-11-02T14:00:11Z</dc:date>
    </item>
    <item>
      <title>Re: Debugging an array of pointers to structures</title>
      <link>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701383#M9174</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Erich,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My structures were a lot more complicated.&amp;nbsp; I ended up declaring &lt;/P&gt;&lt;P&gt;individual array pointers and assigning them the same values in the &lt;/P&gt;&lt;P&gt;array.&amp;nbsp; This way I was able to examine the selected structures I needed &lt;/P&gt;&lt;P&gt;in debug.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mike H.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Aug 2017 08:03:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Design-Studio/Debugging-an-array-of-pointers-to-structures/m-p/701383#M9174</guid>
      <dc:creator>michaelhuslig</dc:creator>
      <dc:date>2017-08-24T08:03:15Z</dc:date>
    </item>
  </channel>
</rss>

