Issues trying to get my teensy 3.2 with octoshield running arduino on ws2811b

Shop Forum Everything Else Issues trying to get my teensy 3.2 with octoshield running arduino on ws2811b

Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #20140
    djthaitech
    Participant

    I am following the DIY from makezine.com on how to construct your own jumbotron using ws2811b rgb led strips. I have followed the instructions, with the only differences being my project is 24 rows instead of 32, and I used 60leds/m, so my rows are 108leds each. I used quick connectors on the right side and cat5e for data runs from octoshield, I used regular 12gauge wire for power instead of cat5. My issue is only the 1st and 2nd and 13th and 14th rows are working (data goes in on 1 & 13) I am struggling to figure out how to get the other rows to work. Your time and assistance is greatly appreciated for a relative novice with regards to electrical circuits and such but I value the knowledge. Thanks in advance!

    #20143
    Dan
    Keymaster

    Does a FastLED raindow demo work if you set it to 24*108 LEDs? That will tell us if they can all light up (good wiring).

    In the Teensy sketch (https://github.com/i-make-robots/LEDWall/blob/master/Teensy/videoDisplay/videoDisplay.ino) did you adjust COLUMNS and ROWS to match your new values?

    In the Processing sketch (https://github.com/i-make-robots/LEDWall/blob/master/Processing/screenCapture/screenCapture.pde) did you change the SCREEN_WIDTH and SCREEN_HEIGHT to match?

    #20144
    djthaitech
    Participant

    So on the 2 sketches I have tried, under the OCTOWS2811 folder, Plasma and Fire, I have changed the define Cols leds to 108 (how many leds per row I have) and define rows leds to 24 and so far it gets the 1st and 2nd and 13th and 14th row to work, but none of the others. Am I supposed to change anything else in the sketch code? Would it be possible to help show me what I should change in the code for my specific project? (I am brand new to coding) I apologize for being a noob but I am trying not to get lost in the woods. Following is an example of the Plasma code Im using to get the 1-2 & 13-14 working only:

    #include <OctoWS2811.h>

    //OctoWS2811 Defn. Stuff
    #define COLS_LEDs 108 // all of the following params need to be adjusted for screen size
    #define ROWS_LEDs 24 // LED_LAYOUT assumed 0 if ROWS_LEDs > 8
    #define LEDS_PER_STRIP (COLS_LEDs * (ROWS_LEDs / 8))

    DMAMEM int displayMemory[LEDS_PER_STRIP*6];
    int drawingMemory[LEDS_PER_STRIP*6];
    const int config = WS2811_GRB | WS2811_800kHz;
    OctoWS2811 leds(LEDS_PER_STRIP, displayMemory, drawingMemory, config);

    //Byte val 2PI Cosine Wave, offset by 1 PI
    //supports fast trig calcs and smooth LED fading/pulsing.
    uint8_t const cos_wave[256] PROGMEM =
    {0,0,0,0,1,1,1,2,2,3,4,5,6,6,8,9,10,11,12,14,15,17,18,20,22,23,25,27,29,31,33,35,38,40,42,
    45,47,49,52,54,57,60,62,65,68,71,73,76,79,82,85,88,91,94,97,100,103,106,109,113,116,119,
    122,125,128,131,135,138,141,144,147,150,153,156,159,162,165,168,171,174,177,180,183,186,
    189,191,194,197,199,202,204,207,209,212,214,216,218,221,223,225,227,229,231,232,234,236,
    238,239,241,242,243,245,246,247,248,249,250,251,252,252,253,253,254,254,255,255,255,255,
    255,255,255,255,254,254,253,253,252,252,251,250,249,248,247,246,245,243,242,241,239,238,
    236,234,232,231,229,227,225,223,221,218,216,214,212,209,207,204,202,199,197,194,191,189,
    186,183,180,177,174,171,168,165,162,159,156,153,150,147,144,141,138,135,131,128,125,122,
    119,116,113,109,106,103,100,97,94,91,88,85,82,79,76,73,71,68,65,62,60,57,54,52,49,47,45,
    42,40,38,35,33,31,29,27,25,23,22,20,18,17,15,14,12,11,10,9,8,6,6,5,4,3,2,2,1,1,1,0,0,0,0
    };

    //Gamma Correction Curve
    uint8_t const exp_gamma[256] PROGMEM =
    {0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,3,3,3,3,3,
    4,4,4,4,4,5,5,5,5,5,6,6,6,7,7,7,7,8,8,8,9,9,9,10,10,10,11,11,12,12,12,13,13,14,14,14,15,15,
    16,16,17,17,18,18,19,19,20,20,21,21,22,23,23,24,24,25,26,26,27,28,28,29,30,30,31,32,32,33,
    34,35,35,36,37,38,39,39,40,41,42,43,44,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,
    61,62,63,64,65,66,67,68,70,71,72,73,74,75,77,78,79,80,82,83,84,85,87,89,91,92,93,95,96,98,
    99,100,101,102,105,106,108,109,111,112,114,115,117,118,120,121,123,125,126,128,130,131,133,
    135,136,138,140,142,143,145,147,149,151,152,154,156,158,160,162,164,165,167,169,171,173,175,
    177,179,181,183,185,187,190,192,194,196,198,200,202,204,207,209,211,213,216,218,220,222,225,
    227,229,232,234,236,239,241,244,246,249,251,253,254,255
    };

    void setup()
    {
    pinMode(13, OUTPUT);
    leds.begin();
    leds.show();
    }

    void loop()
    {
    unsigned long frameCount=25500; // arbitrary seed to calculate the three time displacement variables t,t2,t3
    while(1) {
    frameCount++ ;
    uint16_t t = fastCosineCalc((42 * frameCount)/100); //time displacement – fiddle with these til it looks good…
    uint16_t t2 = fastCosineCalc((35 * frameCount)/100);
    uint16_t t3 = fastCosineCalc((38 * frameCount)/100);

    for (uint8_t y = 0; y < ROWS_LEDs; y++) {
    int left2Right, pixelIndex;
    if (((y % (ROWS_LEDs/8)) & 1) == 0) {
    left2Right = 1;
    pixelIndex = y * COLS_LEDs;
    } else {
    left2Right = -1;
    pixelIndex = (y + 1) * COLS_LEDs – 1;
    }
    for (uint8_t x = 0; x < COLS_LEDs ; x++) {
    //Calculate 3 seperate plasma waves, one for each color channel
    uint8_t r = fastCosineCalc(((x << 3) + (t >> 1) + fastCosineCalc((t2 + (y << 3)))));
    uint8_t g = fastCosineCalc(((y << 3) + t + fastCosineCalc(((t3 >> 2) + (x << 3)))));
    uint8_t b = fastCosineCalc(((y << 3) + t2 + fastCosineCalc((t + x + (g >> 2)))));
    //uncomment the following to enable gamma correction
    //r=pgm_read_byte_near(exp_gamma+r);
    //g=pgm_read_byte_near(exp_gamma+g);
    //b=pgm_read_byte_near(exp_gamma+b);
    leds.setPixel(pixelIndex, ((r << 16) | (g << 8) | b));
    pixelIndex += left2Right;
    }
    }
    digitalWrite(13, HIGH);
    leds.show(); // not sure if this function is needed to update each frame
    digitalWrite(13, LOW);
    }
    }

    inline uint8_t fastCosineCalc( uint16_t preWrapVal)
    {
    uint8_t wrapVal = (preWrapVal % 255);
    if (wrapVal<0) wrapVal=255+wrapVal;
    return (pgm_read_byte_near(cos_wave+wrapVal));
    }

    #20145
    djthaitech
    Participant

    Would it be possible to show me which FAST led Rainbow demo you are referring to specifically, and which values I should change per my display of 24 rows of 108 leds, please? That would help me immensely to see if it is just a simple coding error or if I have an issue with my connections somewhere… Thank you again, I really appreciate it.

    #20146
    Dan
    Keymaster

    https://github.com/FastLED/FastLED

    comes with examples.

    I don’t recognize the code you’re running (did I write it?) but right away I wonder if

    config = WS2811_GRB | WS2811_800kHz;

    is what you want when you probably purchased WS2812* LEDs. The devil is in the details.

    I also wonder if LEDS_PER_STRIP matches your setup.

    #20147
    djthaitech
    Participant

    Honestly I definitely didnt write the code it was what opened when I opened the file named PlasmaAnimation in the OCTOws2811 folder of the sketches in arduino. I dont really know code so I just fixed the couple places I thought I needed to try to match my specific resolution and the rest I have no idea. so that could be my problem there if I am sending completely wrong code. I wish I could post pictures to give visual aid. Also, When i wire power supplies per diagram you have each of the 3 + and – leads splitting off to power 2 lines each, I just wired 2 12gau wires from each psu lead to line instead of splitting. does that matter? I apologize for my confusing context, I’m just stressing out trying to get this silly screen taking up my kids playroom to work so my wife will stop getting on my case about how much she hates how this project has consummed my soul. Anyway thank you so much, your original DIY on makezine is the one that gave me the confidence to go for it, even though there are like 5 different similar methods, i tried to study them all but yours was the clearest and least complicated, although I had no idea I would have to do coding, the subject scares me. lol. anyhow any advice or tips are greatly appreciated. There are lots of forums but finding he author of the diy seemed like the best. Cheers, Chris Thai, Thaitech

    #20148
    djthaitech
    Participant

    I have 24 rows of 108leds each, ws2811b rgb 5050 60/m 10mm 3 lead with teensy 3.2 on octoshield, I used cat5e to wire data (only needed 2 pairs at 12 rows ea 24 total) and used reg 12gauge wire for power aupplies instead of cat5, and 2 power supplies of 5v 60a

    #20149
    Dan
    Keymaster

    try this sketch: https://github.com/i-make-robots/LEDWall/blob/64×36-wall/Teensy/basicTest/basicTest.ino

    change

    #define COLUMNS 64 // all of the following params need to be adjusted for screen size
    #define ROWS 36 // LED_LAYOUT assumed 0 if ROWS > 8

    and post results. if you have trouble putting pictures here, try uploading them to imgur.com and then linking them here.

    #20151
    djthaitech
    Participant

    Thank you again, I have learned so much through this project about circuits and basic coding and the importance of a good quality soldering iron, especially when working with electronics.. After going through 2 cheap soldering irons I finally invested in a temperature adjustable, fine tip iron which made all the difference. I’m out of town for the weekend but will follow your instructions using the sketch you provided and post photos of the project asap. One last question, I noticed on pjrc.com on the octoshield product page, Paul Stoffregen has an example nearly identical to the makezine tutorial where he uses cat5 to feed the data to every 4 lines with the main difference being he splits the grounds from the cat5 data lines to connect to the grounds on every other row that receives power in. Does this provide any advantages or benefit the signal quality vs no common ground? Thank you again so much for your time and valuable expertise, I’m amazed at all the incredible possibilities which can be created using arduino and imagination. I think I will get a beginner’s creator kit so I can teach my 4 children ages 2-7 how they can build smart robots and learn some programming language early. Warm Regards, Chris

    #20152
    Dan
    Keymaster

    I don’t know why that many common grounds would be better. if you find out, let me know.

    #21393
    AgnusRevis
    Participant

    Anyone found a work around for this issue?

Viewing 11 posts - 1 through 11 (of 11 total)
  • You must be logged in to reply to this topic.