Posts

CHATBOT programming tutorial in tamil

Image
PYTHON CODING import webbrowser import smtplib import random from datetime import datetime  import os import sys #from weather import Weather import urllib import requests #import urllib2 import time from bs4 import BeautifulSoup import speech_recognition as sr from playsound import playsound import wikipedia import urllib3 import pyttsx3 #from googlesearch import search engine = pyttsx3.init('dummy') voices = engine.getProperty('voices') engine.setProperty('voice', voices[len(voices)-1].id) def speak(audio):     print('Computer: ' + audio)     engine.say(audio)     engine.runAndWait() def greetMe():     now=datetime.now()     currentH = int(now.strftime("%H"))     if currentH >= 0 and currentH < 12:         speak('Good Morning!')     if currentH >= 12 and currentH < 18:         speak('Good Afternoon!')     if currentH >= 18 and currentH !=0:         speak('Good E

how to make pic and pot robot (robotic arm) in tamil

Image
Coding For Pic and Pot #include <Servo.h> String servo; String val; int value; Servo bottomservo; Servo handservo1; Servo handservo2; Servo clipservo; void setup() {   Serial.begin(9600);   bottomservo.attach(6);    handservo1.attach(9);    handservo2.attach(10);    clipservo.attach(11);     } void loop() {   if (Serial.available())   {     servo  = Serial.readStringUntil(',');     Serial.read();      val  = Serial.readStringUntil('\0');     value = val.toInt();     Serial.println(servo);   }   if(servo == "1")   bottomservo.write(value);    else if(servo == "2")   handservo1.write(value);   else if(servo == "3")   handservo2.write(value);   else if(servo == "4")   clipservo.write(value); } *****************************************************************************
Nodemcu and DHT11 coding #include <dht.h> #include <AdafruitIO_WiFi.h> #include <ESP8266WiFi.h> #include <Ticker.h> #define DHT11_PIN 2 #define IO_USERNAME  "*******"//replace your user name #define IO_KEY       "***********" //replace your key #define WIFI_SSID       "********"//replace your hotspot name #define WIFI_PASS       "********"//replace your hotspot password AdafruitIO_WiFi io(IO_USERNAME, IO_KEY, WIFI_SSID, WIFI_PASS); dht DHT; AdafruitIO_Feed *humidity = io.feed("*******");//replace your feed1 name AdafruitIO_Feed *temperature = io.feed("*****");//replace your feed2 name void setup(){   Serial.begin(9600);     Serial.println("DHT11 Humidity & temperature Sensor\n\n");   Serial.print("Connecting to Adafruit IO");   io.connect();      while(io.status() < AIO_CONNECTED) {     Serial.print(".");     delay

RF controlled car making in tamil

Image
coding void setup() { pinMode(2,OUTPUT); // in1 pinMode(3,OUTPUT); // in2 pinMode(4,OUTPUT); // in3 pinMode(5,OUTPUT); // in4 pinMode(7,INPUT); // RF in1 pinMode(8,INPUT); // RF in2 pinMode(9,INPUT); // RF in3 pinMode(10,INPUT); // RF in4 Serial.begin(9600); } void loop() {   int RF1, RF2, RF3, RF4;   RF1 = digitalRead(7);   RF2 = digitalRead(8);   RF3 = digitalRead(9);   RF4 = digitalRead(10);     if(RF1) //forward     {       digitalWrite(2,HIGH);       digitalWrite(3,LOW);       digitalWrite(4,HIGH);       digitalWrite(5,LOW);       Serial.println("0");     }     if(RF2) //backward     {       digitalWrite(2,LOW);       digitalWrite(3,HIGH);       digitalWrite(4,LOW);       digitalWrite(5,HIGH);       Serial.println("1");     }     if(RF3) //right     {       digitalWrite(2,HIGH);       digitalWrite(3,LOW);       digitalWrite(4,LOW);       digitalWrite(5,HIGH);       Serial.println("2");     }     if(RF4)//le

Arduino controlled RC car making in tamil

Image
Coding void setup() { pinMode(2,OUTPUT); //in1 pinMode(3,OUTPUT); //in2 pinMode(4,OUTPUT); //in3 pinMode(5,OUTPUT); //in4 Serial.begin(9600); } void loop() {   if(Serial.available()>0)   {     char cmt = Serial.read();     Serial.println(cmt);         if(cmt == '0') //forward     {       digitalWrite(2,HIGH);       digitalWrite(3,LOW);       digitalWrite(4,HIGH);       digitalWrite(5,LOW);       Serial.println("0");     }     else if(cmt == '1') //backward     {       digitalWrite(2,LOW);       digitalWrite(3,HIGH);       digitalWrite(4,LOW);       digitalWrite(5,HIGH);       Serial.println("1");     }     else if(cmt == '2') //right     {       digitalWrite(2,HIGH);       digitalWrite(3,LOW);       digitalWrite(4,LOW);       digitalWrite(5,HIGH);       Serial.println("2");     }     else if(cmt == '3')//left     {       digitalWrite(2,LOW);       digitalWrite(3,HIGH);       digitalWrite(4,HIGH);       digitalWrite(5,LOW

using millis() in ultrasonic sensor program in tamil

Image
Coding #define trig 5 #define echo 4 void setup() {   Serial.begin(9600);   pinMode(trig,OUTPUT);   pinMode(echo,INPUT);   pinMode(13,OUTPUT);   pinMode(12,OUTPUT);   digitalWrite(12,HIGH);   delay(2000); } void loop() {   digitalWrite(13,HIGH);   digitalWrite(12,LOW);   delay(1000);   digitalWrite(13,LOW);   digitalWrite(12,HIGH);   delay(2000);     long duration , distance;     digitalWrite(trig,LOW);   delay(2);   digitalWrite(trig,HIGH);   delay(2);   digitalWrite(trig,LOW);     duration= pulseIn(echo,HIGH);   distance=(duration/2)/29.1;   Serial.println(distance); }

Arduino - millis() in tamil

Image
arduino with 2 led blink using millis int period = 2000; unsigned long time_now = 0; unsigned long time_now2 = 0; int led_state1 = false; int led_state2 = false; void setup() {   pinMode(13,OUTPUT);   pinMode(12,OUTPUT);   Serial.begin(9600); } void loop() {   if(millis() > time_now + period){     time_now = millis();     led_state1 = !led_state1;     digitalWrite(13,led_state1);   }    if(millis() > time_now2 + 1000){     time_now2 = millis();     led_state2 = !led_state2;     digitalWrite(12,led_state2);      }    }