SUBHASHINI MANNE

MQX 3.4 USB Device stack CDC Class USB_APP_DATA_RECEIVED event issue

Discussion created by SUBHASHINI MANNE on Feb 10, 2010
Latest reply on Feb 25, 2010 by Juraj Vanco

Hi,

 

I am using the sample example from MQX 3.4 version.

 

These are my observations:

 

1.When I send  data using Hyperterminal,  device  sending back the same character.

2.I developed PC application which sends more than one character.This case always I am getting  data size as( dp_rcv->data_size) 1.

 

When PC appliction sends data bytes, USB Device stack is  generating USB_APP_DATA_RECEIVED  event but  with data size (dp_rcv->data_size) = 1

 

This code snippet is from function void USB_Notif_Callback(uint_8 event_type,void* val,pointer arg)(virtual_com.c)

 

 else if((event_type == USB_APP_DATA_RECEIVED)&&
                                              (start_transactions == TRUE))
        {
          
            uint_32 BytesToBeCopied;           
            APP_DATA_STRUCT* dp_rcv;
            dp_rcv = (APP_DATA_STRUCT*)val;
           
            BytesToBeCopied = dp_rcv->data_size;
            for(index = 0; index<BytesToBeCopied ; index++)
            {
           
              g_curr_recv_buf[index]= dp_rcv->data_ptr[index];

            }
           
                        g_recv_size = index;
        }    

Regards,

Subhashini   

Outcomes