"Mega based" Broadcast Video Replay System project (Shift Registers help)

Hi all

I started to make this very nice project of a hardware surface to control an existing Replay software (Slow motion and all the stuff included :slight_smile: )

I’m exited with this project because I don’t know about programming, but I jumped on it without fear because Arduino and this community can help me make it happen.

Note: “For you have an idea of how newbie I am, my first mistake was to get a Mega board… now I have to change it for a Due, because I didn’t know that the Mega can’t send out keyboard commands.”

Now the problem
5 Shift Registers for 36 Leds ( 74HC595 )
5 Shift Registers for 36 Buttons ( CD4021BE )
3 Modules for 3 OLED and LCD displays ( I2C )

This project will have 7 stages:
1- Breadboard based development surface (Done)
2- Leds (Right side wired and testing) Shift Registers
3- Buttons (Right side installed but not wired)
4- Displays (Right side installed but not wired)
5- Keyboard commands triggered by the surface buttons
6- PCB
7- Final enclosure

At the stage I am now (Leds testing) the attached code is working… but I would like to know if there is a simpler code to turn on for example the led #3 that is controlled by the shift register #1.

Please remember that the final circuit will end with 5 shift registers controlling 36 leds… now, there is only 2 wired.

Please, let me know if I’m going the right direction and what you think about the breadboard working surface I made ( I put a lot of effort to make it as clean and nice as possible… did you notice even those elastic black bands to hold the cables?.. I’m so proud :slight_smile: )

I’m posting several pics and a drawing of how will look the surface once finalized and the final selected buttons!!! (of course, now I have only those… I’m using a cheaper ones for now, will buy them when everything is ready)

Thank you in advance

Here is the “leds” code:

int datapin_leds = 23;
int clockpin_leds = 24;
int latchpin_leds = 22;
uint16_t data = 0;
void setup()
  pinMode(datapin_leds, OUTPUT);
  pinMode(clockpin_leds, OUTPUT);
  pinMode(latchpin_leds, OUTPUT);
void loop()

void shiftWrite(int desiredPin, boolean desiredState)
  digitalWrite(latchpin_leds, LOW);
  if (desiredState)
    data |= (1 << desiredPin);
    data &= ~(1 << desiredPin);
  shiftOut(datapin_leds, clockpin_leds, MSBFIRST, data >> 8);
  shiftOut(datapin_leds, clockpin_leds, MSBFIRST, data);
  digitalWrite(latchpin_leds, HIGH);
void Section2leds()
  int LedsArray[16] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15};
  shiftWrite(LedsArray[2], HIGH);


The last one is the final temporary design of how will look when finished.

Let me know what you think.