<?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: OnBlockSent Event functions still returning BUSY? in Processor Expert Software</title>
    <link>https://community.nxp.com/t5/Processor-Expert-Software/OnBlockSent-Event-functions-still-returning-BUSY/m-p/211931#M927</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was informed that this is a known problem that should be already fixed in CodeWarrior 10.3.&lt;/P&gt;&lt;P&gt;You are probably using older version. Please install the CW10.3, it's already available at Freescale website.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;best regards&lt;/P&gt;&lt;P&gt;Petr Hradsky&lt;/P&gt;&lt;P&gt;Processor Expert Support Team&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 02 Jan 2013 15:59:32 GMT</pubDate>
    <dc:creator>Petr_H</dc:creator>
    <dc:date>2013-01-02T15:59:32Z</dc:date>
    <item>
      <title>OnBlockSent Event functions still returning BUSY?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/OnBlockSent-Event-functions-still-returning-BUSY/m-p/211930#M926</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;We have code for a circular buffer that we're using for printf, and we were hoping to make it interrupt driven. What I noticed is that the PE Serial functions (and other functions that use the SendBlock methods) don't look to reset their state until after going through the interrupt a second time.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For UART modules, what this means is that calling &amp;lt;device&amp;gt;_SendBlock while within the interrupt will still return ERR_BUSY even though the block has already been sent.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To make our own version of an interrupt driven buffer, does PE have any way of working, or would we need to rewrite the PE code to enable us to use UART interrupts directly?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Relevant code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;static void InterruptTx(AS1_TDeviceDataPtr DeviceDataPrv)&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;{&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp; if (DeviceDataPrv-&amp;gt;OutSentDataNum &amp;lt; DeviceDataPrv-&amp;gt;OutDataNumReq) { /* Is number of sent characters less than the number of requested incoming characters? */&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; UART_PDD_PutChar8(UART3_BASE_PTR, *(DeviceDataPrv-&amp;gt;OutDataPtr++)); /* Put a 8-bit character to the transmit register */&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DeviceDataPrv-&amp;gt;OutSentDataNum++;&amp;nbsp;&amp;nbsp; /* Increment the counter of sent characters. */&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (DeviceDataPrv-&amp;gt;OutSentDataNum == DeviceDataPrv-&amp;gt;OutDataNumReq) {&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AS1_OnBlockSent(DeviceDataPrv-&amp;gt;UserDataPtr);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp; } else {&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; UART_PDD_DisableInterrupt(UART3_BASE_PTR, UART_PDD_INTERRUPT_TRANSMITTER); /* Disable TX interrupt */&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DeviceDataPrv-&amp;gt;SerFlag &amp;amp;= (uint16_t)(~(uint16_t)ENABLED_TX_INT); /* Clear the flag ENABLED_TX_INT */&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DeviceDataPrv-&amp;gt;OutDataNumReq = 0x00U; /* Clear the counter of characters to be send by SendBlock() */&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-size: 8pt;"&gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;/P&gt;&lt;P&gt;You can see how the OnBlockSent code won't reset until OutDataNumReq resets. Any thoughts?&lt;/P&gt;&lt;P&gt;&lt;SPAN class="mce_paste_marker"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Dec 2012 14:20:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/OnBlockSent-Event-functions-still-returning-BUSY/m-p/211930#M926</guid>
      <dc:creator>Jeinstei</dc:creator>
      <dc:date>2012-12-18T14:20:33Z</dc:date>
    </item>
    <item>
      <title>Re: OnBlockSent Event functions still returning BUSY?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/OnBlockSent-Event-functions-still-returning-BUSY/m-p/211931#M927</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was informed that this is a known problem that should be already fixed in CodeWarrior 10.3.&lt;/P&gt;&lt;P&gt;You are probably using older version. Please install the CW10.3, it's already available at Freescale website.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;best regards&lt;/P&gt;&lt;P&gt;Petr Hradsky&lt;/P&gt;&lt;P&gt;Processor Expert Support Team&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Jan 2013 15:59:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/OnBlockSent-Event-functions-still-returning-BUSY/m-p/211931#M927</guid>
      <dc:creator>Petr_H</dc:creator>
      <dc:date>2013-01-02T15:59:32Z</dc:date>
    </item>
  </channel>
</rss>

