1
\$\begingroup\$

I'm building a mechanical keyboard and I need more current from my PC than I can get from one usb port. Can buy/make a usb splitter that I can plug into two A ports on my PC and plug into my USB-C MCU? The MCU in question can handle up to 2A and I don't need that much...but I do need more than 900mA.

Am I better off designing my keyboard with a second usb port for additional power? (In which case I'll need to ask another question to understand how!)

\$\endgroup\$
19
  • \$\begingroup\$ why does your keyboard need 2 amps? \$\endgroup\$
    – user253751
    Apr 12, 2022 at 15:17
  • \$\begingroup\$ Led strip. Even at half brightness, all the LEDs together will exceed 900mA, let alone the current the MCU itself needs. I probably won't need 2A...but definitely more than .9A \$\endgroup\$
    – AerosolSP
    Apr 12, 2022 at 15:24
  • 2
    \$\begingroup\$ did you test the brightness? 10W of LED light is quite a lot \$\endgroup\$
    – user253751
    Apr 12, 2022 at 15:36
  • 3
    \$\begingroup\$ Sounds like your LED strip choice is not quite appropriate for the application, unless you want to fully illuminate the whole room. \$\endgroup\$
    – Eugene Sh.
    Apr 12, 2022 at 15:38
  • \$\begingroup\$ Honestly, I have not! They've only arrived today and I haven't gotten home from work yet. But I can't wait until after I've put everything together before finding out that I have to turn the brightness down lower than I'd like in order to not trip a fuse. So I want to make atleast another 500mA available now so I have some wiggle room. \$\endgroup\$
    – AerosolSP
    Apr 12, 2022 at 15:42

1 Answer 1

3
\$\begingroup\$

Design your project with USB C and a C to C cable in mind.

Eve though USB A ports on a desktop only provide about 900ma, the USB C ports on a desktop machine typically provide higher currents, up to 3A.

On your board, measure the voltage on both CC pins using a 10K resistor and then to your microcontrollers ADC, and take the highest voltage of the 2 measurements.

  • If you measure above 1.31V, the downstream facing device advertises maximum 3A, meaning it is good enough for all your device features

  • If you measure above 0.70V, the downstream facing device advertises maximum 1.5A, so you limit the brightness/max PWM in software to stay under the limit

  • If you are communicating USB 3.2 dual lane to the other device, your limit is 1.5A

  • If you are communicating USB 3.2 single lane to the other device, your limit is 0.9A

  • If you are communicating USB 2.0 to the other device, your limit is 0.5A

  • Otherwise, the host must be in suspend, so the limit is 0.1A

By gracefully reducing the maximum consumption based on the advertised values, you increase compatibility with other devices

\$\endgroup\$
1
  • \$\begingroup\$ Thanks! Just one thing: my desktop machine has no USB C ports, so I'm ultimately limited anyway! \$\endgroup\$
    – AerosolSP
    Apr 19, 2022 at 10:07

Your Answer

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

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