Easier digital output

Is there a quicker way I can control several digital pins without having to use "digitalWrite" every time?

If they’re all on the same port, you can use Port Manipulation, or you could put all your pin numbers in an array and loop through the array:

byte pin_numbers[] = {3, 4, 6, 7, 8, 9}

for (byte i=0;i<6;i++) {
  digitalWrite(i, HIGH);
}

However, that is slower to execute. Then, there is always copy+paste :slight_smile:

Note here that slower is a relative term and in practice you will not see any difference. This is the way to do it.

N314: Is there a quicker way I can control several digital pins without having to use "digitalWrite" every time?

Why do you want to?