# Max7219 Scoreboard

**URL:** <https://forum.arduino.cc/t/max7219-scoreboard/1284522>\
**Category:** Programming\
**Created:** [July 23, 2024, 4:34pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522 "2024-07-23T16:34:33Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 4:34pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/1 "2024-07-23T16:34:33Z")

</div>

I have exhausted my searching abilities. I would like to make a score board for 2 teams that just increments the score up from 0-21 with the push of a button for each team. I have follwed a guide that originates here [Arduino Scoreboard by TrevisanGMW - Thingiverse](https://www.thingiverse.com/thing:3448349) however when putting in this code I get all the max7219 leds lit up at the same time. (I have loaded other text scrolling codes to verify my wiring and understanding is correct) I have loaded the libraries and followed a wiring diagram so I'm assuming its in the code. If I can't get help thats ok I will continue trying somehow.

```arduino
// Use the MD_MAX72XX library to Print some text on the display
//
// Demonstrates the use of the library to print text.
//
// User can enter text on the serial monitor and this will display as a
// message on the display.

#include <MD_MAX72xx.h>
//#include <SPI.h>

//#define PRINT(s, v) { Serial.print(F(s)); Serial.print(v); }

// 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 MAX_DEVICES 4

#define CLK_PIN 13 // or SCK
#define DATA_PIN 11 // or MOSI
#define CS_PIN 10 // or SS
#define BUTTON_LEFT_PIN 4 // Data Pin for Left Button
#define BUTTON_RIGHT_PIN 2 // Data Pin for Right Button
long buttonTimerR = 0;
long longPressTimeR = 500;
boolean buttonActiveR = false;
boolean longPressActiveR = false;

long buttonTimerL = 0;
long longPressTimeL = 500;
boolean buttonActiveL = false;
boolean longPressActiveL = false;

// SPI hardware interface
MD_MAX72XX mx = MD_MAX72XX(CS_PIN, MAX_DEVICES);
// Arbitrary pins
//MD_MAX72XX mx = MD_MAX72XX(DATA_PIN, CLK_PIN, CS_PIN, MAX_DEVICES);

// Text parameters
#define CHAR_SPACING 1 // pixels between characters

// Global message buffers shared by Serial and Scrolling functions
#define BUF_SIZE 75
char message[BUF_SIZE] = {" 000"};
bool newMessageAvailable = true;
int currentScoreLeft = 0,
    currentScoreRight = 0;
int lastNumberPushup = 0;
bool resetBeforeFirstUse = true;
bool hasLeftDownState = true;
String howMuchSpace;

void printText(uint8_t modStart, uint8_t modEnd, char *pMsg) // ***************LED MATRIX PRINT FUNCTION***************
// Print the text string to the LED matrix modules specified.
// Message area is padded with blank columns after printing.
{
  uint8_t state = 0;
  uint8_t curLen;
  uint16_t showLen;
  uint8_t cBuf[8];
  int16_t col = ((modEnd + 1) * COL_SIZE) - 1;

  mx.control(modStart, modEnd, MD_MAX72XX::UPDATE, MD_MAX72XX::OFF);

  do // finite state machine to print the characters in the space available
  {
    switch(state)
    {
      case 0: // Load the next character from the font table
        // if we reached end of message, reset the message pointer
        if (*pMsg == '\0')
        {
          showLen = col - (modEnd * COL_SIZE); // padding characters
          state = 2;
          break;
        }

        // retrieve the next character form the font file
        showLen = mx.getChar(*pMsg++, sizeof(cBuf)/sizeof(cBuf[0]), cBuf);
        curLen = 0;
        state++;
        // !! deliberately fall through to next state to start displaying

      case 1: // display the next part of the character
        mx.setColumn(col--, cBuf[curLen++]);

        // done with font character, now display the space between chars
        if (curLen == showLen)
        {
          showLen = CHAR_SPACING;
          state = 2;
        }
        break;

      case 2: // initialize state for displaying empty columns
        curLen = 0;
        state++;
        // fall through

      case 3: // display inter-character spacing or end of message padding (blank columns)
        mx.setColumn(col--, 0);
        curLen++;
        if (curLen == showLen)
          state = 0;
        break;

      default:
        col = -1; // this definitely ends the do loop
    }
  } while (col >= (modStart * COL_SIZE));

  mx.control(modStart, modEnd, MD_MAX72XX::UPDATE, MD_MAX72XX::ON);
}

void setup() // *********************SETUP********************
{
  mx.begin();
  // Code written for IR 06H, EN not used, so jumper should be plugged.
  // initialize the pushbutton pin as an input:
  pinMode(BUTTON_LEFT_PIN, INPUT);
  pinMode(BUTTON_RIGHT_PIN, INPUT);
  //Serial.begin(9600); // Serial for debuggin, should be off on final to avoid delays
  Serial.begin(9600);
}

void loop() // *********************LOOP********************
{
  int buttonStateLeft = digitalRead(BUTTON_LEFT_PIN);
  int buttonStateRight = digitalRead(BUTTON_RIGHT_PIN);
  Serial.println(buttonStateRight);

  if (true == true) // LED Matrix Updater
  {
    String messageUpdater;

    // Space Manager
    if (currentScoreLeft <= 9 && currentScoreRight <= 9){
      howMuchSpace = " ";
    } else if (currentScoreLeft >= 10 && currentScoreRight <= 9){
      howMuchSpace = " ";
    } else if (currentScoreLeft <= 9 && currentScoreRight >= 10){
      howMuchSpace = " ";
    } else if (currentScoreLeft >= 10 && currentScoreRight >= 10){
      howMuchSpace = " ";
    } else {
      howMuchSpace = " ";
    }

    messageUpdater = String(currentScoreLeft) + howMuchSpace + String(currentScoreRight); // Creates space between numbers
    messageUpdater.toCharArray(message,10); // how many numbers to load
    printText(0, MAX_DEVICES-1, message); // update message using LED Matrix Function
    newMessageAvailable = false;
  }

  // RIGHT BUTTON CODE ******************************************************************
   if (buttonStateRight == HIGH) {
    if (buttonActiveR == false) {
      buttonActiveR = true;
      buttonTimerR = millis();
    }
    if ((millis() - buttonTimerR > longPressTimeR) && (longPressActiveR == false)) {
      longPressActiveR = true;
      currentScoreRight = 0;
      delay(300);
    }
  } else {
    if (buttonActiveR == true) {
      if (longPressActiveR == true) {
        longPressActiveR = false;
      } else {
        currentScoreRight = currentScoreRight + 1;
        delay(300);
      }
      buttonActiveR = false;
    }
  }

  // LEFT BUTTON CODE ******************************************************************
   if (buttonStateLeft == HIGH) {
    if (buttonActiveL == false) {
      buttonActiveL = true;
      buttonTimerL = millis();
    }
    if ((millis() - buttonTimerL > longPressTimeL) && (longPressActiveL == false)) {
      longPressActiveL = true;
      currentScoreLeft = 0;
      delay(300);
    }
  } else {
    if (buttonActiveL == true) {
      if (longPressActiveL == true) {
        longPressActiveL = false;
      } else {
        currentScoreLeft = currentScoreLeft + 1;
        delay(300);
      }
      buttonActiveL = false;
    }
  }
}

```

---

<div class="post-metadata">

**Author:** ![LarryD](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/larryd/32/215550_2.png) [@LarryD](https://forum.arduino.cc/u/LarryD)\
**Post date:** [July 23, 2024, 4:46pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/2 "2024-07-23T16:46:28Z")

</div>

- **Always** show us a good schematic of your proposed circuit, post it here.  
Show us good images of **your** ‘actual’ wiring.  
Give links to components.

---

<div class="post-metadata">

**Author:** ![aliarifat794](https://avatars.discourse-cdn.com/v4/letter/a/eb8c5e/32.png) [@aliarifat794](https://forum.arduino.cc/u/aliarifat794)\
**Post date:** [July 23, 2024, 5:27pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/3 "2024-07-23T17:27:50Z")

</div>

Please test the Max7219 dot matrix module with the default example given in the library. See how the display behaves.

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 5:58pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/4 "2024-07-23T17:58:54Z")

</div>

![image](https://europe1.discourse-cdn.com/arduino/original/4X/8/1/a/81a5ee070bde78e3069ec51574ee2fad693302cd.jpeg)  
 ![image](https://europe1.discourse-cdn.com/arduino/original/4X/9/1/3/913d1f1a0ea418eabea79756d7cf684e13643492.jpeg)

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 6:01pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/5 "2024-07-23T18:01:27Z")

</div>

I have run other programs such as scrolling text and everything worked accordingly.

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 6:09pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/6 "2024-07-23T18:09:47Z")

</div>

Also I did as you said and ran some examples from the libraries folder and they work.

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [July 23, 2024, 6:43pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/7 "2024-07-23T18:43:54Z")

</div>

```arduino
// Use the MD_MAX72XX library to Print some text on the display
//
// Demonstrates the use of the library to print text.
//
// User can enter text on the serial monitor and this will display as a
// message on the display.

#include <MD_MAX72xx.h>
//#include <SPI.h>

//#define PRINT(s, v) { Serial.print(F(s)); Serial.print(v); }

// 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 MAX_DEVICES 4
#define HARDWARE_TYPE MD_MAX72XX::FC16_HW

#define CLK_PIN 13 // or SCK
#define DATA_PIN 11 // or MOSI
#define CS_PIN 10 // or SS
#define BUTTON_LEFT_PIN 4 // Data Pin for Left Button
#define BUTTON_RIGHT_PIN 2 // Data Pin for Right Button
long buttonTimerR = 0;
long longPressTimeR = 500;
boolean buttonActiveR = false;
boolean longPressActiveR = false;

long buttonTimerL = 0;
long longPressTimeL = 500;
boolean buttonActiveL = false;
boolean longPressActiveL = false;

// SPI hardware interface
MD_MAX72XX mx = MD_MAX72XX(HARDWARE_TYPE , CS_PIN, MAX_DEVICES);
// Arbitrary pins
//MD_MAX72XX mx = MD_MAX72XX(DATA_PIN, CLK_PIN, CS_PIN, MAX_DEVICES);

// Text parameters
#define CHAR_SPACING 1 // pixels between characters

// Global message buffers shared by Serial and Scrolling functions
#define BUF_SIZE 75
char message[BUF_SIZE] = {" 000"};
bool newMessageAvailable = true;
int currentScoreLeft = 0,
    currentScoreRight = 0;
int lastNumberPushup = 0;
bool resetBeforeFirstUse = true;
bool hasLeftDownState = true;
String howMuchSpace;

void printText(uint8_t modStart, uint8_t modEnd, char *pMsg) // ***************LED MATRIX PRINT FUNCTION***************
// Print the text string to the LED matrix modules specified.
// Message area is padded with blank columns after printing.
{
  uint8_t state = 0;
  uint8_t curLen;
  uint16_t showLen;
  uint8_t cBuf[8];
  int16_t col = ((modEnd + 1) * COL_SIZE) - 1;

  mx.control(modStart, modEnd, MD_MAX72XX::UPDATE, MD_MAX72XX::OFF);

  do // finite state machine to print the characters in the space available
  {
    switch(state)
    {
      case 0: // Load the next character from the font table
        // if we reached end of message, reset the message pointer
        if (*pMsg == '\0')
        {
          showLen = col - (modEnd * COL_SIZE); // padding characters
          state = 2;
          break;
        }

        // retrieve the next character form the font file
        showLen = mx.getChar(*pMsg++, sizeof(cBuf)/sizeof(cBuf[0]), cBuf);
        curLen = 0;
        state++;
        // !! deliberately fall through to next state to start displaying

      case 1: // display the next part of the character
        mx.setColumn(col--, cBuf[curLen++]);

        // done with font character, now display the space between chars
        if (curLen == showLen)
        {
          showLen = CHAR_SPACING;
          state = 2;
        }
        break;

      case 2: // initialize state for displaying empty columns
        curLen = 0;
        state++;
        // fall through

      case 3: // display inter-character spacing or end of message padding (blank columns)
        mx.setColumn(col--, 0);
        curLen++;
        if (curLen == showLen)
          state = 0;
        break;

      default:
        col = -1; // this definitely ends the do loop
    }
  } while (col >= (modStart * COL_SIZE));

  mx.control(modStart, modEnd, MD_MAX72XX::UPDATE, MD_MAX72XX::ON);
}

void setup() // *********************SETUP********************
{
  mx.begin();
  // Code written for IR 06H, EN not used, so jumper should be plugged.
  // initialize the pushbutton pin as an input:
  pinMode(BUTTON_LEFT_PIN, INPUT_PULLUP);
  pinMode(BUTTON_RIGHT_PIN, INPUT_PULLUP);
  //Serial.begin(9600); // Serial for debuggin, should be off on final to avoid delays
  Serial.begin(9600);
}

void loop() // *********************LOOP********************
{
  int buttonStateLeft = !digitalRead(BUTTON_LEFT_PIN);
  int buttonStateRight = !digitalRead(BUTTON_RIGHT_PIN);
  Serial.println(buttonStateRight);

  if (true == true) // LED Matrix Updater
  {
    String messageUpdater;

    // Space Manager
    if (currentScoreLeft <= 9 && currentScoreRight <= 9){
      howMuchSpace = " ";
    } else if (currentScoreLeft >= 10 && currentScoreRight <= 9){
      howMuchSpace = " ";
    } else if (currentScoreLeft <= 9 && currentScoreRight >= 10){
      howMuchSpace = " ";
    } else if (currentScoreLeft >= 10 && currentScoreRight >= 10){
      howMuchSpace = " ";
    } else {
      howMuchSpace = " ";
    }

    messageUpdater = String(currentScoreLeft) + howMuchSpace + String(currentScoreRight); // Creates space between numbers
    messageUpdater.toCharArray(message,10); // how many numbers to load
    printText(0, MAX_DEVICES-1, message); // update message using LED Matrix Function
    newMessageAvailable = false;
  }

  // RIGHT BUTTON CODE ******************************************************************
   if (buttonStateRight == HIGH) {
    if (buttonActiveR == false) {
      buttonActiveR = true;
      buttonTimerR = millis();
    }
    if ((millis() - buttonTimerR > longPressTimeR) && (longPressActiveR == false)) {
      longPressActiveR = true;
      currentScoreRight = 0;
      delay(300);
    }
  } else {
    if (buttonActiveR == true) {
      if (longPressActiveR == true) {
        longPressActiveR = false;
      } else {
        currentScoreRight = currentScoreRight + 1;
        delay(300);
      }
      buttonActiveR = false;
    }
  }

  // LEFT BUTTON CODE ******************************************************************
   if (buttonStateLeft == HIGH) {
    if (buttonActiveL == false) {
      buttonActiveL = true;
      buttonTimerL = millis();
    }
    if ((millis() - buttonTimerL > longPressTimeL) && (longPressActiveL == false)) {
      longPressActiveL = true;
      currentScoreLeft = 0;
      delay(300);
    }
  } else {
    if (buttonActiveL == true) {
      if (longPressActiveL == true) {
        longPressActiveL = false;
      } else {
        currentScoreLeft = currentScoreLeft + 1;
        delay(300);
      }
      buttonActiveL = false;
    }
  }
}

```

 ![grafik](https://europe1.discourse-cdn.com/arduino/original/4X/b/5/d/b5de054a2fa11636058b315c87167c2992cef942.png)

my variant:

```arduino
#include <MD_MAX72xx.h>
#define MAX_DEVICES 4

#define CLK_PIN 13 // or SCK
#define DATA_PIN 11 // or MOSI
#define CS_PIN 10 // or SS
#define BUTTON_LEFT_PIN 4 // Data Pin for Left Button
#define BUTTON_RIGHT_PIN 2 // Data Pin for Right Button

MD_MAX72XX mx(2, CS_PIN, MAX_DEVICES);

#define CHAR_SPACING 2 // pixels between characters

char message[] = "88-88";

void printText(uint8_t modStart, uint8_t modEnd, char *pMsg)
// Print the text string to the LED matrix modules specified.
// Message area is padded with blank columns after printing.
{
  uint8_t state = 0;
  uint8_t curLen;
  uint16_t showLen;
  uint8_t cBuf[8];
  int16_t col = ((modEnd + 1) * COL_SIZE) - 1;

  mx.control(modStart, modEnd, MD_MAX72XX::UPDATE, MD_MAX72XX::OFF);

  do // finite state machine to print the characters in the space available
  {
    switch (state)
    {
      case 0: // Load the next character from the font table
        // if we reached end of message, reset the message pointer
        if (*pMsg == '\0')
        {
          showLen = col - (modEnd * COL_SIZE); // padding characters
          state = 2;
          break;
        }

        // retrieve the next character form the font file
        showLen = mx.getChar(*pMsg++, sizeof(cBuf) / sizeof(cBuf[0]), cBuf);
        curLen = 0;
        state++;
      // !! deliberately fall through to next state to start displaying

      case 1: // display the next part of the character
        mx.setColumn(col--, cBuf[curLen++]);

        // done with font character, now display the space between chars
        if (curLen == showLen)
        {
          showLen = CHAR_SPACING;
          state = 2;
        }
        break;

      case 2: // initialize state for displaying empty columns
        curLen = 0;
        state++;
      // fall through

      case 3: // display inter-character spacing or end of message padding (blank columns)
        mx.setColumn(col--, 0);
        curLen++;
        if (curLen == showLen)
          state = 0;
        break;

      default:
        col = -1; // this definitely ends the do loop
    }
  } while (col >= (modStart * COL_SIZE));
  mx.control(modStart, modEnd, MD_MAX72XX::UPDATE, MD_MAX72XX::ON);
}

void setup() {
  mx.begin();
  pinMode(BUTTON_LEFT_PIN, INPUT_PULLUP);
  pinMode(BUTTON_RIGHT_PIN, INPUT_PULLUP);
  printText(0, MAX_DEVICES - 1, message);
  delay(1000);
}

void loop() {
  static int currentScoreLeft = 0;
  static int currentScoreRight = 0;
  static bool OldButStaL = 1;
  static bool OldButStaR = 0;
  
  bool buttonStateLeft = !digitalRead(BUTTON_LEFT_PIN);
  bool buttonStateRight = !digitalRead(BUTTON_RIGHT_PIN);

  if ((OldButStaL != buttonStateLeft) || (OldButStaR != buttonStateRight)) {
    if (buttonStateLeft)currentScoreLeft++;
    if (buttonStateRight)currentScoreRight++;

    message[0] = currentScoreLeft / 10 + 48;
    message[1] = currentScoreLeft % 10 + 48;

    message[3] = currentScoreRight / 10 + 48;
    message[4] = currentScoreRight % 10 + 48;

    //messageUpdater = String() + howMuchSpace + String(); // Creates space between numbers
    printText(0, MAX_DEVICES - 1, message); // update message using LED Matrix Function
    OldButStaL = buttonStateLeft;
    OldButStaR = buttonStateRight;
    delay(200);
  }
}

```

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 7:07pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/8 "2024-07-23T19:07:03Z")

</div>

This was closer than anything i've had but each button increased by 2 and it repeated as if there were only 2 max7219 panels not 4. I tried doing something with chat gpt but that isn't working either.

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [July 23, 2024, 7:08pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/9 "2024-07-23T19:08:15Z")

</div>

> [@mattherberg](#):
>
> and it repeated as if there were only 2 max7219 panels not 4

show picture

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 7:09pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/10 "2024-07-23T19:09:20Z")

</div>

![image](https://europe1.discourse-cdn.com/arduino/original/4X/8/1/3/8137185c6fe5d34a99c489ed1f513e30c9f6404a.jpeg)

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [July 23, 2024, 7:11pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/11 "2024-07-23T19:11:53Z")

</div>

orientation is not same as by me

```arduino
MD_MAX72XX mx(2, CS_PIN, MAX_DEVICES);

```

try to change first number to

```arduino
GENERIC_HW, FC16_HW, PAROLA_HW, ICSTATION_HW

```

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 7:19pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/12 "2024-07-23T19:19:18Z")

</div>

I apologize, do you mean change the number "2" with GENERIC\_HW, FC16\_HW, PAROLA\_HW, ICSTATION\_HW ? I can copy and paste but not too familiar with code.

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [July 23, 2024, 7:20pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/13 "2024-07-23T19:20:31Z")

</div>

> [@kolaha](#):
>
> `GENERIC_HW, FC16_HW, PAROLA_HW, ICSTATION_HW`

yes, or just 0 or 1, or 3, bc PAROLA\_HW = 2

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 8:53pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/14 "2024-07-23T20:53:22Z")

</div>

So I plugged in your code into the wokwi and it's working perfectly. I must have a wiring issue however other projects worked just fine on the max7219. I am baffled. I am using an elegoo uno r3 which I'm assuming is the same thing as an adruino uno.

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [July 23, 2024, 9:03pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/15 "2024-07-23T21:03:15Z")

</div>

> [@mattherberg](#):
>
> however other projects worked just fine

post sketch theirs here

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 9:11pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/16 "2024-07-23T21:11:36Z")

</div>

This code scrolls "hello" across my screen just fine without changing any wiring. However I had to install the parola library. P.s. thank you so much for taking the time to look at my stuff. It means alot to me as I know no one personally (I'm even an electrician) who could could help.

```arduino
#include <MD_Parola.h>
#include <MD_MAX72xx.h>
#include <SPI.h>
 
#define HARDWARE_TYPE MD_MAX72XX::FC16_HW
//#define HARDWARE_TYPE MD_MAX72XX::GENERIC_HW
 
#define MAX_DEVICES 4
#define CS_PIN 10
 
MD_Parola myDisplay = MD_Parola(HARDWARE_TYPE, CS_PIN, MAX_DEVICES);
 
void setup() {
 
  myDisplay.begin();
  myDisplay.setIntensity(4);
  myDisplay.displayClear();
  myDisplay.displayScroll("hello", PA_CENTER, PA_SCROLL_LEFT, 200);
}
 
void loop() {
  if (myDisplay.displayAnimate()) {
    myDisplay.displayReset();
  }
}

```

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [July 23, 2024, 9:16pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/17 "2024-07-23T21:16:07Z")

</div>

ok. post#7, first sketch

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 9:26pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/18 "2024-07-23T21:26:08Z")

</div>

Yes! It started working I had 0 on left and 0 on right. Once I clicked it past 9 I got an error, but I'm thinking that I may have bumped a wire here. I need to double check my breadboard. Definitly some progress! Thank you!

---

<div class="post-metadata">

**Author:** ![mattherberg](https://avatars.discourse-cdn.com/v4/letter/m/e19b73/32.png) [@mattherberg](https://forum.arduino.cc/u/mattherberg)\
**Post date:** [July 23, 2024, 9:29pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/19 "2024-07-23T21:29:17Z")

</div>

So basically I need to figure out how to move the left number to the right 1 screen and it would be working. - edit. i was wrong this is set up correctly my bad. I think I got it from here thank you so much. If you got a venmo or something I can buy you a beer, coffee, pop (from minnesota here) Theres one from me!

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [July 23, 2024, 9:35pm UTC](https://forum.arduino.cc/t/max7219-scoreboard/1284522/20 "2024-07-23T21:35:18Z")

</div>

> [@mattherberg](#):
>
> from minnesota here

From United States of America ?

[Next page](https://forum.arduino.cc/t/max7219-scoreboard/1284522.md?page=2)
