<?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: Data Serialization in S32K</title>
    <link>https://community.nxp.com/t5/S32K/Data-Serialization/m-p/713067#M1558</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;BR /&gt;I had to modify this comment.&lt;BR /&gt;DSB instruction serialize all explicit memory accesses.&lt;BR /&gt;But it doesn’t serialize peripheral writes, in this case, we need to&amp;nbsp;do&amp;nbsp;Read-After-Write sequence to be sure the writes are complete before we can proceed with execution of subsequent instructions.&amp;nbsp;We can use ISB instruction to flush the pipeline if needed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;BR /&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 13 Sep 2017 21:23:57 GMT</pubDate>
    <dc:creator>danielmartynek</dc:creator>
    <dc:date>2017-09-13T21:23:57Z</dc:date>
    <item>
      <title>Data Serialization</title>
      <link>https://community.nxp.com/t5/S32K/Data-Serialization/m-p/713066#M1557</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am working on data serialization with S32K142/144 micro controller . I am using this&amp;nbsp; controller for CAN specific applications. And in which i realized "data serialization " should restrictively followed .&lt;/P&gt;&lt;P&gt;So,i have gone thorough alot-off&amp;nbsp; posts and documentations.&lt;/P&gt;&lt;P&gt;after all i have still one doubt , as for any peripheral resister access , we should follow "read after write".&lt;/P&gt;&lt;P&gt;As in below example, during accessing of &lt;STRONG&gt;LPTMR0_CSR&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;void lptmr_isr(void)&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;&amp;nbsp; // Declare dummy variable to store the read of the LPTMR0_CSR register&lt;/P&gt;&lt;P&gt;volatile int dummy_var&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt; /****&amp;nbsp;&amp;nbsp; STEP #1&amp;nbsp; ****/&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; // Clear the flag; enable interrupts; enable the timer&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; LPTMR0_CSR = ( LPTMR_CSR_TEN_MASK | LPTMR_CSR_TIE_MASK | LPTMR_CSR_TCF_MASK&amp;nbsp; );&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;STRONG&gt;/****&amp;nbsp; STEP #2&amp;nbsp; ****/&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp; // Store CSR register in dummy_var to serialize the clearing of the TCF flag &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; dummy_var = LPTMR0_CSR;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;But,&lt;/P&gt;&lt;P&gt;1. can we use just memory barrier instruction &lt;STRONG&gt;__asm("dsb");&lt;/STRONG&gt; in place of "&lt;STRONG&gt;dummy_var = LPTMR0_CSR;&lt;/STRONG&gt;" instruction ?&lt;/P&gt;&lt;P&gt;2. Is could you please give few example of real time use of&amp;nbsp; &lt;STRONG&gt;__asm("dmb"); &lt;STRONG&gt;__asm("dsb");&lt;/STRONG&gt; &lt;STRONG&gt;__asm("isb");&lt;/STRONG&gt;&lt;/STRONG&gt; .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please help me on this.&lt;/P&gt;&lt;P&gt;Thankyou!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Aug 2017 18:56:30 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Data-Serialization/m-p/713066#M1557</guid>
      <dc:creator>yashkumar</dc:creator>
      <dc:date>2017-08-31T18:56:30Z</dc:date>
    </item>
    <item>
      <title>Re: Data Serialization</title>
      <link>https://community.nxp.com/t5/S32K/Data-Serialization/m-p/713067#M1558</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;BR /&gt;I had to modify this comment.&lt;BR /&gt;DSB instruction serialize all explicit memory accesses.&lt;BR /&gt;But it doesn’t serialize peripheral writes, in this case, we need to&amp;nbsp;do&amp;nbsp;Read-After-Write sequence to be sure the writes are complete before we can proceed with execution of subsequent instructions.&amp;nbsp;We can use ISB instruction to flush the pipeline if needed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;BR /&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Sep 2017 21:23:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Data-Serialization/m-p/713067#M1558</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2017-09-13T21:23:57Z</dc:date>
    </item>
  </channel>
</rss>

