cancel
Showing results for 
Search instead for 
Did you mean: 

USB Low-Full-High Speed Peripherals

Contributor II

Hello,

In AN61345 app note,usb class is in vendor commands,but in fx2lp slavefifo configuration example,they have not defined any vendor commands.simply streaming the data from gpif to usb.

how can i defined vendor commads in this example and i am using image sensor instead of fpga.

let me know.

regards,

geetha.

0 Likes
Reply
1 Solution
Moderator
Moderator

Hello Geetha,

We've locked the thread so that we can keep a track of the same query in one place. If you have further queries that we need to check on that thread, we can unlock it.

Please let me know what error occurs for you? You can check with the following code which will skip one packet on sending the vendor command-

BOOL DR_VendorCmnd( void )

{

  switch(SETUPDAT[1])

  {

  case no_data_control:

  EP6FIFOCFG=0x00;

  EP6BCH=0x00;

  EP6BCL=0x00;

  break;

  }

  return(FALSE);

}

Best Regards,

Sananya

View solution in original post

0 Likes
Reply
4 Replies
Moderator
Moderator

Hello Geetha,

The vendor commands are used over vendor class interface and may or may not be used when the vendor device class is defined in the descriptor as in the mentioned App Note example. If you are using this example, you can directly add vendor commands in the slave.c file. Please refer to the Application Note for firmware implementing the same.

Best Regards,

Sananya

0 Likes
Reply
Contributor II

Hello sananya,

why this thread is locked https://community.cypress.com/message/170027?et=watches.email.thread#170027

can you send me the code snippet.

BOOL DR_VendorCmnd( void )

{

  switch(SETUPDAT[1])

  {

  case Data_control:

  break;

  case no_data_control:

EP6FIFOCFG=0x00;

  break;

  }

  return(FALSE);

}

the above code is not working for me.

regards,

geetha.

0 Likes
Reply
Moderator
Moderator

Hello Geetha,

We've locked the thread so that we can keep a track of the same query in one place. If you have further queries that we need to check on that thread, we can unlock it.

Please let me know what error occurs for you? You can check with the following code which will skip one packet on sending the vendor command-

BOOL DR_VendorCmnd( void )

{

  switch(SETUPDAT[1])

  {

  case no_data_control:

  EP6FIFOCFG=0x00;

  EP6BCH=0x00;

  EP6BCL=0x00;

  break;

  }

  return(FALSE);

}

Best Regards,

Sananya

View solution in original post

0 Likes
Reply
Moderator
Moderator

Please also ensure that the "Bytes to Transfer" field in Control Center is set to 0 before sending the vendor command.

Best Regards,

Sananya