Did some testing with 2 different codes today(changed the code in something easier for the forum):
1:
void loop(){
shiftOut(dataPin, clockPin, MSBFIRST, B00001);
digitalWrite(latchPin, HIGH);
delay(500);
digitalWrite(latchPin, LOW);
}
2:
void loop(){
shiftOut(dataPin, clockPin, MSBFIRST, B00001);
digitalWrite(latchPin, HIGH);
digitalWrite(latchPin, LOW);
delay(500);
}
As you can see the difference is the place of the delay(). I uploaded both codes, and both looks exactly the same, so i can assume it does not care where i place the delay?
]