Tekko BDSimSimulatorProjects

Servo এদিক-ওদিক ঘোরানোServo Motor Arduino Code & Circuit (SG90)

Servo library কোণ পাঠায়; SG90 ০° থেকে ১৮০° পর্যন্ত যায় আবার ফিরে আসে। Step বা delay বদলে দেখো কেমন নড়ে।

The Servo library sends the angle; the SG90 sweeps from 0° to 180° and back. Change the step or delay and watch the horn move.

▶ ফ্রি চালিয়ে দেখো / Run it free Parts অর্ডার করো (WhatsApp)

যা যা লাগবে · Parts you need

তার লাগানো · Wiring

Servo motor (SG90) VCC→Arduino Uno 5V
Servo motor (SG90) GND→Arduino Uno GND
Servo motor (SG90) SIG→Arduino Uno D9

Code (Arduino C++)

#include <Servo.h>
Servo myServo;

void setup() {
  myServo.attach(9);
}

void loop() {
  for (int a = 0; a <= 180; a += 5) { myServo.write(a); delay(30); }
  for (int a = 180; a >= 0; a -= 5) { myServo.write(a); delay(30); }
}

ভিডিও · Videos

Servo motor sg90 full bangla tutorial with coding (বাংলা)Arduino tutorial 7- How to control Servo motor with Arduino (code explained) | using serv…

আরো project · More projects