Home » Blog » Tutorial LED Dot Matrix MAX 7219 – Bagian 1: Menampilkan Teks

Tutorial LED Dot Matrix MAX 7219 – Bagian 1: Menampilkan Teks

Tutorial LED Dot Matrix – Bagian 1: Menampilkan Teks Halo teman-teman. Ini bagian 1 dari serial tutorial LED Dot Matrix. Video ini adalah tutorial cara menampilkan teks melalui LED Dot Matrix MAX 7219.

Dokumentasi MD Parola

Parola for Arduino: MD_Parola Class Reference (majicdesigns.github.io)

Kode

// Including the required Arduino libraries
#include <MD_Parola.h>
#include <MD_MAX72xx.h>
#include <SPI.h>

// Uncomment according to your hardware type
//#define HARDWARE_TYPE MD_MAX72XX::FC16_HW
#define HARDWARE_TYPE MD_MAX72XX::GENERIC_HW

// Defining size, and output pins
#define MAX_DEVICES 4
#define CS_PIN 3

// Create a new instance of the MD_Parola class with hardware SPI connection
MD_Parola myDisplay = MD_Parola(HARDWARE_TYPE, CS_PIN, MAX_DEVICES);


void setup() {
  // Intialize the object
  myDisplay.begin();

  // Set the intensity (brightness) of the display (0-15)
  myDisplay.setIntensity(0);

  // Clear the display
  myDisplay.displayClear();


}

void loop() {

myDisplay.setTextAlignment(0, PA_CENTER);
myDisplay.write("A");
delay(2000);


}

Leave a Reply

Your email address will not be published. Required fields are marked *