From the course: Learning Arduino: Interfacing with Hardware
Unlock the full course today
Join today to access over 23,200 courses taught by industry experts.
Initializing pins for the shift register - Arduino Tutorial
From the course: Learning Arduino: Interfacing with Hardware
Initializing pins for the shift register
- [Instructor] Okay so to start the coding for this part I've provided you with a starter project for this section. So go ahead and open 03_06_starter_project file from the exercise files. So, the exercise file looks like this one. So, the very first thing that we need to do, is we need to identify the three pins that we connected to the shift register. So, the very first one is constant integer, is the dataPin and we connected that to pin number eight in our Arduino board. The second one is constant int, the latchPin that lives in pin number 10. And finally, the shift clock pin, and I will name it as constant int clockPin, and that one's connected to pin 11. Okay, so the next part now, is trying to get the combination in order to show the numbers. So, this is the truth table for the common added LED that we are using. So, in order to get the binary number, you simply take each of the combination and place a zero B…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
(Locked)
Understanding the shift register2m 24s
-
(Locked)
MC74HC595A shift register overview1m 5s
-
(Locked)
Wire up the input and clock signals2m 1s
-
(Locked)
Wire up the signals for VCC and GND2m 52s
-
(Locked)
Wire up the 7-segment LED2m 18s
-
(Locked)
Initializing pins for the shift register2m 56s
-
(Locked)
The shiftOut command3m 21s
-
(Locked)
-
-