<?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: Error During Build (SPI Block) MBD for MPC5744P in Model-Based Design Toolbox (MBDT)</title>
    <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949968#M3603</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello &lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/abhishek.kumar@chassisbrakes.com"&gt;abhishek.kumar@chassisbrakes.com&lt;/A&gt;‌,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There seems to be a problem with a define in the makefile. All problems begin here:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;MPC5744P.h:17064:61: error: expected ')' before '*' token&lt;BR /&gt; #define SPI_0 ((SPI_Type *)SPI_0_BASE)&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will take a look and come back with a fix.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Razvan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 20 Jun 2019 14:56:01 GMT</pubDate>
    <dc:creator>constantinrazva</dc:creator>
    <dc:date>2019-06-20T14:56:01Z</dc:date>
    <item>
      <title>Error During Build (SPI Block) MBD for MPC5744P</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949967#M3602</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear All&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I experienced an error while building a model to Initialize FET Prediver (33937A).&amp;nbsp;&lt;/P&gt;&lt;P&gt;The build error seems to originate while using SPI Block.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have attached the error (MATLAB Diagnostic) in txt file as well as the model.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_1.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/88457i8C055CE10E43E481/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_1.png" alt="pastedImage_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please let me know why this issue seems to be.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Abhishek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Jun 2019 14:40:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949967#M3602</guid>
      <dc:creator>abhishek_kumar1</dc:creator>
      <dc:date>2019-06-20T14:40:42Z</dc:date>
    </item>
    <item>
      <title>Re: Error During Build (SPI Block) MBD for MPC5744P</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949968#M3603</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello &lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/abhishek.kumar@chassisbrakes.com"&gt;abhishek.kumar@chassisbrakes.com&lt;/A&gt;‌,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There seems to be a problem with a define in the makefile. All problems begin here:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;MPC5744P.h:17064:61: error: expected ')' before '*' token&lt;BR /&gt; #define SPI_0 ((SPI_Type *)SPI_0_BASE)&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will take a look and come back with a fix.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Razvan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Jun 2019 14:56:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949968#M3603</guid>
      <dc:creator>constantinrazva</dc:creator>
      <dc:date>2019-06-20T14:56:01Z</dc:date>
    </item>
    <item>
      <title>Re: Error During Build (SPI Block) MBD for MPC5744P</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949969#M3604</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello &lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/abhishek.kumar@chassisbrakes.com"&gt;abhishek.kumar@chassisbrakes.com&lt;/A&gt;‌,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've found the problem:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In MPC5744.h, at line 17064, there is the following define&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;#define SPI_0&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; ((SPI_Type *)SPI_0_BASE)&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;At the same time, in the model you've sent me, the name of the SPI Master transfer block is SPI_0. A variable generated to be used as input/output for that block is named SPI_0, as MATLAB codegen has no idea that it should not use that exact name; it just puts the name of the block there. So this is what is actually going on.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;typedef struct {&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;uint8_T &lt;STRONG&gt;SPI_0&lt;/STRONG&gt;; /* '&amp;lt;S2&amp;gt;/SPI_0' */&lt;BR /&gt;} B_FET_predriver_MC34GD3000;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;void FET_predriver_MC34GD3000(uint8_T rtu_MPC_SPI_Data,&lt;BR /&gt; B_FET_predriver_MC34GD3000 *localB)&lt;BR /&gt;{&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;/* S-Function (spi_mpc574x_master_transfer): '&amp;lt;S2&amp;gt;/SPI_0' */&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;DSPI_UpdateCS(0, 0);&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;DSPI_MasterTransfer(0, &amp;amp;rtu_MPC_SPI_Data,&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;amp;localB-&amp;gt;&lt;STRONG&gt;SPI_0&lt;/STRONG&gt;, 1U);&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;BR /&gt;}&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Took a while to find the culprit, but the fix is simple - just &lt;STRONG&gt;rename&lt;/STRONG&gt; the &lt;STRONG&gt;SPI&lt;/STRONG&gt; &lt;STRONG&gt;Master transfer&lt;/STRONG&gt; &lt;STRONG&gt;block&lt;/STRONG&gt; from SPI_0 to something else (e.g: SPI_zero or SPI_00).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please let me know if you have further issues with it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Razvan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Jun 2019 08:43:31 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949969#M3604</guid>
      <dc:creator>constantinrazva</dc:creator>
      <dc:date>2019-06-21T08:43:31Z</dc:date>
    </item>
    <item>
      <title>Re: Error During Build (SPI Block) MBD for MPC5744P</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949970#M3605</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear&amp;nbsp;&lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/constantinrazvan.chivu"&gt;constantinrazvan.chivu&lt;/A&gt;‌&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Works like a charm.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Abhishek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Jun 2019 08:50:00 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949970#M3605</guid>
      <dc:creator>abhishek_kumar1</dc:creator>
      <dc:date>2019-06-21T08:50:00Z</dc:date>
    </item>
    <item>
      <title>Re: Error During Build (SPI Block) MBD for MPC5744P</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949971#M3606</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Abhishek Kumar,&lt;/P&gt;&lt;P&gt;When I use the MPC57XX MBD toolbox to configure SPI and &lt;SPAN&gt;communicate with&amp;nbsp;&lt;/SPAN&gt;power chip, the data structure required by the power chip is 16-bit, as shown in the figure below, but only the 8-bit data transmission can be configured in the toolbox. Is there any way to solve it?&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/85748i5E9C474564EE96F1/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;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_3.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/86090i9E36E8789F08D86B/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_3.png" alt="pastedImage_3.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Sep 2019 11:33:45 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949971#M3606</guid>
      <dc:creator>lijiantaowy</dc:creator>
      <dc:date>2019-09-16T11:33:45Z</dc:date>
    </item>
    <item>
      <title>Re: Error During Build (SPI Block) MBD for MPC5744P</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949972#M3607</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello &lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/lijiantaowy@163.com"&gt;lijiantaowy@163.com&lt;/A&gt;‌,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have already sent you a response here&amp;nbsp;&lt;A href="https://community.nxp.com/thread/513041"&gt;https://community.nxp.com/thread/513041&lt;/A&gt;&amp;nbsp;.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Marius&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Sep 2019 06:52:49 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Error-During-Build-SPI-Block-MBD-for-MPC5744P/m-p/949972#M3607</guid>
      <dc:creator>mariuslucianand</dc:creator>
      <dc:date>2019-09-23T06:52:49Z</dc:date>
    </item>
  </channel>
</rss>

