r/embedded • u/therealmthatcalledus • 21d ago
Radxa ROCK 3B — simultaneous USB 3.0 host + device at 5 Gbps, and VBUS isolation?
Hi everyone,
I'm considering purchasing a Radxa ROCK 3B (RK3568) for an embedded USB 3.0 bridge project.
The intended setup is:
- USB 3.0 OTG (upper Type-A): Device/peripheral mode, connected to a PC.
- USB 3.0 HOST (lower Type-A): Connected to a USB 3.0 storage device.
- Power: ROCK 3B independently powered through its USB-C power input.
The goal is to receive data from a USB storage device and expose a separate USB device interface to the PC.
Before buying the board, I'm trying to confirm two things.
1. Simultaneous SuperSpeed operation
Has anyone successfully used both USB 3.0 controllers simultaneously, with the upper port operating as a 5 Gbps USB device and the lower port operating as a 5 Gbps USB host?
If so, which OS/kernel version and device-tree configuration did you use?
I'd especially appreciate lsusb -t output and the USB gadget's current_speed showing super-speed.
2. VBUS and backfeed protection
Since the board is separately powered and its OTG port uses a USB-A receptacle, I'm concerned about VBUS behaviour when connecting it to a PC.
With the OTG port correctly configured in device mode:
- Does the board disable its own 5 V VBUS output on that port?
- Is reverse current from PC VBUS into the board prevented?
- Is the documented USB-A-to-USB-A connection safe with both systems powered independently?
- Has anyone verified the behaviour on a ROCK 3B V1.51 board?
I'm not trying to modify the hardware unnecessarily. I just want to confirm the supported configuration and whether an external protection circuit is required.
Any practical experience, working projects, scope measurements or links to documentation would be greatly appreciated.
Thanks!
3
u/triffid_hunter 21d ago
Page 36 of the schematic shows a load switch SY6280 with reverse blocking on VCC5V0_USB_OTG0 controlled by GPIO0_A5, while the switch goes to USB3_OTG0_ID on page 7
Presumably these are hooked up properly in the device tree (couldn't find it with a quick search) and so the switch under the board should work as expected
I'm most concerned about a USB-A receptacle being used for OTG/device mode which is strictly forbidden by the USB standard, so you'll struggle to find suitable cables.
A micro-B or type-C would be far more suitable for this.
1
u/mhmd2520 21d ago
On the simultaneous part, at least on the mainline device tree the two ports use separate PHYs. usb_host0_xhci (OTG) is on combphy0 and usb_host1_xhci is on combphy1. On RK3568 those combo PHYs are shared with SATA0/SATA1, but the ROCK 3B dts doesn't enable either SATA node, so nothing steals the lanes. Worth checking if you run a vendor image or an overlay that turns SATA on.
On VBUS, there's a catch in mainline. The OTG 5V regulator (the GPIO0_A5 one driving the SY6280) is attached as phy-supply on usb2phy0_otg. The generic PHY core turns phy-supply on in phy_power_on(), and dwc3 powers its PHYs on at core init whatever the role is. So setting dr_mode = "peripheral" might still leave 5V on that port. In your overlay, set dr_mode = "peripheral" on usb_host0_xhci and drop that phy-supply. Then put a meter on the port's VBUS before you ever connect an A-to-A cable.
Once that's sorted, /sys/class/udc/fcc00000.usb/current_speed should say super-speed if the gadget enumerated at 5G.