<?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: How to transmit data using SPI in simulink?  (S32K148EVB) in Model-Based Design Toolbox (MBDT)</title>
    <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/How-to-transmit-data-using-SPI-in-simulink-S32K148EVB/m-p/1011501#M4058</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/sfard@multimatic.com"&gt;sfard@multimatic.com&lt;/A&gt;‌,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All the blocks that you add generate code for one / more of the following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- initialization - code that is ran 1 time, at the beginning&lt;/P&gt;&lt;P&gt;- step - code that is ran continuously, at every step period - you can control this for every model - so to answer your question, as long as you have code that is generated inside the step function, if you want it to be called at frequency &lt;STRONG&gt;f&amp;nbsp;&lt;/STRONG&gt;you should set the step size to&amp;nbsp;&lt;STRONG&gt;1/f&lt;/STRONG&gt;, so 1e-6 would be right [Note: this step function is controlled via a LPIT channel]&lt;/P&gt;&lt;P&gt;- interrupts - ISR blocks generate functions that are called on certain events, and only then -- so event-driven code here [Note:&amp;nbsp;code generated for the subsystem that is triggered by the ISR block goes inside these functions]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As for why it does not seem to work, I'll take a look and get back to you tomorrow as I'm working through my queue - but I decided to give a very short description to know what to expect from our toolbox.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please let us know if you have other questions regarding the toolbox functionality.&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>Tue, 19 Nov 2019 14:28:37 GMT</pubDate>
    <dc:creator>constantinrazva</dc:creator>
    <dc:date>2019-11-19T14:28:37Z</dc:date>
    <item>
      <title>How to transmit data using SPI in simulink?  (S32K148EVB)</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/How-to-transmit-data-using-SPI-in-simulink-S32K148EVB/m-p/1011500#M4057</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;I am very new to NXP model-based design toolbox. I am trying to communicate with an accelerometer which has an SPI interface; however I have a hard time to send a signal to the slave. I created the attached model, but when I checked the MOSI signal on a Logic Analyzer, the signal&amp;nbsp;is not what I am trying to send.&lt;/P&gt;&lt;P&gt;My other question is about the step size of the model. If I want to send the signal at 1MHZ to the salve, does it mean that I should reduce the step size of the Simulink model to 1e-6?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_1.jpg"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/94518i3864F4A0332AB64D/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_1.jpg" alt="pastedImage_1.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Nov 2019 13:46:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/How-to-transmit-data-using-SPI-in-simulink-S32K148EVB/m-p/1011500#M4057</guid>
      <dc:creator>sfard</dc:creator>
      <dc:date>2019-11-19T13:46:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to transmit data using SPI in simulink?  (S32K148EVB)</title>
      <link>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/How-to-transmit-data-using-SPI-in-simulink-S32K148EVB/m-p/1011501#M4058</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/sfard@multimatic.com"&gt;sfard@multimatic.com&lt;/A&gt;‌,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All the blocks that you add generate code for one / more of the following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- initialization - code that is ran 1 time, at the beginning&lt;/P&gt;&lt;P&gt;- step - code that is ran continuously, at every step period - you can control this for every model - so to answer your question, as long as you have code that is generated inside the step function, if you want it to be called at frequency &lt;STRONG&gt;f&amp;nbsp;&lt;/STRONG&gt;you should set the step size to&amp;nbsp;&lt;STRONG&gt;1/f&lt;/STRONG&gt;, so 1e-6 would be right [Note: this step function is controlled via a LPIT channel]&lt;/P&gt;&lt;P&gt;- interrupts - ISR blocks generate functions that are called on certain events, and only then -- so event-driven code here [Note:&amp;nbsp;code generated for the subsystem that is triggered by the ISR block goes inside these functions]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As for why it does not seem to work, I'll take a look and get back to you tomorrow as I'm working through my queue - but I decided to give a very short description to know what to expect from our toolbox.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please let us know if you have other questions regarding the toolbox functionality.&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>Tue, 19 Nov 2019 14:28:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Model-Based-Design-Toolbox-MBDT/How-to-transmit-data-using-SPI-in-simulink-S32K148EVB/m-p/1011501#M4058</guid>
      <dc:creator>constantinrazva</dc:creator>
      <dc:date>2019-11-19T14:28:37Z</dc:date>
    </item>
  </channel>
</rss>

