CommandXboxController / leftTrigger() and rightTrigger() not triggering

Hi, we got a Logitech F310 controller to see if we had the same problem than our XBOX 360 controller and we observed the exact same problem. It seems like rescanning twice is a good method for fixing this problem.

For reference our laptop is a Dell Inspiron 5593 running Windows 10.0.19045

Please go ahead and submit a service request to NI. As @KaV1a wrote, we confirm that our problem is the same as yours, and for us it is 100% reproducible by restarting the laptop (as in clicking on “Restart” in the Windows Start menu) with both a genuine Xbox 360 controller and a Logitech F310.

Following a restart, we always encounter two issues:

  1. DriverStation does not see any joystick or controller - the known bug

After a first Rescan, or unplugging and replugging the USB hub which our joysticks and controller are connected to:

  1. DriverStation sees the controller as a DirectInput controller, and the triggers do not work from our code (but the left axis of the controller still does). Calling DriverStation.getJoystickIsXbox(Ports.USB.GAMEPAD) returns false - the unacknowledged bug / the reason behind the creation of this thread

A second Rescan, or a second unplugging and replugging seems to always solve the problem:

DriverStation then realizes that the controller is XInput, triggers work from our code
DriverStation.getJoystickIsXbox(Ports.USB.GAMEPAD)) returns true

So, for now, we use your approach to detect the issue and report it to the console if present, and the drive team will always double-check that they are good to go before a match (i.e. they will make sure that they have rescanned twice).

Thanks.

2 Likes

I’m wondering if there’s a windows version relation here? What exact Windows version (eg what’s in system info) are you and other teams seeing this issue running?

1 Like

For team 2495, as stated earlier, Windows 10. 0.19045 on a Dell Inspiron 5593 that we have been using without issues for a few years (until the 2023 release of the NI Driver Station which is known to have a related bug)

Is the “Driver Station does not detect joysticks at startup” a rare issue? For us it’s always an issue after rebooting our laptop (as of this year).

Can’t you reproduce the problem on your hardware? We can try another laptop with Windows 11 just to get another datapoint.

In any event I think it would be a good idea to amend the Known Issues page of the WPILib doc to mention that connecting joysticks after starting the DS or rescanning once might not be enough, and suggest to rescan twice (and it would be good to add the screenshots from @StarbuckBarista to show what a properly detected Xbox controller look like in the DS).

No, that is a known issue and occurs for everyone. We have not been able to reproduce the directinput vs xbox controller issue you’re running into, although it’s possible it’s related given that rescanning works after a couple of tries.

Interesting. So assuming you have the controller properly recognized in the DS and you do a soft restart of your machine, once you login again and launch the DS then you do a single rescan and everything is OK? For us we tried the scenarios we described multiple times and every time we saw the problem…

I’ve just submitted the Service Request to NI with a summary of our collective observations and a link leading back to this thread. I will reply whenever I receive more information from the team at NI.

To teams just stumbling upon this thread, we do not have an immediate solution. I recommend implementing some form of error handling to alert drivers when their controllers are unresponsive.

1 Like

Thanks for all the hard work - we’ve seen this a couple times too. I sure hope NI can fix this before our week 2 event!

To unhelpfully chime in, we’ve gotten the same issue twice, but are unable to consistently reproduce it (admittedly, we haven’t tried much). I’ll be able to try to reproduce more later tonight and provide machine and controller specs.

Thanks. That would indeed be good if all the teams that experience the issue could list the brand and model of their laptop, the exact version of Windows they are running, and the brand and model of their controller.

@chauser What do you think NI will fix first? This bug, or the I2c bug in the Rio :wink:

Sighs.

Definitely this one. The I2C bug is likely unfixable without new CPU’s. Its most likely either a HW bug, or a bug from the CPU vendor and not NI. I spent a few weeks even recompiling the kernel with newer patches to see if it was fixable, and got nowhere.

Thanks for attempting to fix the I2C issue. Recompiling the kernel with newer patches does not sound like fun!

Going back to the controller detection issue, I think it would be good if it was mentioned in the list of known issues for 2023, so I took the liberty to raise this documentation ticket:

List of known issues (for 2023) could be expanded · Issue #2207 · wpilibsuite/frc-docs (github.com)

By the way, can you comment on the alleged issue with the second port of the OpenMesh radio? 2495 has been using a switch connected to the second port of the OpenMesh radio for a few years now, to stream webcams via a Pi running the excellent WPILibPi, as well as to recognize targets using a Limelight, and we do sporadically encounter an unexplained lack of feed from the cameras at startup which is typically resolved by invoking spirits by dancing around the robot.

2nd port on the radio is also a known issue caused by either a hardware bug or proprietary parts of the firmware in the radio.

Following up with the Service Request with NI:

After further research I found this issue is currently being worked on and there are only a few details left for a patch to be released.

I was instructed that is possible this is caused by the loop not enumerating through all joysticks. If there was any patch released or update performed to the software, this will be announced in the official communication channels of the First Robotics Competition to ensure all the participants who are dealing with such bug take this into account. Thanks for bringing such issue to our attention!

2 Likes

Rumor is that the NI Driver Station 23.1 released on 28-Feb-2023 might include a fix for our issue.

Let’s give it a try.

FRC Game Tools Download - NI

source: Get your software ready for competition - Technical / Programming - Chief Delphi

1 Like

Hi. We have updated the driver station to the newest update and the problem appears to be fixed. We rebooted the computer and received the same results! Rescan was not needed and the controller and its triggers were detected immediately in green.

“NI FRC Game Tools are updated. Last week’s release contains version 23.1 of the Driver
Station application which corrects an issue with detecting USB devices at application launch.”

We have not seen the issue described in this thread after updating, so I am going to mark this as the solution.

Team Update 0_2021 (windows.net)

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.