<?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 dev_cdc_vcom_lite_bm is not full duplex ? in Processor Expert Software</title>
    <link>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1526990#M5262</link>
    <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Dear all,&lt;/P&gt;&lt;P&gt;I have a LPC55S28-EVK and I tried to install the demo software dev_cdc_vcom_lite_bm.&lt;/P&gt;&lt;P&gt;It works perfecyly but .... it seems that is half fuplex VCOM port.&lt;/P&gt;&lt;P&gt;I connected to a PC via USB the board and, usin putty program, I'm able to send chars to the board and receive chars from it.&lt;/P&gt;&lt;P&gt;Unfortunately if I wnat only send chars to the board and I don't wont to receive anithyng from it the putty software stop working.&lt;/P&gt;&lt;P&gt;I commented out the lines from 767 to 777 in the file virtual_com.c&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;       if ((0 != s_recvSize) &amp;amp;&amp;amp; (USB_CANCELLED_TRANSFER_LENGTH != s_recvSize))
        {
            int32_t i;

            /* Copy Buffer to Send Buff */
            for (i = 0; i &amp;lt; s_recvSize; i++)
            {
                s_currSendBuf[s_sendSize++] = s_currRecvBuf[i];
            }
            s_recvSize = 0;
        }

//        if (s_sendSize)
//        {
//            uint32_t size = s_sendSize;
//            s_sendSize    = 0;
//
//            error = USB_DeviceSendRequest(s_cdcVcom.deviceHandle, USB_CDC_VCOM_BULK_IN_ENDPOINT, s_currSendBuf, size);
//
//            if (error != kStatus_USB_Success)
//            {
//                /* Failure to send Data Handling code here */
//            }
//        }&lt;/LI-CODE&gt;&lt;P&gt;so the software is able to receive messages from USB connection but it can't trasmit messages.&lt;/P&gt;&lt;P&gt;Than I recompile the project and I enter in debug mode.&lt;/P&gt;&lt;P&gt;I connect the USB port of the board to USB port of a computer and I run the demo USB software. The computer recognize the board as COM device.&lt;/P&gt;&lt;P&gt;Using putty program I press a key on the keyboard that the board receives correctly but if I press any other ket on the keyboard of the PC no other char is received from tha board.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Did you have any simnilar problem ? how did you fixed it ?&lt;/P&gt;&lt;P&gt;thank you very much for your help and cooperation&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 22 Sep 2022 22:00:45 GMT</pubDate>
    <dc:creator>_Ferrari_</dc:creator>
    <dc:date>2022-09-22T22:00:45Z</dc:date>
    <item>
      <title>dev_cdc_vcom_lite_bm is not full duplex ?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1526990#M5262</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Dear all,&lt;/P&gt;&lt;P&gt;I have a LPC55S28-EVK and I tried to install the demo software dev_cdc_vcom_lite_bm.&lt;/P&gt;&lt;P&gt;It works perfecyly but .... it seems that is half fuplex VCOM port.&lt;/P&gt;&lt;P&gt;I connected to a PC via USB the board and, usin putty program, I'm able to send chars to the board and receive chars from it.&lt;/P&gt;&lt;P&gt;Unfortunately if I wnat only send chars to the board and I don't wont to receive anithyng from it the putty software stop working.&lt;/P&gt;&lt;P&gt;I commented out the lines from 767 to 777 in the file virtual_com.c&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;       if ((0 != s_recvSize) &amp;amp;&amp;amp; (USB_CANCELLED_TRANSFER_LENGTH != s_recvSize))
        {
            int32_t i;

            /* Copy Buffer to Send Buff */
            for (i = 0; i &amp;lt; s_recvSize; i++)
            {
                s_currSendBuf[s_sendSize++] = s_currRecvBuf[i];
            }
            s_recvSize = 0;
        }

