Here is an example .cap file.
Edit the cap file controls / LastButtonOnController = the last detected button on your physical controller.
---------------------------------------------------------------------------------
The issue is with setting a button for a controller that is higher than the number of buttons on a physical controller.
My Xbox360 controller has 10 buttons that are detected.
LastButtonOnController = 10
Button_21 = 21
InputSystem.GetControlString("LastButtonOnController", 1) = Joy Button 09
InputSystem.GetControlString("Button_21", 1) = Joy Button 09
It should be
InputSystem.GetControlString("LastButtonOnController", 1) = Joy Button 09
InputSystem.GetControlString("Button_21", 1) = Joy Button 20
even if Joy Button 20 isn't on the Physical controller.
Hope I explained that ok