Transmitting Data in response to class requests

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Posted here and in Host forum...

Anybody out there done this with frameworks for the CY7C67300? I am trying to implement a CDC PSTN ACM...

I have a fwx_class_handler, and call susb_send, but this seems to generate a new transaction rather than inserting a packet into the data stage of the class request.

code fragment:
// Interface 0, Control EndPoint (0)
static USBTXRXINFO VCPClassMsgInfo ATTR_USB_XFER_BUF_SECTION
= { 0 } ;
static uint8 VCPClassDataBuffer[CLASS_BUFFER_SIZE] ATTR_USB_XFER_BUF_SECTION
= { 0 } ;

void susb2_class_handler ( struct USB_DEVICE_REQUEST *pRequest )
{
...
case GET_LINE_CODING: // Optional for class, returns UART control line structure
if (...check pRequest contents){
memcpy(VCPClassDataBuffer, &LineCoding, sizeof(LINE_CODING_STRUCTURE));
VCPClassMsgInfo.buffer = VCPClassDataBuffer ;
VCPClassMsgInfo.length = sizeof(LINE_CODING_STRUCTURE) ;
VCPClassMsgInfo.done_func = & ClassCommandDone ;

susb_send ( FALCON_SLAVE_SIE, EP0, & VCPClassMsgInfo ) ;
}
else{//failed errorcheck, so stall the endpoint
susb2_stall ( ) ;
}
break;
...
}
Raised a support request but deadly silence for three days now.

?

Thanks

0 Likes
0 Replies