How to control Arduino LED Via Serial Communictation Using Processing
In this tutorial we will learn how to connect Arduino to Processing. We will to communication using the Serial Port. We will use the Processing Development Environment to control the Arduino. This is the first the Processing tutorial. When we will press on the left and right button the LED turn on and turn off. MY Pervious Video How to install Processing IDE https://youtu.be/PuJSNMFzfKA Arduino Code :) //please Subscribe to zeeatech youtube channel// int ledPin = 13; //define the LED pin void setup(){ pinMode(ledPin, OUTPUT); //initialize LED output Serial.begin(9600); //start the serial communication } void loop(){ if(Serial.available() > 0){ //if some data is available of in the serial port char ledPinState = Serial.read() ; //read the value if(ledPinState == '1'){ //if statement will be true(1) digitalWrite(ledPin, HIGH); //turn ON the LED } if(ledPinState == '0'){ //if...