The AM335x USB operate as the device mode and Full-Speed.
It can simulate a disconnect that the SOFTCONN bit of POWER register (bit 6) is cleared to 0.
Can it disable the 1.5Kohm pull-up resistor on the D+ line automatically?
Best regards,
Daisuke
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
The AM335x USB operate as the device mode and Full-Speed.
It can simulate a disconnect that the SOFTCONN bit of POWER register (bit 6) is cleared to 0.
Can it disable the 1.5Kohm pull-up resistor on the D+ line automatically?
Best regards,
Daisuke
Hi Biser,
Thank you for your reply.
Our customer wants to know how to disable the internal 1.5Kohm pull-up resistor on the D+ line to notify the external host that the USB device can remove from the USB bus.
I am waiting for your answer.
Best regards,
Daisuke
Daisuke Maeda said:Our customer wants to know how to disable the internal 1.5Kohm pull-up resistor on the D+ line to notify the external host that the USB device can remove from the USB bus.
The D+ or D- pullup only exists in the very beginning of the enumeration process for a very short of the time. After the enumeration is complete, the pullup is disabled for the whole life cycle of the connection.
I guess in your project, AM335x MUSB in device mode is permanently connected into the USB host, and you want to disconnect sometimes? If so, clearing SOFTCONN may not be the best solution. Could you please describe the USB requirement in your design? Do you use Linux or other OS?
Sorry, please ignore my message above. It was incorrect for full-speed.
To answer your initial question, yes, clearing SOFTCONN bit will disable the pullup and you can use it to simulate disconnect from the host. Just ensure to teardown the connect state in OTG state machine in your driver after cleared SOFTCONN bit.
Hi Biser,
Thank you for your reply.
The AM335x as a device side clears SOFTCONN bit.
Best regards,
Daisuke
In most of the use cases, no, clearing SOFTCONN is not suitable for remove the USB device. When unplugged the USB cable, MUSB generates DISCONNECT interrupt, the device driver should handle this event and teardown the driver state for both MUSB and the gadget driver.
But if AM335x/MUSB is permanently connected to the USB host and there is no USB cable to disconnect, then I think SOFTCONN is a better alternative to remove the USB device. The driver has to do the same handling as that for DISCONNECT interrupt.