How to Access Some Buttons on Controller Through Code


We’re using the basic Logitech Fakebox controller that came with the Rookie Starter Kit. Do any of you know the numbers that I have to put into the code to check the status of the D-pad, Start, and Back buttons? I thought Back would be 12 and Start would be 13, but I get an error saying those buttons do not exist when I deploy the code. I have no inkling of what the D-pad numbers would be.


Here’s a chart. It depends on the mode selected:


If you open up the driver station to the inputs tab, you can click each button on any controller and see what number it is


Wow, thank you so much! This is exactly what I needed. I hope your team didn’t find all those values through trial and error…


Most of them don’t have numbers next to them, though, which was the trouble.


Wait. Right now I have the “A” button as 6, and it works. Is there another mode?