Hello,
Sometimes, my controller hangs after being polled by a CDC connection. I see when I debug the ISR that my device status registers contains the vale 0x41 (11110001), which can be interpreted using the following data sheet table:
bit0 The frame interrupt occurs every 1 ms. This is used in isochronous packet transfers. bit1 Fast endpoint interrupt. If an Endpoint Interrupt Priority register (USBEpIntPri) bit is set, the corresponding endpoint interrupt will be routed to this bit. bit2 Slow endpoints interrupt. If an Endpoint Interrupt Priority Register (USBEpIntPri) bit is not set, the corresponding endpoint interrupt will be routed to this bit. bit3 Set when USB Bus reset, USB suspend change or Connect change event occurs. Refer to Section 13â€"11.6 “Set Device Status (Command: 0xFE, Data: write 1 byte)†on page 366. bit4 The command code register (USBCmdCode) is empty (New command can be written). bit5 Command data register (USBCmdData) is full (Data can be read now). bit6 The current packet in the endpoint buffer is transferred to the CPU. bit7 The number of data bytes transferred to the endpoint buffer equals the number of bytes programmed in the TxPacket length register (USBTxPLen).
I don't fully understand why this is happening (it just appears after some time; no endpoint is triggered anymore as a result). Windows issue? software failure? Thanks in advance