Joystick Programming in Arduino

Joystick Programming in Arduino




Video Link
https://youtu.be/tPgzNT4k9WQ


Joystick







CODE
--------------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------
void setup() {

  Serial.begin(9600);
}


void loop() {
  // read the input on analog pin 0:
  int xAxis = analogRead(A0);
  int yAxis = analogRead(A1);

  // print out the value you read:
  Serial.println(xAxis);
  Serial.println(yAxis);

  delay(100);        // delay in between reads for stability
}

----------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------------------








No comments:

Post a Comment

Wifi Home automation Diy kit

 Wifi Home automation Diy kit By Manmohan Pal Wifi Home Automation Kit Hi, This is Manmohan Pal, I am glad to present a DIY kit for Home Aut...