Preventing USB controllers from swapping USB ports?


In our driver’s station we use a laptop and two game controllers. Over the years we have had a reoccurring problem with the game controllers swapping USB ports at the absolute worst times. Our drivers have developed the habit of checking this just before matches, but occasionally they either don’t have time or forget, and very bad things happen as a result.

Has anyone else experienced this type of thing? What do you do to prevent it from happening? Is there some way to force the drivers station laptop to always use the same controllers (or physical USB ports) for the driver and operator?


great question as we had the same thing happen week 1. Our drive team plugged controllers into the wrong ports and our drive base controls were reversed one match in quals. Needles to say…driver ALWAYS double checks now pre match after everything is setup on the driver station.


what our team does is that we label which controller goes into which port physically and also, they plug the controllers into a certain order which I think helps aswell. as soon as we started to do that we had no bad feedback or having to mess with the ports moving in the drivers station.


Double click on the name of the controller in the driverstation. It will become underlined and will be “locked” on that port.


This year we put labels on each controller for which port it should show up as in the driver station.

However, we haven’t had this problem because we use 3 different controllers so I guess that makes it so the driver station doesn’t mix them up. Even when we had the same type of controller plugged in, they didn’t get mixed up.


Are you unplugging the controllers from the laptop between matches? If so, why?

There is no way that I know of for the controllers to be set more specifically.

I made ensuring the controllers are set correctly a task for our technician during driver station setup on the field and we’ve never had a problem.

Pre-flight checklists are your friend.


We’ve been using only one robot driver/operator using one game pad for a few years now, havn’t had any issues.

Although some times the game pad disappears, requiring a rescan


IIRC, the issue happened because the driver station needed rebooted.


Our driver station application most of the time seems to remember which controller was set in the order on the DS…even after a system reboot. I’ve never studied exactly why/what it is doing for this behavior.

I will say this…our checklist is on a software desktop note that is always on the top of the desktop. Instead of another piece of paper to carry around. Sorry I don’t have a better suggestion.


We had this happen to us randomly in the middle of matches last year. They’d have the controllers in their hands and suddenly would have each others controls. We never did narrow down exactly what caused it, but another team mentioned a similar problem and they were using the same offbrand controller we had at the time. Here’s our current routine…

  • Diligently check controllers are in the correct ports before every match
  • Use only trusted brands of controllers (currently we use PS4 dual shock controllers, though Microsoft brand seemed fine as well)
  • Treat all controller cables with care, don’t coil them around controllers or bunch them up or squish them (it’s possible we had a bad cable which would briefly disconnect in match, causing one controller to disconnect temporarily and the other would swap positions, so when the first came back they had been swapped)
  • Treat all USB ports with care as well, make sure we aren’t putting pressure at the connection
  • Plug controllers into USB ports on opposite sides of the robot
  • Function check before every match (this is more about everything else than the controllers, but it also serves to verify those)


This all sounds so familiar. Controller issues were one of the big overlooked failures that cost us matches. It’s easy to overlook the drivers station and focus solely on the robot during build season. Our number of controller related failures dropped drastically when we switched to controllers with hardwired USB cables rather than those with swapable cables that connect with a micro USB connector. That micro USB connection was the root cause of the vast majority of our problems.


Oh, and I forgot to mention we keep a spare controller in the driver station so we can hot swap it in match if one fails. Saved us in a subdivision finals match last year. Drivers realized controller has failed when robot wasn’t moving and we still had comms, grabbed the spare and plugged it in, back to play.


From this thread and others, it looks like we have some viable possible solutions to investigate:

  1. Lock the controller in the drivers station software, then…
  2. If possible, rename one of the controllers so the laptop sees it as a non-identical device, or
  3. Buy a different brand of controller for either the driver or operator.

Thanks for the help, CD. We’ll let you know how this works.


At our meeting last night we discussed the options above. It doesn’t look like #2 is possible. Opinions were divided about #3. Further help from the community would help settle the debate.

The open question is this: Would wired xbox controllers from different manufacturers have the same or different names in the driver station list of USB devices? This would be simple to test if we had different controllers, but we have 4 identical ones. Would people be willing to respond, listing the make and model of their controller and also how it appears in the driver station? And to make the thread useful for more people, let’s open it up to any game controller, not just xbox controllers. Including manufacturer and model number is critical to making your response useful. An Amazon link to the exact product is even better.


go to walmart and buy one? :slight_smile: that’s what I’m going to do very soon.

I notice you did not list the possibility of combining all controls onto one controller, as a possible solution. Interesting.


We have used two different xbox controllers previously from different manufacturers. They did show up as two different names. One was an official xbox controller and one was the clear light up version–it appeared in the DS as "afterglow . . . "


Some years, maybe. Not this year, with this bot.


Hey @ToddF

my team has this happen as well and we just set up a button on the joystick that if they are backwards you press the button and it swaps the y and x values in the code so that you are now driving correctly… If you need help adding in this code just message me! :slight_smile:


It depends on the controller. Not all Xinput devices literally show up as Xbox Controllers by name in the driver station, but many do, so they will not always be distinct.

Be aware that most third party Xbox controllers have really crummy analog stick centering, so you will need to increase the deadband to compensate.


What is the driver station looking for when it’s determining unique devices? Product Description or VID:PID?

Obviously it’s using Product Description for the display string, but is it using that when checking for the locked ports?