Strict Standards: Static function Automattic\Jetpack\My_Jetpack\Product::get_name() should not be abstract in /home/kodlabaf/public_html/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php on line 141

Strict Standards: Static function Automattic\Jetpack\My_Jetpack\Product::get_title() should not be abstract in /home/kodlabaf/public_html/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php on line 148

Strict Standards: Static function Automattic\Jetpack\My_Jetpack\Product::get_description() should not be abstract in /home/kodlabaf/public_html/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php on line 155

Strict Standards: Static function Automattic\Jetpack\My_Jetpack\Product::get_long_description() should not be abstract in /home/kodlabaf/public_html/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php on line 162

Strict Standards: Static function Automattic\Jetpack\My_Jetpack\Product::get_features() should not be abstract in /home/kodlabaf/public_html/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php on line 169

Strict Standards: Static function Automattic\Jetpack\My_Jetpack\Product::get_pricing_for_ui() should not be abstract in /home/kodlabaf/public_html/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php on line 176

Strict Standards: Static function Automattic\Jetpack\My_Jetpack\Product::get_manage_url() should not be abstract in /home/kodlabaf/public_html/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php on line 183

Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /home/kodlabaf/public_html/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php:141) in /home/kodlabaf/public_html/wp-content/plugins/pe-recent-posts/pe-recent-posts.php on line 21

Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /home/kodlabaf/public_html/wp-content/plugins/jetpack/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php:141) in /home/kodlabaf/public_html/wp-content/plugins/pe-recent-posts/pe-recent-posts.php on line 21
Bluetooth Araba Hız Ayarsız – KodlaBafra

Bluetooth Araba Hız Ayarsız

Bluetooth Araba Hız Ayarsız

aad

#include <SoftwareSerial.h>  // Software Serial kütüphanesini ekledik.
SoftwareSerial bluetooth(10, 11);  // Bluetooth TX, RX pinler
 
const int solileri = 7;
const int solgeri = 6;
const int sagileri = 4;
const int saggeri = 5;
 
void setup() {
  Serial.begin(9600);    // Bilgisayar haberleşmesi başlat
  bluetooth.begin(9600);      // Bluetooth haberleşmesi başlat
  pinMode(solileri, OUTPUT);
  pinMode(solgeri, OUTPUT);
  pinMode(sagileri, OUTPUT);
  pinMode(saggeri, OUTPUT);
}
 
void loop() {
  if (bluetooth.available() > 0) {   /*Bluetooth’tan veri bekliyoruz */
    char tus = (char)bluetooth.read();
    if ( tus == 'w' ) {
      ileri();
    }
    if ( tus == 's' ) {
      geri();
    }
    if ( tus == 'a' ) {
      sol();
    }
    if ( tus == 'd' ) {
      sag();
    }
    if ( tus == 'x' ) {
      dur();
    }    
  }
 
}
 
void ileri() { // Robotun ileri yönde hareketi için fonksiyon tanımlıyoruz.
  digitalWrite(sagileri, HIGH); // Sağ motorun ileri hareketi aktif
  digitalWrite(saggeri, LOW); // Sağ motorun geri hareketi pasif
 
  digitalWrite(solileri, HIGH); // Sol motorun ileri hareketi aktif
  digitalWrite(solgeri, LOW); // Sol motorun geri hareketi pasif 
}
void sag() { // Robotun sağa dönme hareketi için fonksiyon tanımlıyoruz.
  digitalWrite(sagileri, HIGH); // Sağ motorun ileri hareketi aktif
  digitalWrite(saggeri, LOW); // Sağ motorun geri hareketi pasif

  digitalWrite(solileri, HIGH); // Sol motorun ileri hareketi aktif
  digitalWrite(solgeri, LOW); // Sol motorun geri hareketi pasif

}
void sol() { // Robotun sağa dönme hareketi için fonksiyon tanımlıyoruz.
  digitalWrite(sagileri, HIGH); // Sağ motorun ileri hareketi aktif
  digitalWrite(saggeri, LOW); // Sağ motorun geri hareketi pasif

  digitalWrite(solileri, HIGH); // Sol motorun ileri hareketi aktif
  digitalWrite(solgeri, LOW); // Sol motorun geri hareketi pasif
}
 
void geri() { // Robotun geri yönde hareketi için fonksiyon tanımlıyoruz.
 digitalWrite(sagileri, LOW); // Sağ motorun ileri hareketi pasif
 digitalWrite(saggeri, HIGH); // Sağ motorun geri hareketi aktif
 
  digitalWrite(solileri, LOW); // Sol motorun ileri hareketi pasif
  digitalWrite(solgeri, HIGH); // Sol motorun geri hareketi aktif

}
void dur() { // Robotun geri yönde hareketi için fonksiyon tanımlıyoruz.
  digitalWrite(sagileri, LOW); // Sağ motorun ileri hareketi aktif
  digitalWrite(saggeri, LOW); // Sağ motorun geri hareketi pasif

  digitalWrite(solileri, LOW); // Sol motorun ileri hareketi aktif
  digitalWrite(solgeri, LOW); // Sol motorun geri hareketi pasif

}

Yazar hakkında

Orhan Gazi DEMİRCİ administrator

1984 Samsun doğumluyum. Ondokuz Mayıs Üniversitesi Bilgisayar öğretmenliği 2007 Mezunuyum. Bafra İlçe Milli Eğitim Müdürlüğünde Fatih Projesi eğitmenliği görevinde bulunmaktayım. KodlaBafra yürütücülüğü 2017 yılından beri yürütmekteyim. Evli ve bir çocuk babasıyım.