0
\$\begingroup\$

I'm attempting to design a USB 2.0 hub based on the USB2514Bi, but I seem to be running into some issues. The hub will have an additional daughter board, hence the switches and breakout headers, but theoretically this hub portion should be able to operate completely independently. I've ordered the PCB shown and assembled it by hand, but I haven't been able to make it function in any meaningful way. Windows recognizes the fact that it is a USB device, but I can't seem to write any configuration data to the chip over SMBus.

The schematic shown is for a slightly different design that fixed some minor, silly issues; which is why slight discrepancies exist between the schematic and PCB design. (This includes removing the ferrite bead that seemed to be heavily limiting current, and fixing the mis-wiring of the SDA and SCL lines.)

I'm leaning towards the problem stemming from my soldering, as I've gone through multiple eval board schematics and my design is quite similar.

enter image description here

This is the first "complicated" design I've done myself, and I've been continuing to learn along the way, so any advice would be greatly appreciated.

enter image description here

\$\endgroup\$
8
  • \$\begingroup\$ Are you working at Low Speed, Full Speed, or High Speed here? Because your layout is probably not suitable for High Speed. Your layout in general seems pretty messy. Also, the use of an AMS1117 is a bit of a flaw, though perhaps not an egregious one--it's not a very good regulator. \$\endgroup\$
    – Hearth
    Mar 18 at 15:13
  • \$\begingroup\$ There's no ground plane? \$\endgroup\$ Mar 18 at 15:17
  • \$\begingroup\$ @Hearth the design just needs to work with Low Speed, however Full Speed would be nice assuming it's not too much of an extra hassle. Can you recommend a better regulator? My alternative would probably be a TI part. \$\endgroup\$ Mar 18 at 15:22
  • \$\begingroup\$ You have high speed lines crossing low speed lines, which is a big no no for signal integrity. Going to a four layer board will help. In addition, you should add copper pours and ground them. Rick Hartley gave an excellent talk on this, which totally changed how I think about routing PCBs. \$\endgroup\$
    – C. Dunn
    Mar 18 at 15:23
  • 2
    \$\begingroup\$ You have Type-C connectors. There is nothing to handle the Type-C interface before you are even allowed to turn power on or communicate USB. And it uses Type-A for upstream connection, which requires an illegal cable with Type-A on both ends. This board will not be able to work according to what having a Type-C connector requires. It seems you have replaced downstream Type-A connectors with Type-C connectors and expect it to work. Also you have replaced the upstream USB connector with Type-A which is a downstream connector. Unless that is a Type-A plug instead of a receptacle. \$\endgroup\$
    – Justme
    Mar 18 at 17:52

2 Answers 2

2
\$\begingroup\$

There are quite a many issues.

But the largest problem is that no standard compliant Type-C device will be able to detect being connected to your hub.

Basically, if you want Type-C connectors, you need a hub which can handle them. The hub is intended for direct connection to Type-A receptacles which don't need any special handling.

Having a Type-A receptacle on a USB device side is incorrect, as Type-A receptacles are reserved for the host side. Therefore, devices such as USB memory sticks and keyboards etc have an USB Type-A plugs as they are devices intended to be connected to a host. And that's why devices need to have a Type-B receptacle, so that you can only have cables that are able to connect devices to hosts, so allowed cable should e.g. have Type-A plug and Type-B plug. Which means, cable with Type-A plugs on both ends can be used to connect two hosts together, or two phone chargers, or two powerbanks, all intended to source power out and communicate with a device. Which won't work for data and will fry something due to power supplies being shorted together. So there is no reason for such cables to exist as they let consumers damage their equipment.

So what inherently makes Type-A receptacle as the host connector is the standard. You can of course make your own device that does not adhere to standards, but don't expect non-standard scenarios to work properly. For example, we don't generally have mains supply cords with standard mains plugs on both ends, for obvious reasons, as they are unsafe, can do damage, and devices generally don't have sockets but plugs so use cases are pretty rare.

USB2 did not allow cables with Type-A plugs on both ends, but USB3 allows such cables to exist, with the exception that power supply wire is not connected between plugs. So if you have a legal USB3 cable with Type-A plugs on both ends, you still cannot use it with your hub, because the hub requires to see the supply from PC before it tries to communicate with PC - as required by the standard.