//        if (s_sendSize)
//        {
//            uint32_t size = s_sendSize;
//            s_sendSize    = 0;
//
//            error = USB_DeviceSendRequest(s_cdcVcom.deviceHandle, USB_CDC_VCOM_BULK_IN_ENDPOINT, s_currSendBuf, size);
//
//            if (error != kStatus_USB_Success)
//            {
//                /* Failure to send Data Handling code here */
//            }
//        }&lt;/LI-CODE&gt;&lt;P&gt;so the software is able to receive messages from USB connection but it can't trasmit messages.&lt;/P&gt;&lt;P&gt;Than I recompile the project and I enter in debug mode.&lt;/P&gt;&lt;P&gt;I connect the USB port of the board to USB port of a computer and I run the demo USB software. The computer recognize the board as COM device.&lt;/P&gt;&lt;P&gt;Using putty program I press a key on the keyboard that the board receives correctly but if I press any other ket on the keyboard of the PC no other char is received from tha board.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Did you have any simnilar problem ? how did you fixed it ?&lt;/P&gt;&lt;P&gt;thank you very much for your help and cooperation&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 22 Sep 2022 22:00:45 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1526990#M5262</guid>
      <dc:creator>_Ferrari_</dc:creator>
      <dc:date>2022-09-22T22:00:45Z</dc:date>
    </item>
    <item>
      <title>Re: dev_cdc_vcom_lite_bm is not full duplex ?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1528051#M5269</link>
      <description>&lt;P&gt;Hello ,&lt;/P&gt;
&lt;P&gt;How about do not comment out the lines you mentioned,&amp;nbsp; while set a breakpoint with if received data :&lt;/P&gt;
&lt;PRE class="lia-code-sample  language-markup"&gt;&lt;CODE&gt;   s_currSendBuf[s_sendSize++] = s_currRecvBuf[i];&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;Alice&lt;/P&gt;</description>
      <pubDate>Mon, 26 Sep 2022 09:32:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1528051#M5269</guid>
      <dc:creator>Alice_Yang</dc:creator>
      <dc:date>2022-09-26T09:32:27Z</dc:date>
    </item>
    <item>
      <title>Re: dev_cdc_vcom_lite_bm is not full duplex ?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1528199#M5270</link>
      <description>&lt;P&gt;Dear Alice,&lt;/P&gt;&lt;P&gt;thank you for your reply.&lt;/P&gt;&lt;P&gt;You suggested to comment out the line&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;s_currSendBuf[s_sendSize++] = s_currRecvBuf[i];&lt;/LI-CODE&gt;&lt;P&gt;but I think that the result doesn't change because if I comment out the line that you have suggested, the value variable s_sendSize will be 0 (zero) so the lines that I commented out&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;        if (s_sendSize)
        {
            uint32_t size = s_sendSize;
            s_sendSize    = 0;

            error = USB_DeviceSendRequest(s_cdcVcom.deviceHandle, USB_CDC_VCOM_BULK_IN_ENDPOINT, s_currSendBuf, size);

            if (error != kStatus_USB_Success)
            {
                /* Failure to send Data Handling code here */
            }
        }&lt;/LI-CODE&gt;&lt;P&gt;will be never executed&lt;/P&gt;&lt;P&gt;thank you for your help and cooperation&lt;/P&gt;&lt;P&gt;best regards&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 26 Sep 2022 14:12:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1528199#M5270</guid>
      <dc:creator>_Ferrari_</dc:creator>
      <dc:date>2022-09-26T14:12:22Z</dc:date>
    </item>
    <item>
      <title>Re: dev_cdc_vcom_lite_bm is not full duplex ?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1531003#M5276</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;"&lt;/P&gt;
&lt;P&gt;You suggested to comment out the line&lt;/P&gt;
&lt;PRE class="lia-code-sample  language-markup"&gt;&lt;CODE&gt;s_currSendBuf[s_sendSize++] = s_currRecvBuf[i];&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;"&lt;/P&gt;
&lt;P&gt;-&amp;gt;&amp;gt; No,&amp;nbsp; I mean set a breakpoint on here, and do no change any code.&lt;/P&gt;
&lt;P&gt;Because you said board can receive and send data, while comment out send, the receive can't work.&lt;/P&gt;
&lt;P&gt;So suggest you stop the project at receive step, check whether received data.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;Alice&lt;/P&gt;</description>
      <pubDate>Fri, 30 Sep 2022 09:17:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1531003#M5276</guid>
      <dc:creator>Alice_Yang</dc:creator>
      <dc:date>2022-09-30T09:17:26Z</dc:date>
    </item>
    <item>
      <title>Re: dev_cdc_vcom_lite_bm is not full duplex ?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1531624#M5277</link>
      <description>&lt;P&gt;Dear Alice,&lt;/P&gt;&lt;P&gt;thank you for you reply.&lt;/P&gt;&lt;P&gt;I have to develope a project that receives and transmits data from USB port. I have three cases:&lt;/P&gt;&lt;P&gt;a) The application has to receive and send data&lt;/P&gt;&lt;P&gt;b) The application only has to receive data (it doesn't transmit anything)&lt;/P&gt;&lt;P&gt;c) The application only has to transmit data (it doesn't receive anything)&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;I'm using LPC55S28-EVK and MCUXpresso IDE v11.5.1 [Build 7266] [2022-04-13]&lt;/P&gt;&lt;P&gt;I started from the sdk example dev_cdc_vcom_bm and I connected the USB port of PC to the board via 'full speed' USB port. Using PuTTY software I can send and receive chars to and from theboard and it works fine: Case a) is OK.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Than I commented out the lines from 630 to 639 of the file virtual_com.c&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;     if ((0 != s_recvSize) &amp;amp;&amp;amp; (USB_CANCELLED_TRANSFER_LENGTH != s_recvSize))
        {
            int32_t i;

            /* Copy Buffer to Send Buff */
            for (i = 0; i &amp;lt; s_recvSize; i++)
            {
                s_currSendBuf[s_sendSize++] = s_currRecvBuf[i];
            }
            s_recvSize = 0;
        }
