<?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>Model-Based Design Toolbox (MBDT)のトピックRe: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
    <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637288#M142</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Eden Li,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I guess you are trying to avoid using the NXP Math library and implement the same equations by using Simulink Standard block.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your Model3.zip have at least 2 caveats that prevents you for getting the same result as the NXP library:&lt;/P&gt;&lt;P&gt;#1: you are passing wrong arguments to the NXP library: you should pass the inductance LQ/LD&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="1.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17378i86A4B08FB9EF04F6/image-size/large?v=v2&amp;amp;px=999" role="button" title="1.JPG" alt="1.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;#2: you are implementing a slightly different equations than the one used in the NXP decoupling library&amp;nbsp;&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/17453iA220A111FE03F273/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;/P&gt;&lt;P&gt;Disclaimer: Just to be clear for everyone that might read this topic in the future and also&amp;nbsp;trying to avoid a custom&amp;nbsp;model only - i revert the models to be generic and in sync with the NXP library examples (to have a reference to compare with.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Therefore, please find attached to models: one in floating point and the other one in fixed point with scaling [-1, 1) &amp;nbsp;32b Simulink implementation to address this issue.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Decoupling_FLT is a simple one implemented in floating point:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="3.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17496i6D91854A8E06D773/image-size/large?v=v2&amp;amp;px=999" role="button" title="3.JPG" alt="3.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;You should get these results when running with default inputs shown in the UserGuide:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="4.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17544i788873624BEBCC0D/image-size/large?v=v2&amp;amp;px=999" role="button" title="4.JPG" alt="4.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Decoupling_F32 is more complex since it is using scaling and math operations on 32bits&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="6.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17586i8F45EC238F00065B/image-size/large?v=v2&amp;amp;px=999" role="button" title="6.JPG" alt="6.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Running for the same inputs you should get the following results:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="7.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17497iFF89996E76BE19AD/image-size/large?v=v2&amp;amp;px=999" role="button" title="7.JPG" alt="7.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this clarify all the concerns related with this topic.&lt;/P&gt;&lt;P&gt;Best regards,&lt;BR /&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 01 May 2017 12:32:12 GMT</pubDate>
    <dc:creator>Daniel_Popa</dc:creator>
    <dc:date>2017-05-01T12:32:12Z</dc:date>
    <item>
      <title>Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637278#M132</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;@&lt;/P&gt;&lt;P&gt;Hi,Guys,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; Iwanna use the&amp;nbsp;GMCLIB_DecouplingPMSM in MCLIB for MPC564xL to PMSM contorl ,But,the Parameter s32Kd,s32Kq of the&amp;nbsp;&lt;SPAN&gt;GMCLIB_DecouplingPMSM block in Simulink，I don't know how to caculate the&amp;nbsp;s32Kd and&amp;nbsp;&lt;SPAN&gt;s32Kq.&lt;/SPAN&gt;&lt;/SPAN&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/12951i831AC21593470CB1/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;&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/13074i2A1ED3AC4A1AEF24/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;I caculated the parameter of the f16Kd and f16kq,but the result is not 0.625 as the file "MPC564XLMCLUG.pdf" shows.I caculate the result is&amp;nbsp;&lt;SPAN&gt; f16Kd=40,f16kq=20;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;My caculation &lt;SPAN style="color: #666666; background-color: rgba(255, 255, 255, 0.8); font-size: 12.000000953674316px;"&gt;equation&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/13110iD1F772CE6B5BA367/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;P&gt;and ,the do we not using the equation?&lt;/P&gt;&lt;P&gt;Thank you very much!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Apr 2017 05:45:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637278#M132</guid>
      <dc:creator>edenli</dc:creator>
      <dc:date>2017-04-24T05:45:01Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637279#M133</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Eden Li,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Back in the dark ages when operations on floating point were very costly most of the DSP programming was done on integers and one of the most used representation was Q15 format used for 16bit native MCU/DSP.&lt;/P&gt;&lt;P&gt;In this format all number are scaled from -1 to 0.9999.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You calculations are correct but you stopped in the middle - you got only the real number for kq and kd&amp;nbsp;coefficients.&lt;/P&gt;&lt;P&gt;Since the computations are carried on fixed point, you need to scale these 2 factors in the range of [-1:1)&lt;/P&gt;&lt;P&gt;This scaling is done in 2 stages.&amp;nbsp;&lt;/P&gt;&lt;P&gt;1: first compute the scaling&amp;nbsp;coefficients: it is basically a shift left proper value&lt;/P&gt;&lt;P&gt;kd_shift = ceil(log(kd)/log(2))&lt;BR /&gt;kq_shift = ceil(log(kq)/log(2))&lt;/P&gt;&lt;P&gt;2: compute the scaled quantities for the coefficients&lt;/P&gt;&lt;P&gt;kdf = kd*2^(-kd_shift)&lt;BR /&gt;kqf = kq*2^(-kq_shift)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using this mathematical trick you ensure the higher computational precision. Basically you can represent a real number as real = (fraction)&amp;lt;&amp;lt;(fraction_shift)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can get details about floating point/fixed point mathematics&lt;A href="https://en.wikipedia.org/wiki/Floating-point_arithmetic"&gt; here&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;For your convenience i made a small m script to compute the factors that you need to use for math computations using the NXP toolbox. Please find it attached:&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Apr 2017 11:22:18 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637279#M133</guid>
      <dc:creator>Daniel_Popa</dc:creator>
      <dc:date>2017-04-24T11:22:18Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637280#M134</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;BTW, this method for scaling floating-fixed can be applicable to many other computations as well. Another typical example might be PI/PID controllers. &amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 25 Apr 2017 09:15:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637280#M134</guid>
      <dc:creator>Daniel_Popa</dc:creator>
      <dc:date>2017-04-25T09:15:37Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637281#M135</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-size: 15px;"&gt;Hi dumitru-daniel.popa,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 15px;"&gt;First,Thank you for your reply,and according to what you said,i built a model using the&amp;nbsp;&lt;SPAN style="color: #51626f; background-color: #ffffff;"&gt;GMCLIB_DecouplingPMSM for &amp;nbsp;the PMSM SVPWM control,As shown in the below,and i upload the attachment.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 15px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_6.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/14243iBBE78016BB503DDE/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_6.png" alt="pastedImage_6.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 15px;"&gt;but the result comparing is the same,i write my analysis is as below,i thought the reason is,but i am not sure,the parameter kdf &amp;amp; kqf.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 15px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_7.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/14334i6F39250FA5BF6F60/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_7.png" alt="pastedImage_7.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 15px;"&gt;the caculation of the two parameter,requring the I_Max ,W_MAX,but i don't know how to confrim the two parameter in the Permanent Magnet Synchronous Machine Block in the simulink,i don't know the pararmeter is right or not,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 15px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_8.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/14141iF9C51E9A3BD0594B/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_8.png" alt="pastedImage_8.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 15px;"&gt;Can you help me analyze the reason?yesterday ,the model has bothered me for a day!&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Apr 2017 02:08:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637281#M135</guid>
      <dc:creator>edenli</dc:creator>
      <dc:date>2017-04-26T02:08:50Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637282#M136</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am sorry,the attatchment is below.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Apr 2017 02:12:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637282#M136</guid>
      <dc:creator>edenli</dc:creator>
      <dc:date>2017-04-26T02:12:03Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637283#M137</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Eden Li,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would love to help you with this model, but unfortunately i do not have the power_lib toolbox license.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you create a standalone model of the Decoupling bloc + the one you plan to design with all the parameters included (flux, Ld, Lq) so that i can run it on my computer for checking ? (like you have done it in the past)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Apr 2017 08:58:38 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637283#M137</guid>
      <dc:creator>Daniel_Popa</dc:creator>
      <dc:date>2017-04-26T08:58:38Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637284#M138</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;I am sorry,i am not very clear about what you said, i thought you wanna express the content,as the attachment .if not right please reply for me.&lt;/P&gt;&lt;P&gt;BTW,How to check the model if you don't have the&amp;nbsp;&lt;SPAN style="color: #666666; background-color: #ffffff; font-size: 14px;"&gt;power_lib toolbox license?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #666666; background-color: #ffffff; font-size: 14px;"&gt;Best regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #666666; background-color: #ffffff; font-size: 14px;"&gt;Eden Li&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Apr 2017 09:52:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637284#M138</guid>
      <dc:creator>edenli</dc:creator>
      <dc:date>2017-04-26T09:52:12Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637285#M139</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Eden Li,&lt;/P&gt;&lt;P&gt;Your model contains blocks from &lt;A href="https://www.mathworks.com/products/simpower.html" style="color: #2989c5; text-decoration: none;"&gt;SimPowerSystems&lt;/A&gt;&lt;SPAN style="color: #242729; background-color: #ffffff;"&gt;&amp;nbsp;toolbox which i do not have a license for - therefore i can't simulate the block so i do not know what results you are expecting for.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="Capture.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17543iE7BEFA6DDE39B052/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.JPG" alt="Capture.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #242729; background-color: #ffffff;"&gt;Please create a simple model for and highlight the differences you need clarification on.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #242729; background-color: #ffffff;"&gt;Ideally would be to have something like the model attached below - if you could modify it to include the variables and the input parameters.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Apr 2017 11:14:59 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637285#M139</guid>
      <dc:creator>Daniel_Popa</dc:creator>
      <dc:date>2017-04-26T11:14:59Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637286#M140</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;Ha,ha,that's my problem complicating the question.Now,i rebuilt a model,shown as below.the Parameter of the PMSM in the attachment.&lt;/P&gt;&lt;P&gt;In the model ,the same input the model,but the result is&amp;nbsp;&lt;SPAN style="color: #434343; background-color: #f2f2f2; font-size: 12px;"&gt;Completely different.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&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/17826iFB5B96EAB48410D9/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_1.png" alt="pastedImage_1.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;As mentioned above,i thought the problem is here,as the picture shown,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&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/17870iB867062568A0A800/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_3.png" alt="pastedImage_3.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I think the value for parameter of the I_MAX and W_MAX is the reason.&amp;nbsp;I don't know &amp;nbsp;that how to caculate the value of the Parameter according the parameter of P,Ld,Lq,flux,Udc.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Best Regards!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Eden Li&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Apr 2017 13:11:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637286#M140</guid>
      <dc:creator>edenli</dc:creator>
      <dc:date>2017-04-26T13:11:34Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637287#M141</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;Help me to solve the&amp;nbsp;question ,if you have the&amp;nbsp;time.haha,Thank you very much!&lt;/P&gt;&lt;P&gt;My friend best regard for you!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 29 Apr 2017 06:55:02 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637287#M141</guid>
      <dc:creator>edenli</dc:creator>
      <dc:date>2017-04-29T06:55:02Z</dc:date>
    </item>
    <item>
      <title>Re: Consulting the using about the GMCLIB_DecouplingPMSM in MCLIB for MPC564xL Simulink Block</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637288#M142</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Eden Li,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I guess you are trying to avoid using the NXP Math library and implement the same equations by using Simulink Standard block.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your Model3.zip have at least 2 caveats that prevents you for getting the same result as the NXP library:&lt;/P&gt;&lt;P&gt;#1: you are passing wrong arguments to the NXP library: you should pass the inductance LQ/LD&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="1.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17378i86A4B08FB9EF04F6/image-size/large?v=v2&amp;amp;px=999" role="button" title="1.JPG" alt="1.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;#2: you are implementing a slightly different equations than the one used in the NXP decoupling library&amp;nbsp;&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/17453iA220A111FE03F273/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;/P&gt;&lt;P&gt;Disclaimer: Just to be clear for everyone that might read this topic in the future and also&amp;nbsp;trying to avoid a custom&amp;nbsp;model only - i revert the models to be generic and in sync with the NXP library examples (to have a reference to compare with.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Therefore, please find attached to models: one in floating point and the other one in fixed point with scaling [-1, 1) &amp;nbsp;32b Simulink implementation to address this issue.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Decoupling_FLT is a simple one implemented in floating point:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="3.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17496i6D91854A8E06D773/image-size/large?v=v2&amp;amp;px=999" role="button" title="3.JPG" alt="3.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;You should get these results when running with default inputs shown in the UserGuide:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="4.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17544i788873624BEBCC0D/image-size/large?v=v2&amp;amp;px=999" role="button" title="4.JPG" alt="4.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Decoupling_F32 is more complex since it is using scaling and math operations on 32bits&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="6.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17586i8F45EC238F00065B/image-size/large?v=v2&amp;amp;px=999" role="button" title="6.JPG" alt="6.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Running for the same inputs you should get the following results:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="7.JPG"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/17497iFF89996E76BE19AD/image-size/large?v=v2&amp;amp;px=999" role="button" title="7.JPG" alt="7.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this clarify all the concerns related with this topic.&lt;/P&gt;&lt;P&gt;Best regards,&lt;BR /&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 May 2017 12:32:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/Consulting-the-using-about-the-GMCLIB-DecouplingPMSM-in-MCLIB/m-p/637288#M142</guid>
      <dc:creator>Daniel_Popa</dc:creator>
      <dc:date>2017-05-01T12:32:12Z</dc:date>
    </item>
  </channel>
</rss>