Regarding your Type-C connectors, if you have a USB 2.0 or 3.0 device, i.e. not host, they can very easily have their Type-A plug or Type-B receptacle replaced with a Type-C receptacle or plug.

But, you cannot easily replace a USB 2.0 or 3.0 host side Type-A receptacle with a Type-C receptacle.

That's where you need a Type-C port controller. It needs to detect when something is plugged in, what is plugged in, to know if you connected a device or host or power supply to the connector, and in which orientation it was plugged in to mux the pins to work in both connector orientations without flipping it. And if the cable requires Vconn supply to work, also provide that supply. Then the VBUS can be turned on, if there was a device requiring VBUS connected.

After that, you are free to negotiate USB-PD, but it seemd that your PCB wiring is so thin it doesn't support 5A or 3A very well, so there might be no need for USB-PD. Also you can signal 5V up to 3A without USB-PD. But if you can only provide 5V, you don't need USB-PD if you can't support more than 5V.

You also say you need USB 2.0 which uses only D+ and D-. But it also requires ground, and 5V VBUS supply. But your design cannot support USB-C as a host interface, at least not without the add-on board you don't have yet. There is no way to detect when Type-C device is plugged in, and there is nothing to turn on 5V VBUS after a device being plugged in is detected. Type-C receptacles are not allowed to provide VBUS voltage before a device requiring power is detected. For same reason you can plug in a Type-C charger to the receptacle and that must not cause damage.

\$\endgroup\$
6
  • \$\begingroup\$ The use of USB Type-C is for its PD capabilities, which will be handled by a separate PCB. I’m not sure I understand why I can’t use USB Type-C in this situation though, because it’s being used for USB 2.0 signals which only require the D+ and D- connections. I’m not looking to use any of the more advanced data transfer capabilities of the connector, so I don’t understand why what is effectively a differently shaped connector (in this application) would be problematic. \$\endgroup\$ Mar 19 at 18:02
  • \$\begingroup\$ I should have been more specific in my original post, but the hub is not intended for use with any other consumer products. The upstream connection will be to a computer, and the downstream USB Type-C ports will distribute data and power to other designs I am creating. I am confused what you mean with your "illegal cable" comment as well, I have seen many of this type of cable and nothing is different conductor wise from the connections if I was using something like Mini-B. \$\endgroup\$ Mar 19 at 18:17
  • \$\begingroup\$ And one more question regarding your original comment, what inherently makes a USB Type-A receptacle a "downstream connector"? You indicated a Type-A plug would be fine, but that is effectively what would be accomplished when attaching it to an A-to-A cable. \$\endgroup\$ Mar 19 at 18:33
  • 1
    \$\begingroup\$ @ZachCollins Cables with Type-A plugs on both ends are not supposed to exist. They allow you to connect two hosts together e.g. a computer port that supplies power out, to another computer or phone charger or powerbank etc. They cannot communicate and power short circuit will damage something. It also makes no sense to make cables with Type-B plugs on both ends, because you can't make two devices like two printers communicate together. \$\endgroup\$
    – Justme
    Mar 19 at 18:46
  • 2
    \$\begingroup\$ @ZachCollins OK, fine. While the connector is just a connector, the usage of it matters. It's the cheap incorrectly designed USB devices that have wrong USB connectors in them, which means, as they cannot pass official compliance tests for being in line with USB standards, you are using non-compliant USB devices, and who knows what other things are wrong and incorrectly designed, if they did not even bother to design it with the correct connector. You as a consumer should never encounter incorrect connectors on devices and therefore those dangerous cables either. \$\endgroup\$
    – Justme
    Mar 19 at 23:37
1
\$\begingroup\$

Windows recognizes the fact that it is a USB device, but I can't seem to write any configuration data to the chip over SMBus.

Initial (power-on) configuration of the IC is determined by CFG_SEL[1:0] pins. In your design both pins are pulled up, meaning that the IC is I2C master and expects responses from a slave EEPROM of 24Cxx type. Try first the simplest default configuration by having CFG_SEL[1:0]=00.

And please read the USB2514B datasheet and/or get a demo board EVB-USB2514BC. Also, in the past, MCHP/SMSC did offer free application review, not sure if they are doing this today for this kind of old chips.

And yes, downstream Type-C ports are brutally mismanaged. You must have individual high-side switches on VBUS that are controlled by CC1/CC2 pins.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.