


I have a Bat-themed printed circuit board that I designed earlier and I will test it as a GamePad, if it works well I will revise it and design a new version for next use. Define the pins of the components on the circuit, which the key function on the GamePad should call, and update the pin numbers. There are 4 buttons and a Joystick module in the circuit, I will prefer the "Android Gamepad" mode to test the circuit. Let's update the source code according to the components found in the breadboard circuit. By default, Android mode is assigned, but this value can be changed later in the code.

The "GamePad Mode" variable contains the current GamePad mode. Each key name has a corresponding pin number. This description block contains the key names of the mods as well as the button numbers for the different GamePad mods. Also, the source code offers three GamePad modes. The shared GamePad source code contains a total of 13 buttons, the buttons define the key functions of a standard GamePad.
