About 2,300,000 results
Open links in new tab
  1. switch...case | Arduino Documentation

    May 21, 2024 · Like if statements, switch case controls the flow of programs by allowing programmers to specify different code that should be executed in various conditions. In particular, a switch statement …

  2. Switch (case) Statement, used with sensor input - Arduino Docs

    Oct 2, 2024 · Switch allows you to choose between several discrete options. This tutorial shows you how to use it to switch between four desired states of a photo resistor: really dark, dim, medium, and bright.

  3. How to Wire and Program a Button | Arduino Documentation

    Oct 2, 2024 · That's why you need a pull-up or pull-down resistor in the circuit. Schematic Code Learn more You can find more basic tutorials in the built-in examples section. You can also explore the …

  4. Switch (case) Statement, used with serial input - Arduino Docs

    Oct 2, 2024 · This tutorial shows you how to use switch to turn on one of several different LEDs based on a byte of data received serially. The sketch listens for serial input, and turns on a different LED for …

  5. Beginners: using the switch - case statement - Arduino Forum

    Oct 27, 2020 · The switch - case statement is a powerful construct that is often under-used by beginners. Basically it allows you to perform tests on a value (or range of values) and make …

  6. InputPullupSerial | Arduino Documentation

    Oct 2, 2024 · It monitors the state of a switch by establishing serial communication between your Arduino and your computer over USB. Additionally, when the input is HIGH, the onboard LED …

  7. Digital Read Serial | Arduino Documentation

    Oct 2, 2024 · This is a digital input, meaning that the switch can only be in either an on state (seen by your Arduino as a "1", or HIGH) or an off state (seen by your Arduino as a "0", or LOW), with nothing …

  8. Switch | Arduino Documentation

    Dec 12, 2025 · Arduino library for deglitching and debouncing switches and buttons. Supports detecting longPress, doubleClick, and singleClick. Supports defining callback functions.

  9. INPUT | INPUT_PULLUP | OUTPUT | Arduino Documentation

    May 15, 2024 · In order to assure a proper reading when the switch is open, a pull-up or pull-down resistor must be used. The purpose of this resistor is to pull the pin to a known state when the switch …

  10. While Loop | Arduino Documentation

    Oct 2, 2024 · Learn more You can find more basic tutorials in the built-in examples section. You can also explore the language reference, a detailed collection of the Arduino programming language. Last …