I'm trying to run the USB VCOM example project on RT1052-based custom hardware. My setup is as follows:
1. Import example project.
2. Remove BOARD_FLASH in linker script. The example fits in 128K internal RAM with ample margin.
3. Modify CONTROLLER_ID to be kUSB_ControllerEhci1. My hardware uses the second USB controller.
4. Compile and run the project.
I can debug the application and step through code.
I've also attached a Beagle USB analyzer. The RT1052 USB controller responds when attached to my PC, but does not ACK the initial SETUP/DATA0 request. I've attached a trace from the Beagle. You can see the ACK is missing after SETUP/DATA0. When I unplug/replug the USB cable, the RT1052 attempts to re-initialize the USB stack and the same problem occurs. (Demonstrates that the USB stack is not frozen, and the problem is repeatable.)
Does anyone have ideas as to what might be wrong?
You are correct, it was a hardware problem.
On my board, I have a 5-pin header for GND, D-, D+, ID, and 5V0. Since I do not have a test fixture yet, I soldered a USB cable directly to the PCB for testing. Unfortunately, I mixed up the D- and D+ wires. After I soldered the D- and D+ wires to the correct locations, the example worked perfectly.
Thanks for the suggestion!