In this video, Zahraa walks you through an example how to use INPUT_PULLUP as one of the modes when configuring an input. In the example, Zahraa connects a pushbutton as input and activates the internal pull-up resistor and uses built-in LED on pin 13.
- [Narrator] In this example, we are going to…use pin 13 for the LED and use…an input internal pull-up resistor for the push button.…Digital pin 13 on a greener board is kind of special…as it has a resistor and LED connected to it all the time.…As covered previously, there are three values…you can use for the interface mode settings.…The input pull-up mode.…Each erdrena model provides an option to activate…an internal pull-up resistor on each individual digital pin.…
The input pull-up mode value determines whether the internal…pull-up resistor is activated or not.…So, now having a pull-up resistor…means the arrangement is active low.…So the push button logic goes to high when it's not pressed,…and low when it's being pressed.…As the pull-up resistor pulls…the value to high when not pressed.…Alright, so this is how I would connect the wiring.…The push button is in active low,…so I'll just connect the push button…from pin two all the way to the ground.…
And for the LED on pin 13 we're not doing any wiring…because it's a built-in LED.…
- What's an Arduino?
- Creating an Arduino program
- Using the setup() and loop() functions
- Using the pinMode() and digitalWrite() commands
- Creating your first sketch
- Writing code to turn LEDs on and off
- Wiring a pushbutton to Arduino
- Activating an LED with a pushbutton
Skill Level Beginner
Learning Arduino: Pulse Width Modulationwith Rae Hoyt1h 16m Intermediate
Learning Arduino: Interfacing with Hardwarewith Zahraa Khalil1h 40m Intermediate
1. Introduction to Arduino
2. Creating an Arduino Program
3. Interface with Output: LED
4. Interface with Input: Pushbutton
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.