NEW — Arduino Nano simulation

An interactive Arduino Nano circuit simulation you can run free in your browser on Velxio, by mark30805740.

Components

Sketch code

const int BUTTON_PIN = 2;

void setup() {
  // Start the hardware serial communication at 9600 baud
  pinMode(BUTTON_PIN, INPUT_PULLUP);
  Serial.begin(9600);
  while (!Serial);
  Serial.println("Client request:");
}

void loop() {
  bool buttonState = digitalRead(BUTTON_PIN);
  int buttcount = 0 ;
  if (buttonState == LOW) {
    Serial.print("Botton is Pressed:");
    Serial.println(buttonState);
    Serial.print("Botton Count:");
    Serial.println(buttcount++);
  } else {
    Serial.println("Botton is not Pressed!");
    Serial.print("0\n");
  }
}

More projects by mark30805740