Arduino ledcube master library not working

#include <LedCube.h>
#include <newfix.h>










#define SIZE 3
#define COLS  SIZE * SIZE

byte levelPins[SIZE] = {11,12,13};
byte colPins[COLS] = {2,3,4,5,6,7,8,9,10};

LedCube wow(SIZE, levelPins, colPins);






void setup() {
  
   
    // light each light one at a time
    for(byte level=0; level<wow.getLevels(); level++)
    {
        for(byte col=0; col<wow.getCols(); col++)
        {
            wow.lightPulse(level, col, 100);
            delay(1000);
        }
    } 

}

void loop() {
  // put your main code here, to run repeatedly:

}


When i go to upload the code it compiles without error but it does not work

Sorry about the wow., i tried changing the object to see if it would make a difference

Check your LEDs for polarity. One in each plane would stop all from lighting.

When i exclude the library from the sketch and use for loops to control the cube it actually works
I have had this same cube working with this library on a different pc and an older ide

Then you know what you need.

You do not need a library.

int led[]={2, 3, 4};

void setup() {
  for (int i = 0; i < 3; i++) {
  pinMode(led[i], OUTPUT);
  }
}

void loop() {
  for (int i = 0; i < 3; i++) {
    digitalWrite(led[i], HIGH);
    delay(300);
  }
  delay(300);
  for (int i = 0; i < 3; i++) {
    digitalWrite(led[2-i], LOW);
    delay(300);
  }
  delay(300);
}

cube

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.