Arduino Nano innovation for the visually impaired: smart blind stick-

  Рет қаралды 1,118

Preethi J

Preethi J

Күн бұрын

This project describes the IOT project for smart blind stick using Arduino Nano
// defines pins numbers
const int trigPin = 9;
const int echoPin = 10;
const int buzzer = 11;
const int ledPin = 13;
// defines variables
long duration;
int distance;
int safetyDistance;
void setup() {
pinMode(trigPin, OUTPUT); // Sets the trigPin as an Output
pinMode(echoPin, INPUT); // Sets the echoPin as an Input
pinMode(buzzer, OUTPUT);
pinMode(ledPin, OUTPUT);
Serial.begin(9600); // Starts the serial communication
}
void loop() {
// Clears the trigPin
digitalWrite(trigPin, LOW);
delayMicroseconds(2);
// Sets the trigPin on HIGH state for 10 microseconds
digitalWrite(trigPin, HIGH);
delayMicroseconds(10);
digitalWrite(trigPin, LOW);
// Reads the echoPin, returns the sound wave travel time in microseconds
duration = pulseIn(echoPin, HIGH);
// Calculating the distance
distance = duration * 0.034 / 2;
safetyDistance = distance;
if (safetyDistance is lesser than or equal to 5)
{
digitalWrite(buzzer, HIGH);
digitalWrite(ledPin, HIGH);
}
else {
digitalWrite(buzzer, LOW);
digitalWrite(ledPin, LOW);
}
// Prints the distance on the Serial Monitor
Serial.print("Distance: ");
Serial.println(distance);
}

Пікірлер
Arduino Based Blind Stick With GPS And GSM | Arduino Project
8:20
Just Do Electronics
Рет қаралды 16 М.
Арыстанның айқасы, Тәуіржанның шайқасы!
25:51
QosLike / ҚосЛайк / Косылайық
Рет қаралды 692 М.
12 Mind-Blowing ESP32 Projects to try in 2024!
8:50
ToP Projects Compilation
Рет қаралды 215 М.
DIY Arduino Uno Based Gas Leakage Monitoring System
4:12
Effective Ways To Detect People With Common Sensors
7:43
Core Electronics
Рет қаралды 92 М.
New USB type C Arduino Nano Comapatible Development Board Review
5:35
Smart Stick for Blind | Inspire Award Project 2023
7:21
Innovative Ideas
Рет қаралды 24 М.
A Better Way To Make Better Breadboard Jumper Wires
10:43
Brett's Basement
Рет қаралды 55 М.
Try these 16 Brilliant ESP32 projects!!!
11:18
ToP Projects Compilation
Рет қаралды 615 М.
Considering Arduino Nano? Watch this First!
7:47
Programming Electronics Academy
Рет қаралды 56 М.