









The Push Button Round typically has two or four pins, depending on the model. Below is a description of the pin configuration:
| Pin Number | Description |
|---|---|
| 1 | Terminal 1 (connect to circuit) |
| 2 | Terminal 2 (connect to circuit) |
| Pin Number | Description |
|---|---|
| 1 | Terminal 1 (connect to circuit) |
| 2 | Terminal 2 (connect to circuit) |
| 3 | Terminal 3 (internally connected to Terminal 1) |
| 4 | Terminal 4 (internally connected to Terminal 2) |
Note: For 4-pin buttons, terminals 1 and 3 are internally connected, as are terminals 2 and 4. This ensures flexibility in PCB design.
Below is an example of how to connect and use a Push Button Round with an Arduino UNO:
// Push Button Example with Arduino UNO
// This code reads the state of a push button and turns on an LED when pressed.
const int buttonPin = 2; // Pin connected to the push button
const int ledPin = 13; // Pin connected to the onboard LED
void setup() {
pinMode(buttonPin, INPUT_PULLUP); // Set button pin as input with internal pull-up
pinMode(ledPin, OUTPUT); // Set LED pin as output
}
void loop() {
int buttonState = digitalRead(buttonPin); // Read the button state
if (buttonState == LOW) { // Button pressed (LOW due to pull-up resistor)
digitalWrite(ledPin, HIGH); // Turn on the LED
} else {
digitalWrite(ledPin, LOW); // Turn off the LED
}
}
Note: The internal pull-up resistor ensures the button pin is HIGH when the button is not pressed, avoiding floating input issues.
Button Not Responding:
Erratic Behavior (Button Bouncing):
Button Stuck or Difficult to Press:
Q1: Can I use the Push Button Round with a 5V circuit?
A1: Yes, most Push Button Round models support 5V operation. Check the specific voltage rating of your button to confirm.
Q2: Do I need an external pull-up resistor if using an Arduino?
A2: No, the Arduino has an internal pull-up resistor that can be enabled in the code (INPUT_PULLUP).
Q3: How do I debounce the button in software?
A3: Use a delay or a state-checking algorithm in your code to filter out noise caused by button bouncing.
Q4: Can I use the button for high-power applications?
A4: No, Push Button Round switches are designed for low-power applications. Use a relay or transistor for high-power circuits.
By following this documentation, you can effectively integrate the Push Button Round into your electronic projects!