Hi,
I am developing CDC driver for USB device and I stumble on some problem. The driver I am using on windows side uses Clear endpoint Feature as some kind of flish mechanism or to get data right. That causes me a lot of trobule because I cant get it working. I think data toggle don't agree and I am missing some important data transfer, even not getting associated interrupt with that endpoing because of bad clear data toggle. I reset data toggle to 0 at set interface and clear feature, as pointed out in USB standard. Is there more situation when I should do this? Or is there easy way of error handling invalid data toggle.
Thanks for anwsering. I have got usb analyzer, but I dosen't do me any good now. From what I can managed to gather and I think is happening. I set datatoggle bit in hardvare after Clear feature (as it should be done) for coresponding endpoint. Send some data, It is recived on PC. I know this form USB analyzer and I traced my Vcom driver with port monitor. Then I wait for some data as everything is configured (device enumerated and so on), the initial question is anwsered but the next one is not, after clear endpoint fature the PC side is asking the question again. This should trigger UBS interrupt for coresponding endpoint but it isint happening, again after some time there is clear endpoint feature and the same package, and it's get responded this time and again there is silence on the comunication protocol. I counted the requested tranfer versus missing interrupts and the ratio is exactly 2:1 so i think data toggling is set wrong by half of the time, but how can this be happening if i set data toggle bit every time I get clear endpoint feature.
I hope I stated the problem clearly, for the harvare side I think the only rvelant thing is the bit I am setting. It states "Write a 1 to this bit to reset the endpoint data toggle to 0." Ok i think(hopefully) I solved the Clear endpoint fature, other errors were caused by other things, and cumulative problem was hard to catch.