#if 0
        if (s_sendSize)
        {
            uint32_t size = s_sendSize;
            s_sendSize    = 0;

            error = USB_DeviceCdcAcmSend(s_cdcVcom.cdcAcmHandle, USB_CDC_VCOM_BULK_IN_ENDPOINT, s_currSendBuf, size);

            if (error != kStatus_USB_Success)
            {
                /* Failure to send Data Handling code here */
            }
        }
#endif&lt;/LI-CODE&gt;&lt;P&gt;in order to simulate the case b)&lt;/P&gt;&lt;P&gt;I set a breakpoint on the line 632 as you suggested in your previouse post&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;s_currSendBuf[s_sendSize++] = s_currRecvBuf[i];&lt;/LI-CODE&gt;&lt;P&gt;Then I started PuTTY software and I typed one key on the PC keyboard. The software stops at the brackpoint and the the s_recvSize is equale 1. The received char on the first position of s_currRecvBuf is 'a' (I typed 'a' on the PC keyboard).&lt;/P&gt;&lt;P&gt;Than I clicked on the 'Resume' icon of the MCUXpresso IDE software to continue the debug.&lt;/P&gt;&lt;P&gt;Than I typed another char ('b') on the PC keyboard but the software doesn't stop at the breakcpoint: the character 'b' is not received. Case b) does'nt work.&lt;/P&gt;&lt;P&gt;Than I modified the virtual_com.c file as follow:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;     /* endpoint callback length is USB_CANCELLED_TRANSFER_LENGTH (0xFFFFFFFFU) when transfer is canceled */
#if 0
        if ((0 != s_recvSize) &amp;amp;&amp;amp; (USB_CANCELLED_TRANSFER_LENGTH != s_recvSize))
        {
            int32_t i;

            /* Copy Buffer to Send Buff */
            for (i = 0; i &amp;lt; s_recvSize; i++)
            {
                s_currSendBuf[s_sendSize++] = s_currRecvBuf[i];
            }
            s_recvSize = 0;
        }
