In the "Map Controllers" panel, press the button on the joystick you want to map a command to. You can double-click, or press the "Modify" button and the available command list will pop-up so you can select the command you want to assign to that button.