Gamepad Buttons
FREEMulti-button gamepad with custom actions
When to reach for it
Gamepad Buttons puts up to four fixed-payload actions on one thumb-reachable diamond: arm/disarm, gripper open/close, four mode switches. Set Buttons Shown to 1 and it renders a single round button, so for one action alone, Custom Button is simpler. For freeform JSON on any topic without the diamond layout, Topic Publisher (Pro) is the escape hatch.
Worked example: arm/disarm and gripper on the shipped topic
As shipped, all four buttons publish to /gamepad with schema std_msgs/msg/String, and Message is free-tier per button. Rewrite two payloads to {"data":"arm"} and {"data":"disarm"}, do the same for gripper open and close, and leave Hold Mode off (the default) so each tap fires once. Labels stay A/B/X/Y until Custom Button Labels (Pro) renames them to match.
Watch out for
- Only the top button's Topic field is exposed in the editor. The other three slots carry their own topic in config; nothing syncs them when you edit Topic, so all four default to
/gamepadwith no way to point one elsewhere. - Buttons Shown is a target the grid can override: shrink the widget to a 1-cell-tall or wide strip and the count is capped by available cells. Reorder by Button Priority before resizing, so the buttons you actually use survive the cut.
Configuration fields
The topic this widget publishes to. While connected, tap to pick from the topics the robot advertises.
The ROS message type for this topic, e.g. sensor_msgs/msg/Image. Usually auto-filled when you choose a topic.
Publish repeatedly while a button is held, instead of once per tap.
Streaming rate while a button is held.
WITH PRODefault is 10 Hz. Higher rates feel more responsive on jog-style commands; lower rates save bandwidth.
How many buttons the widget shows, from 1 to 4. Four forms the diamond; fewer line up and drop by Button Priority.
Replace A / B / X / Y with your own text on each button.
WITH PROPro lets you swap the default A / B / X / Y for whatever your robot expects, like "Arm", "Home", "Reset", "Cancel". Useful for muscle-memory operators who never want to think about which letter does what.
Pick a color per button to encode meaning at a glance.
WITH PROColor-code by function: red for cancel or abort, green for go, gold for prepared actions, blue for mode switches. The default palette stays themed if you don't customize.
Set each button's published Message. Tap the reorder icon to set Button Priority.