2025-12-12 4:02 AM
Hi,
I use STM32H7 with STCUBE 11.1.
I use RNDIS module usbd_cdc_rndis.h to communicate with a PC.
Sometimes when the PC sends a frame the STM32 replies with NAK, here is the sequence that repeats:
SYNC
PID OUT
Address
CRC
EOP
SYNC
PID DATA0
data 30 bytes
CRC
EOP
SYNC
PID NAK
EOP
What might be the issue? Can I change the USB interval (CDC_RNDIS_FS_BINTERVAL)?
2025-12-15 2:34 AM
Hi @Jonas_A
NAK is a normal USB handshake response that tells the host "I am not ready to receive data right now, please retry later." not necessarily an issue.
Would you specify the issue in application layer ? Do you use reference board? H735 DK? Do you reproduce using the example firmware?
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2025-12-16 4:32 AM
When this happens the PC resends the USB frame infinitely because the STM32 always sends NAK.
Do you know how to troubleshoot this? I use a j-link so I can set breakpoints etc., do you know which function that set the reply to NAK?
The attached .csv file is a log from the logic analyzer that I use.
The first packet that is responded with a NAK starts on line 112095 (byte: 0x40)