Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

USBD_CDC_ACM_HandleTypeDef dubplicate data for NUMBER_OF_CDC? #20

Open
devOramaMan opened this issue Sep 5, 2022 · 1 comment
Open

Comments

@devOramaMan
Copy link

typedef struct
{
uint32_t data[NUMBER_OF_CDC][CDC_DATA_HS_MAX_PACKET_SIZE / 4U]; /* Force 32bits alignment */
uint8_t CmdOpCode;
uint8_t CmdLength;
uint8_t *RxBuffer;
uint8_t *TxBuffer;
uint32_t RxLength;
uint32_t TxLength;

__IO uint32_t TxState;
__IO uint32_t RxState;

} USBD_CDC_ACM_HandleTypeDef;

and

USBD_CDC_ACM_HandleTypeDef CDC_ACM_Class_Data[NUMBER_OF_CDC];

I couldn't quite understand from the code why data also has “NUMBER_OF_CDC” array aswell as the CDC_ACM_Class_Data. Is it something I’m missing?

@alambe94
Copy link
Owner

alambe94 commented Sep 5, 2022

Yes, you are correct. [NUMBER_OF_CDC] is not necessary in USBD_CDC_ACM_HandleTypeDef.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants