gamepad
Press buttons on a virtual game controller connected to iOS, tvOS, or visionOS simulators to test games that need controller input; send d-pad, face, shoulder, and menu presses in order.
Instructions
Press buttons on a virtual game controller connected to a simulator (iOS, tvOS, visionOS). For games that take a controller. Buttons: up, down, left, right (d-pad), a, b, x, y, menu, options, l1, r1, l2, r2. Several buttons are pressed one after another.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"device": "<device>",
"buttons": "<buttons>"
},
"name": "gamepad"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| device | Yes | Device id (or exact name) from the devices tool | |
| holdMs | No | How long each button is held. Default 150 | |
| buttons | Yes | Buttons to press, in order, for example ["right", "a"] | |
| screenshotAfterMs | No | If set, wait this many milliseconds after the action and return a screenshot too |