xmegaa1uxplainedpro USB transfer complete interrupt

1 post / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi,

Setting up the USB to receive on interrupt was straightforward and it works.

 

In conf_usb.h:

#define  UDI_CDC_RX_NOTIFY(port)          main_cdc_rx_notify(port)

 

In main.c:

void main_cdc_rx_notify(uint8_t port)
{
    udi_cdc_read_buf (buf_in, 1);
}

 

How can I similarly define 

#define  UDI_CDC_TX_EMPTY_NOTIFY(port) main_cdc_tx_empty_notify(port)

 

What USB CDC API will the call back function main_cdc_tx_empty_notify(port) call?

 

I am currently using udi_cdc_write_buf(tmpTXBuf,len);    to send through the USB. I don't have any callback defined yet for UDI_CDC_TX_EMPTY_NOTIFY.

 

Thanks,

 

Last Edited: Mon. Aug 9, 2021 - 01:48 PM