I wanted to put all the Arduino projects and ESP32 projects which can be used to display the messages. I am using a free Arduino simulator. Yes, Wokwi is a free Arduino simulator, that works straight out of the browser and is easy to share projects with others. Basically, it can be on a 7 segment display, 1602 LCD, 2004 LCD, OLED, TFT displays, FastLED, matrix, PAL TV, LED bar graph more much more. If you have any suggestions or projects to be added, kindly share the project link in the comments or direct message me.
πLet us get STARted π
Project 1 - Arduino UNO and LCD1602 displayBrief introduction: This project will show you how to display a simple text message on a 1602 Liquid crystal display. Here are the details of the components needed
- LCD1602 ( 2 rows, 16 columns)
- Arduino UNO
- Connecting wires
Connection diagram
Code
// LCD1602 custom characters example
#include <LiquidCrystal.h>
LiquidCrystal lcd(12, 11, 10, 9, 8, 7);
uint8_t heart[8] = {
0b00000,
0b01010,
0b11111,
0b11111,
0b11111,
0b01110,
0b00100,
0b00000,
};
void setup() {
lcd.createChar(3, heart);
lcd.begin(16, 2);
lcd.print(" I \x03 Arduino");
}
void loop() { }
Project link: https://wokwi.com/arduino/projects/294395602645549578
Project 2 - Arduino UNO and LCD2004 displayBrief introduction: This project will show you how to display a simple text message on a 2004 Liquid crystal display. This LCD can accommodate more text and can hence function as a menu bar or even a good counter. Here are the details of the components needed
- LCD2004 ( 4 rows, 20 columns)
- Arduino UNO
- Connecting wires
Code
// LCD2004 Tiny Pacman on Wokwi
#include <LiquidCrystal.h>
LiquidCrystal lcd(12, 11, 10, 9, 8, 7);
uint8_t pacman[8] = {
0b00000,
0b00000,
0b01110,
0b11011,
0b11111,
0b01110,
0b00000,
0b00000
};
uint8_t pacmanOpen[] = {
0b00000,
0b00000,
0b01110,
0b11011,
0b11100,
0b01110,
0b00000,
0b00000
};
uint8_t dot[] = {
0b00000,
0b00000,
0b00000,
0b00110,
0b00110,
0b00000,
0b00000,
0b00000
};
void setup() {
lcd.createChar(1, pacman);
lcd.createChar(2, dot);
lcd.begin(20, 4);
lcd.setCursor(3, 0);
lcd.print("wokwi-lcd2004");
lcd.setCursor(2, 2);
lcd.print("4 lines, 20 cols");
}
void loop() {
for (int i = 3; i < 16; i++) {
lcd.setCursor(i, 3);
lcd.print("\1");
for (int j = i + 1; j < 16; j++) {
lcd.setCursor(j, 3);
lcd.print("\2");
}
lcd.createChar(1, pacman);
delay(200);
lcd.createChar(1, pacmanOpen);
delay(200);
lcd.setCursor(i, 3);
lcd.print(" ");
}
delay(1000);
}
Project Link: https://wokwi.com/arduino/projects/294590769009787402
Project 3: ATtiny85 and OLED project! Upgrade your displayBrief introduction: This project will show you how to display a simple text message on an OLED. This LCD can accommodate more text and can hence function as a menu bar or even a good counter. Here are the details of the connection
- SSD1306 display module
- ATtiny85
- Connecting wires
Connection diagram
Code
/*
Why the heart icon? Because I thought it was cool
and I want
#include <dht.h>
#include <TinyWireM.h>
#include <Tiny4kOLED.h>
void prepareDisplay() {
unsigned int i, k;
unsigned char ch[5];
oled.clear();
oled.begin();
oled.setCursor(20, 1);
oled.print(F("Hello OLED"));
}
void setup() {
oled.begin(128, 64, sizeof(tiny4koled_init_128x64br), tiny4koled_init_128x64br);
// Two fonts are supplied with this library, FONT8X16 and FONT6X8
oled.setFont(FONT8X16);
// To clear all the memory
oled.clear();
oled.on();
delay(3000);
prepareDisplay();
}
void loop() {}
Project Link:https://wokwi.com/arduino/projects/320857522224235091
Project 4: Arduino UNO and TFT LCD displayBrief introduction: This project will show you how to display a simple text message on a TFT display. This LCD can accommodate more text, graphics and can hence function as a beautiful or even a good image display. Here are the details of the connection.
Code:
/*
Simple "Hello World" for ILI9341 LCD
https://wokwi.com/arduino/projects/308024602434470466
*/
#include "SPI.h"
#include "Adafruit_GFX.h"
#include "Adafruit_ILI9341.h"
#define TFT_DC 9
#define TFT_CS 10
Adafruit_ILI9341 tft = Adafruit_ILI9341(TFT_CS, TFT_DC);
void setup() {
tft.begin();
tft.setCursor(26, 120);
tft.setTextColor(ILI9341_RED);
tft.setTextSize(3);
tft.println("Hello, TFT!");
tft.setCursor(20, 160);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.println("I can has colors?");
// Meme reference: https://english.stackexchange.com/questions/20356/origin-of-i-can-haz
}
void loop() { }
Project Link:https://wokwi.com/arduino/projects/308024602434470466
Project 5: Arduino UNO and MD Parola Library for MAX7219Background: This project will show you how to display a simple text message on a MAX7219 display. Several MAX7219 displays are concatenated. Here are the details of the connection
Code
// Use the Parola library to scroll text on the display
//
// Demonstrates the use of the scrolling function to display text received
// from the serial interface
//
// User can enter text on the serial monitor and this will display as a
// scrolling message on the display.
// Speed for the display is controlled by a pot on SPEED_IN analog in.
// Scrolling direction is controlled by a switch on DIRECTION_SET digital in.
// Invert ON/OFF is set by a switch on INVERT_SET digital in.
//
// UISwitch library can be found at https://github.com/MajicDesigns/MD_UISwitch
// MD_MAX72XX library can be found at https://github.com/MajicDesigns/MD_MAX72XX
//
#include <MD_Parola.h>
#include <MD_MAX72xx.h>
#include <SPI.h>
// set to 1 if we are implementing the user interface pot, switch, etc
#define USE_UI_CONTROL 0
#if USE_UI_CONTROL
#include <MD_UISwitch.h>
#endif
// Turn on debug statements to the serial output
#define DEBUG 0
#if DEBUG
#define PRINT(s, x) { Serial.print(F(s)); Serial.print(x); }
#define PRINTS(x) Serial.print(F(x))
#define PRINTX(x) Serial.println(x, HEX)
#else
#define PRINT(s, x)
#define PRINTS(x)
#define PRINTX(x)
#endif
// Define the number of devices we have in the chain and the hardware interface
// NOTE: These pin numbers will probably not work with your hardware and may
// need to be adapted
#define HARDWARE_TYPE MD_MAX72XX::PAROLA_HW
#define MAX_DEVICES 11
#define CLK_PIN 13
#define DATA_PIN 11
#define CS_PIN 10
// HARDWARE SPI
MD_Parola P = MD_Parola(HARDWARE_TYPE, CS_PIN, MAX_DEVICES);
// SOFTWARE SPI
//MD_Parola P = MD_Parola(HARDWARE_TYPE, DATA_PIN, CLK_PIN, CS_PIN, MAX_DEVICES);
// Scrolling parameters
#if USE_UI_CONTROL
const uint8_t SPEED_IN = A5;
const uint8_t DIRECTION_SET = 8; // change the effect
const uint8_t INVERT_SET = 9; // change the invert
const uint8_t SPEED_DEADBAND = 5;
#endif // USE_UI_CONTROL
uint8_t scrollSpeed = 25; // default frame delay value
textEffect_t scrollEffect = PA_SCROLL_LEFT;
textPosition_t scrollAlign = PA_LEFT;
uint16_t scrollPause = 2000; // in milliseconds
// Global message buffers shared by Serial and Scrolling functions
#define BUF_SIZE 75
char curMessage[BUF_SIZE] = { "" };
char newMessage[BUF_SIZE] = { "Hello! Enter new message?" };
bool newMessageAvailable = true;
#if USE_UI_CONTROL
MD_UISwitch_Digital uiDirection(DIRECTION_SET);
MD_UISwitch_Digital uiInvert(INVERT_SET);
void doUI(void)
{
// set the speed if it has changed
{
int16_t speed = map(analogRead(SPEED_IN), 0, 1023, 10, 150);
if ((speed >= ((int16_t)P.getSpeed() + SPEED_DEADBAND)) ||
(speed <= ((int16_t)P.getSpeed() - SPEED_DEADBAND)))
{
P.setSpeed(speed);
scrollSpeed = speed;
PRINT("\nChanged speed to ", P.getSpeed());
}
}
if (uiDirection.read() == MD_UISwitch::KEY_PRESS) // SCROLL DIRECTION
{
PRINTS("\nChanging scroll direction");
scrollEffect = (scrollEffect == PA_SCROLL_LEFT ? PA_SCROLL_RIGHT : PA_SCROLL_LEFT);
P.setTextEffect(scrollEffect, scrollEffect);
P.displayClear();
P.displayReset();
}
if (uiInvert.read() == MD_UISwitch::KEY_PRESS) // INVERT MODE
{
PRINTS("\nChanging invert mode");
P.setInvert(!P.getInvert());
}
}
#endif // USE_UI_CONTROL
void readSerial(void)
{
static char *cp = newMessage;
while (Serial.available())
{
*cp = (char)Serial.read();
if ((*cp == '\n') || (cp - newMessage >= BUF_SIZE-2)) // end of message character or full buffer
{
*cp = '\0'; // end the string
// restart the index for next filling spree and flag we have a message waiting
cp = newMessage;
newMessageAvailable = true;
}
else // move char pointer to next position
cp++;
}
}
void setup()
{
Serial.begin(57600);
Serial.print("\n[Parola Scrolling Display]\nType a message for the scrolling display\nEnd message line with a newline");
#if USE_UI_CONTROL
uiDirection.begin();
uiInvert.begin();
pinMode(SPEED_IN, INPUT);
doUI();
#endif // USE_UI_CONTROL
P.begin();
P.displayText(curMessage, scrollAlign, scrollSpeed, scrollPause, scrollEffect, scrollEffect);
}
void loop()
{
#if USE_UI_CONTROL
doUI();
#endif // USE_UI_CONTROL
if (P.displayAnimate())
{
if (newMessageAvailable)
{
strcpy(curMessage, newMessage);
newMessageAvailable = false;
}
P.displayReset();
}
readSerial();
}
Project link: https://wokwi.com/arduino/libraries/MD_Parola/Parola_Scrolling
Project 6: Arduino UNO and 7 segment displayBrief Introduction: 7 segment display is not a quite favourite candidate but still you can manage to display large text. hence the project. Here are the components needed:
- 4 digit, 7 segment display
- Arduino
- Connecting wires
Connection diagram
Code
/*
Displaying a string that contains a period on a seven-segment display.
Contributed by Matthew Nielsen (github.com/xunker) for the SevSeg Arduino
Library (github.com/DeanIsMe/SevSeg) by Dean Reading.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
#include "SevSeg.h"
SevSeg sevseg; //Instantiate a seven segment controller object
#define MAX_NUMBER_STRINGS 12
#define MAX_STRING_SIZE 8
char testStrings[MAX_NUMBER_STRINGS][MAX_STRING_SIZE];
#define PATTERN_CHANGE_TIME 1000
unsigned long timer = millis() - PATTERN_CHANGE_TIME;
byte testStringsPos = 0;
void setup() {
byte numDigits = 4;
byte digitPins[] = {2, 3, 4, 5};
byte segmentPins[] = {6, 7, 8, 9, 10, 11, 12, 13};
bool resistorsOnSegments = false; // 'false' means resistors are on digit pins
byte hardwareConfig = COMMON_ANODE; // See README.md for options
bool updateWithDelays = false; // Default. Recommended
bool leadingZeros = false; // Use 'true' if you'd like to keep the leading zeros
sevseg.begin(hardwareConfig, numDigits, digitPins, segmentPins, resistorsOnSegments, updateWithDelays, leadingZeros);
sevseg.setBrightness(90);
// Adds set of test strings with periods in various places
strcpy(testStrings[0], "A..BC.");
strcpy(testStrings[1], "....");
strcpy(testStrings[2], ". ");
strcpy(testStrings[3], " . ");
strcpy(testStrings[4], " . ");
strcpy(testStrings[5], " .");
strcpy(testStrings[6], ".ABC");
strcpy(testStrings[7], "A.BCD");
strcpy(testStrings[8], "A.B.CD");
strcpy(testStrings[9], "A.B.C.D");
strcpy(testStrings[10], "A.B.C.D.");
strcpy(testStrings[11], ". . . .");
}
void loop() {
// Cycle to the next string every one second
if (millis() > (timer + PATTERN_CHANGE_TIME)) {
sevseg.setChars(testStrings[testStringsPos]);
testStringsPos++;
if (testStringsPos >= MAX_NUMBER_STRINGS) testStringsPos = 0;
timer = millis();
}
sevseg.refreshDisplay(); // Must run repeatedly
}
/// END ///
Project Link: https://wokwi.com/arduino/libraries/SevSeg/stringWithPeriod
Project 7: Arduino UNO and PAL TV-- Why not! Retro love πBackground: This PAL TV project on Arduino UNO supports nice graphics and display. Here are the connection details
- Arduino UNO
- PAL TV
- Connecting wires
Code
#include <TVout.h>
#include <TVoutfonts/fontALL.h>
#include "schematic.h"
#include "TVOlogo.h"
TVout TV;
int zOff = 150;
int xOff = 0;
int yOff = 0;
int cSize = 50;
int view_plane = 64;
float angle = PI/60;
unsigned char cube2d[8][2];
void setup() {
TV.begin(PAL,120,96);
TV.select_font(font6x8);
TV.println("I am the TVout\nlibrary running on a freeduino\n");
}
void loop() {}
Connection diagram
Project Link: https://wokwi.com/arduino/projects/301776607665717769
Support/feedback/suggestions?you have many ways to ask for help, suggest a feature or share your feedback
- Open an issue on GitHub
- Visit Facebook group
- Hop on to Discord Server!
- leave a comment here π
Comments