digitalWrite()

Write a HIGH, or a LOW, value to a digital pin. If the pin has been configured as an OUTPUT with pinMode, its voltage will be set 3.3V for HIGH, GROUND for LOW. If the pin is configured as an INPUT, digitalWrite() will enable (HIGH) or disable (LOW) the internal pullup on the input pin. It is recommended to set the pinMode() to INPUT_PULLUP to enable the internal pull-up resistor. Check Z-Uno pinout digitalWrite(pin, value) pin the pin number value HIGH or LOW none Automatically changes pin mode to OUTPUT as pinMode(pin, OUTPUT) was called.
void setup() {
    pinMode(8, OUTPUT);      // sets the digital pin as output
}

void loop() {
    digitalWrite(8, HIGH);        // sets the LED on
    delayMicros(4000);                  // waits for four seconds
    digitalWrite(8, LOW);         // sets the LED off
    delay(4000);                  // waits for four seconds
}
Z-Uno pin control is pretty slow, typical digitalWrite() call will take itself about 1 ms. Hence it is not possible to do fast pin operations except on pins 9–16 that allows special "fast mode". To use this fast mode one need to specify pin number via s_pin variable type. Z-Uno compiler will detect it and use fast mode for such digitalWrite() calls. In this case the call will take about 1–2 μs for indirect call (via function) and 0.5 μs for direct (see example below).
s_pin my_pin = 9;

void setup() {
  pinMode(my_pin, OUTPUT);
}	

void blinkWithPin(s_pin pin) {
  pinMode(pin, OUTPUT);
  digitalWrite(pin, 0);
  delayMicroseconds(100);
  digitalWrite(pin, 1);
  delayMicroseconds(100);
  digitalWrite(pin, 0);
}

void loop() {
  byte another_pin;
  digitalWrite(my_pin, 0);    // direct call is possible
    
  another_pin = 10;
  blinkWithPin(another_pin);  // or call via function
}