#endif
        s_currSendBuf[0]='a';
        s_currSendBuf[1]='b';
        s_currSendBuf[2]=' ';
        s_sendSize=3;
        if (s_sendSize)
        {
            uint32_t size = s_sendSize;
            s_sendSize    = 0;

            error = USB_DeviceCdcAcmSend(s_cdcVcom.cdcAcmHandle, USB_CDC_VCOM_BULK_IN_ENDPOINT, s_currSendBuf, size);

            if (error != kStatus_USB_Success)
            {
                /* Failure to send Data Handling code here */
            }
        }&lt;/LI-CODE&gt;&lt;P&gt;in order to simulate the 'Case c) (the application transmits but doesn't receive)&lt;/P&gt;&lt;P&gt;As usual I used the PuTTY software and I noticed that the string 'ab ' is correctly transmited and received by the PC: case c) is OK.&lt;/P&gt;&lt;P&gt;Just for summaty:&lt;BR /&gt;a) The application has to receive and send data: It works.&lt;/P&gt;&lt;P&gt;b) The application only has to receive data (it doesn't transmit anything): It doesn't work.&lt;/P&gt;&lt;P&gt;c) The application only has to transmit data (it doesn't receive anything): It works.&lt;/P&gt;&lt;P&gt;Did yoy have any similar problem ?&lt;BR /&gt;How did you fixed it ?&lt;/P&gt;&lt;P&gt;Thank you for your help and cooperation&lt;BR /&gt;regards&lt;/P&gt;</description>
      <pubDate>Mon, 03 Oct 2022 12:14:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1531624#M5277</guid>
      <dc:creator>_Ferrari_</dc:creator>
      <dc:date>2022-10-03T12:14:03Z</dc:date>
    </item>
    <item>
      <title>Re: dev_cdc_vcom_lite_bm is not full duplex ?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1534713#M5285</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;Yes, the same on my side.&lt;/P&gt;
&lt;P&gt;And I think this is not the issue with MCU side code, because the terminal software on PC send data failed, so MCU can not received. How about try other terminal tools?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;Alice&lt;/P&gt;</description>
      <pubDate>Mon, 10 Oct 2022 08:49:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1534713#M5285</guid>
      <dc:creator>Alice_Yang</dc:creator>
      <dc:date>2022-10-10T08:49:43Z</dc:date>
    </item>
    <item>
      <title>Re: dev_cdc_vcom_lite_bm is not full duplex ?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1535029#M5286</link>
      <description>&lt;P&gt;Dear Alice,&lt;/P&gt;&lt;P&gt;thank you for your reply ?&lt;/P&gt;&lt;P&gt;you wrote:&lt;/P&gt;&lt;P&gt;&amp;gt;And I think this is not the issue with MCU side code, because the terminal software on PC send data failed, so MCU can not received.&lt;/P&gt;&lt;P&gt;If I understand your answer you wrote that the MCU firmware is ok. The problem is on PC site.&lt;/P&gt;&lt;P&gt;Could you, please, confirm your sentence ?&lt;/P&gt;&lt;P&gt;Thank you very much for your help and cooperation&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 10 Oct 2022 16:57:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1535029#M5286</guid>
      <dc:creator>_Ferrari_</dc:creator>
      <dc:date>2022-10-10T16:57:12Z</dc:date>
    </item>
    <item>
      <title>Re: dev_cdc_vcom_lite_bm is not full duplex ?</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1537606#M5290</link>
      <description>&lt;P&gt;Dear Alice,&lt;/P&gt;&lt;P&gt;maybe I fixed the problem: I modified the software as follow:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;  usb_status_t error = kStatus_USB_Error;
    if ((1 == s_cdcVcom.attach) &amp;amp;&amp;amp; (1 == s_cdcVcom.startTransactions))
    {
        /* User Code */
        /* endpoint callback length is USB_CANCELLED_TRANSFER_LENGTH (0xFFFFFFFFU) when transfer is canceled */

        if ((0 != s_recvSize) &amp;amp;&amp;amp; (USB_CANCELLED_TRANSFER_LENGTH != s_recvSize))
        {
            int32_t i;

            /* Copy Buffer to Send Buff */
            for (i = 0; i &amp;lt; s_recvSize; i++)
            {
                s_currSendBuf[s_sendSize++] = s_currRecvBuf[i];
            }
            s_recvSize = 0;
        }
		
		// I added the line
		//------------------------------------------------------------------------------------------
        error = USB_DeviceCdcAcmSend(s_cdcVcom.cdcAcmHandle, USB_CDC_VCOM_BULK_IN_ENDPOINT, NULL, 0);
		//------------------------------------------------------------------------------------------

        if (s_sendSize)
        {
            uint32_t size = s_sendSize;
            s_sendSize    = 0;
			
			// I added the line
			//------------------------------------------------------------------------------------------			
            SDK_DelayAtLeastUs(100U, SDK_DEVICE_MAXIMUM_CPU_CLOCK_FREQUENCY);
			//------------------------------------------------------------------------------------------	
			
            error = USB_DeviceCdcAcmSend(s_cdcVcom.cdcAcmHandle, USB_CDC_VCOM_BULK_IN_ENDPOINT, s_currSendBuf, size);

            if (error != kStatus_USB_Success)
            {
                /* Failure to send Data Handling code here */
            }
        }&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;By adding the two lines as the problem seems to be fixed. I transmit a NULL after receiving a data from USB port, but I have to delay the transmission if I have to receive and send data.&lt;/P&gt;&lt;P&gt;Thank you very much for your help and cooperation&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Oct 2022 07:15:24 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/dev-cdc-vcom-lite-bm-is-not-full-duplex/m-p/1537606#M5290</guid>
      <dc:creator>_Ferrari_</dc:creator>
      <dc:date>2022-10-14T07:15:24Z</dc:date>
    </item>
  </channel>
</rss>

