

The BUTTONPAD-2X2SINGLE (Manufacturer Part ID: COM-07835) is a 2x2 matrix button pad manufactured by SparkFun Electronics. It consists of four individual buttons arranged in a 2x2 grid, making it ideal for user input in various electronic devices. The button pad is designed for easy integration into projects requiring tactile input, such as control panels, gaming devices, or custom user interfaces.








The BUTTONPAD-2X2SINGLE is a simple yet versatile component. Below are its key technical details:
| Parameter | Value |
|---|---|
| Manufacturer | SparkFun Electronics |
| Part Number | COM-07835 |
| Button Configuration | 2x2 matrix (4 buttons total) |
| Button Type | Tactile, momentary |
| Operating Voltage | 3.3V to 5V (typical) |
| Dimensions | 1.95" x 1.95" (49.5mm x 49.5mm) |
| Mounting Style | PCB mount |
| Material | Silicone button pad |
The BUTTONPAD-2X2SINGLE uses a 2x2 matrix configuration, where rows and columns are connected to pins. Below is the pinout description:
| Pin Number | Label | Description |
|---|---|---|
| 1 | ROW1 | Row 1 of the button matrix |
| 2 | ROW2 | Row 2 of the button matrix |
| 3 | COL1 | Column 1 of the button matrix |
| 4 | COL2 | Column 2 of the button matrix |
The BUTTONPAD-2X2SINGLE is straightforward to use in a circuit. It operates as a matrix, where pressing a button connects a specific row and column. Below are the steps to integrate it into your project:
Here is an example code snippet to interface the BUTTONPAD-2X2SINGLE with an Arduino UNO:
// Define the row and column pins
const int rowPins[2] = {2, 3}; // ROW1 -> Pin 2, ROW2 -> Pin 3
const int colPins[2] = {4, 5}; // COL1 -> Pin 4, COL2 -> Pin 5
void setup() {
// Initialize row pins as outputs
for (int i = 0; i < 2; i++) {
pinMode(rowPins[i], OUTPUT);
digitalWrite(rowPins[i], LOW); // Set rows to LOW initially
}
// Initialize column pins as inputs with pull-up resistors
for (int i = 0; i < 2; i++) {
pinMode(colPins[i], INPUT_PULLUP);
}
Serial.begin(9600); // Start serial communication for debugging
}
void loop() {
// Scan the button matrix
for (int row = 0; row < 2; row++) {
// Set the current row to HIGH
digitalWrite(rowPins[row], HIGH);
// Check each column for a button press
for (int col = 0; col < 2; col++) {
if (digitalRead(colPins[col]) == LOW) {
// Button press detected
Serial.print("Button pressed at Row ");
Serial.print(row + 1);
Serial.print(", Column ");
Serial.println(col + 1);
}
}
// Set the current row back to LOW
digitalWrite(rowPins[row], LOW);
}
delay(100); // Add a small delay to debounce the buttons
}
No Button Press Detected:
Multiple Buttons Triggered Simultaneously:
Unstable or Floating Signals:
Q: Can I use the BUTTONPAD-2X2SINGLE with a 3.3V microcontroller?
A: Yes, the button pad is compatible with both 3.3V and 5V systems.
Q: How do I clean the button pad?
A: Use a soft, lint-free cloth slightly dampened with isopropyl alcohol. Avoid using excessive moisture.
Q: Can I expand this to a larger matrix?
A: Yes, you can combine multiple BUTTONPAD-2X2SINGLE units to create larger button matrices, but you will need additional GPIO pins or a multiplexer.
By following this documentation, you can effectively integrate the BUTTONPAD-2X2SINGLE into your projects and troubleshoot any issues that arise.