Project tutorial
Control a 7 Segment Display with a keypad!

Control a 7 Segment Display with a keypad! © CC BY-SA

In this project I'll show you a simple way to control a 7 Segment Display with a keypad!

  • 10,542 views
  • 17 comments
  • 18 respects

Components and supplies

Apps and online services

About this project

This is a simple project that shows you how to control a 7 Segment Display with a Numeric Keypad! Whatever number you press on the keypad will appear on the Seven Segment Display!

Making It

The schematic is down below. It should be pretty easy. You need to use a 3x4 matrix keypad so you have enough pins.

The Code

In my sketch, to easily control the 7 Segment Display, I am using the sevenSegmentDisplay library by Giuseppe Masino which you will need to install also. You can download it from the Arduino Library Manager or the Github page. You will also need to install the Keypad library which you can also get from the Arduino Library manger.

You will need to tweak the code a little bit to get it to work. Here's what you need to do:

At this line:

sevenSegmentDisplay ssd(COMMON_ANODE, 13, 12, 11, 10, 9, 8, 7, A0); 

If you have a common cathode display change COMMON_ANODE to COMMON_CATHODE. Also, you may have noticed that I put A0 for the decimal point. We're not using the DP in this project, so it doesn't really matter.

That's it, upload the code and you should be ready to go!

Keypad image by Adafruit

Code

Keypad Display Code

Schematics

Schematic
For Common Cathode connect resistor to GND instead of 5V
Untitled iuvx22va7i

Comments

Similar projects you might like

Matrix Keypad With 7 Segment Display

by David A Riewe

  • 7,103 views
  • 1 comment
  • 9 respects

Bluetooth control led with lcd led status display real time.

Project tutorial by Youssef Sabaa

  • 17,314 views
  • 4 comments
  • 34 respects

Servo Control with TV Remote Control

Project showcase by eldo85

  • 7,085 views
  • 5 comments
  • 22 respects

Programming 4 Digit 7 Segment LED Display

by SAnwandter1

  • 88,100 views
  • 25 comments
  • 72 respects

Using 4×4 Keypad With Arduino

by Techmirtz

  • 22,596 views
  • 6 comments
  • 29 respects
Add projectSign up / Login