two MAX7219 integrated connect to programing idea.Can you help me?

Hello Dear;
I have a problem;
I want to connected two "MAX 7219" integrated, each other.
Also; I will send "32" by serial from computer to arduino,I want 32st led on.

  1. I would use the SPI interface to connect to the chips:
    D13, SCK, to CLK
    D11, MOSI, to Data IN
    D10, SS, to Load

Then have an array of 16 bytes, each byte representing one column (as drawn) of each matrix.
When a byte changes, send its data out:

digitalWrite (ssPin, LOW);
SPI.transfer(registerAddress); // 1 to 8
SPI.transfer(dataToUpdate); // the new byte, each bit is an LED, 1 = on, 0 = off
digitalWrite (ssPin, HIGH);

To send data to the second chip, you would use No-Op commands:

No-Op Register
The no-op register is used when cascading MAX7219s or MAX7221s. Connect all devices’ LOAD/CS inputs
together and connect DOUT to DIN on adjacent devices. DOUT is a CMOS logic-level output that easily
drives DIN of successively cascaded parts. (Refer to the Serial Addressing Modes section for detailed information
on serial input/output timing.) For example, if four MAX7219s are cascaded, then to write to the
fourth chip, sent the desired 16-bit word, followed by three no-op codes (hex 0xXX0X, see Table 2). When
LOAD/CS goes high, data is latched in all devices. The first three chips receive no-op commands, and the
fourth receives the intended data.

So for your case

digitalWrite (ssPin, LOW);
SPI.transfer(registerAddress); // 1 to 8 in end of chain part
SPI.transfer(dataToUpdate); // the new byte, each bit is an LED, 1 = on, 0 = off
SPI.transfer(0); // No-op register of beginning of chain part
SPI.transfer(0);
digitalWrite (ssPin, HIGH);

And you could make those 2 function calls if you wanted as well.

thank you

Hello,

I think you won't controlling different leds in use max7219.
For details, check picture.

I can't open that picture (postimg.org is blocked), there may be a little code tweaking needed.
I've only used individual CS pin to each part myself so as not to have to deal with no-ops.
Scroll Test - YouTube
Parola.h library I'm sure uses no-ops to allow large numbers of displays to be connected
https://parola.codeplex.com/

Thanks.

ledcontrol library would be simple for this