I have some esp32-s3-wroom-1u modules and was wondering if its okay to connect esp32s usb data (dp and dm) pins directly to hosts data pins. Since esp32 is 3.3v device while host pc is a 5v device doesnt esp32 need a level shifter? I have seen online that others have just connected them directly to usb ports data pins. It would make sense if esp32 has an internal level shifter but im not sure.
Another question is how does the otg work on it. On cellphones with otg support and using usb micro B port ,shorting the ID pin to ground switches a device to otg mode. How does it work for esp32 s3?
USB on esp32-s3 wroom
-
- Posts: 9709
- Joined: Thu Nov 26, 2015 4:08 am
Re: USB on esp32-s3 wroom
The data lines of USB are always 3.3V, so that will work. An USB host will output 5V to power a device, so if you want to use that, you'll need a LDO or something to get it down to 3.3V.qheinal wrote: ↑Sun Mar 31, 2024 5:04 pmI have some esp32-s3-wroom-1u modules and was wondering if its okay to connect esp32s usb data (dp and dm) pins directly to hosts data pins. Since esp32 is 3.3v device while host pc is a 5v device doesnt esp32 need a level shifter? I have seen online that others have just connected them directly to usb ports data pins. It would make sense if esp32 has an internal level shifter but im not sure.
It depends on the stack that you use, but in most cases people hardcode the program running on the ESP32 to either run as a device or as a host. I think you can do full OTG, but it's normally not necessary.Another question is how does the otg work on it. On cellphones with otg support and using usb micro B port ,shorting the ID pin to ground switches a device to otg mode. How does it work for esp32 s3?
Re: USB on esp32-s3 wroom
Since USB Signaling is indeed 3.3v then It makes sense that it wouldn't need level shifting. Also it makes sense why if VBus shorts to data pins it can damage the usb controllers on electronics.
Its kinda funny how I've written host/device drivers for baremetal but i didnt know usb signaling was actually 3.3v not 5v. Even when reading the usb docs it didnt say that.
Its kinda funny how I've written host/device drivers for baremetal but i didnt know usb signaling was actually 3.3v not 5v. Even when reading the usb docs it didnt say that.
Who is online
Users browsing this forum: No registered users and 213 guests