<?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: MQX 4.0 lwevent problem in MQX Software Solutions</title>
    <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-0-lwevent-problem/m-p/448655#M15025</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sebastian,&lt;/P&gt;&lt;P&gt;Two things come to mind.&lt;/P&gt;&lt;P&gt;1) make sure your task priorities are 8 and higher.&amp;nbsp; Lower priority numbers are reserved for the RTOS and I have seen where a user task at wrong priority can make the lwevent have issues.&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2) Upgrade....KSDK_1.3 (&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://www.freescale.com/ksdk" rel="nofollow"&gt;http://www.freescale.com/ksdk&lt;/A&gt;&lt;SPAN&gt;) and see if this fixes issue.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;David&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 09 Oct 2015 20:15:10 GMT</pubDate>
    <dc:creator>DavidS</dc:creator>
    <dc:date>2015-10-09T20:15:10Z</dc:date>
    <item>
      <title>MQX 4.0 lwevent problem</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-0-lwevent-problem/m-p/448654#M15024</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello I am using MQX 4.0 with KSDK 1.2.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Basically I have a task that is performing "_lwevent_wait_for(&amp;amp;evento_entrada, 0x1, TRUE, NULL);"&lt;/P&gt;&lt;P&gt;The event is created by the same task with "_lwevent_create(&amp;amp;evento_entrada,LWEVENT_AUTO_CLEAR);"&lt;/P&gt;&lt;P&gt;The event is being set by a GPIO in an interrupt with "_lwevent_set(&amp;amp;evento_entrada, 0x01);"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is that at beginning the code works correctly, but later with a random number of interrupts by the GPIO, it start an infinite loop where the task is not being blocked when actually the event is not set. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here I attach a screenshot where you can see the problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sebastian.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="error lwevent.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/58840i6AEFA22D9D64EAA2/image-size/large?v=v2&amp;amp;px=999" role="button" title="error lwevent.png" alt="error lwevent.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Oct 2015 14:28:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-0-lwevent-problem/m-p/448654#M15024</guid>
      <dc:creator>sebastianzubiau</dc:creator>
      <dc:date>2015-10-09T14:28:27Z</dc:date>
    </item>
    <item>
      <title>Re: MQX 4.0 lwevent problem</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-0-lwevent-problem/m-p/448655#M15025</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sebastian,&lt;/P&gt;&lt;P&gt;Two things come to mind.&lt;/P&gt;&lt;P&gt;1) make sure your task priorities are 8 and higher.&amp;nbsp; Lower priority numbers are reserved for the RTOS and I have seen where a user task at wrong priority can make the lwevent have issues.&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2) Upgrade....KSDK_1.3 (&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://www.freescale.com/ksdk" rel="nofollow"&gt;http://www.freescale.com/ksdk&lt;/A&gt;&lt;SPAN&gt;) and see if this fixes issue.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;David&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Oct 2015 20:15:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-0-lwevent-problem/m-p/448655#M15025</guid>
      <dc:creator>DavidS</dc:creator>
      <dc:date>2015-10-09T20:15:10Z</dc:date>
    </item>
    <item>
      <title>Re: MQX 4.0 lwevent problem</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-0-lwevent-problem/m-p/448656#M15026</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks David. I checked the task priorities and all was fine.&lt;/P&gt;&lt;P&gt;I discovered that the problem happen when I use the function "UART_DRV_SendDataBlocking(uint32_t instance, const uint8_t * txBuff, uint32_t txSize, uint32_t timeout)"&lt;/P&gt;&lt;P&gt;So I changed it with the non-blocking one. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now I need to receive from UART in a blocking way and it seems to work corecctly but in a certain moment the task is being blocked waiting for the semaphore and the timeout don't unblock it. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I use "UART_DRV_ReceiveDataBlocking(uint32_t instance, uint8_t * rxBuff, uint32_t rxSize, uint32_t timeout)"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Did you ever hear of that?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 13 Oct 2015 15:56:58 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-0-lwevent-problem/m-p/448656#M15026</guid>
      <dc:creator>sebastianzubiau</dc:creator>
      <dc:date>2015-10-13T15:56:58Z</dc:date>
    </item>
  </channel>
</rss>

