Project tutorial

Arduinomated Car Parking with Voice Assistance in Smartphone © GPL3+

Make an assistant which tells you about how much to drive backwards without any collision through your smartphone by Arduino and 1Sheeld.

  • 4,411 views
  • 1 comment
  • 26 respects

Components and supplies

Rgdgrrzsvgslnl8hlyxx
Arduino ADK Rev. 3
×1
13959 01a
SparkFun Ultrasonic Sensor - HC-SR04
×1
1sheeld%2b%20board%20and%20app
1Sheeld+ (iOS and Android shield for Arduino)
×1
1434509556 android phone color
Android device
iOS devices can also be used on place of Android but I am using Android smartphone here.
×1
12002 04
Breadboard (generic)
×1

Apps and online services

About this project

It's a problem to take the car in reverse and many time people bump it into other cars or garage wall. My dad often ask me to assist him while parking car. But, what if you are driving alone and there is no one to assist you? There comes the Arduinomated car parking assistant which will work on 1Sheeld+ and Ultrasonic distance sensor which will tell you about how much distance is there between your car and obstacle without seeing backwards with a voice assistant; means you don't have to look backward nor into a screen.

What is 1Sheeld?

1sheeld is a stackable Arduino UNO shield used by in projects which can substitute and many components and make the work easy for wireless connections between an smartphone and the Arduino using a single App available for Android and iOS both.

Tech Specs:

  • 1Sheeld+ uses a standard HM-10 Bluetooth low energy adapter (BLE 4.0)
  • 7.37 MHz operating frequency
  • Range up to 30 feet
  • Communicates with Arduino using UART
  • Supports iOS versions starting 9.0 and up.
  • Supports Android versions starting 4.3 and up.

Note: I am assuming that almost all the people know about the Ultrasonic Distance sensor.

Building Connections

Connections for this are very easy.

  • Put the 1Sheeld+ on the Arduino Mega2560.
  • Now, connect the VCC and GND pin of the distance sensor with the 5 V and GND pin of Arduino respectively.
  • Connect echo pin to pin 11 and trigger pin to pin 13.

Download and Install the 1Sheeld App in Smartphone

  • Download the 1Sheeld app from the Playstore/iTunes.
  • Connect your smartphone to 1Sheeld via Bluetooth.
  • Select Text to Speech in the App.

Uploading the Sketch to Arduino

  • Remember to install the 1Sheeld library before you start uploading the code. Click here to get the library. You can also install it through Arduino IDE. Go to Sketch > Include Library > Manage Libraries > Enter "One Sheeld" and install the library.
  • Go to Tools > Boards > click on "Arduino Mega ADK".
  • Upload the sketch to the board.

Testing and Calibration

  • Now, test the project by using a book, cardboard, etc as an obstacle and connect the App with 1Sheeld.
  • Change the delay time in delay() function to calibrate the speech time.

Now, you can put it on the bumper of your car with tape and test it.

Sketch uses 27104 bytes (10%) of program storage space. Maximum is 253952 bytes. Global variables use 2063 bytes (25%) of dynamic memory, leaving 6129 bytes for local variables. I would suggest you to use Mega or higher board. UNO don't have much memory!

Have a good day! Try it and comment, respect and follow!

Code

Sketch - Car ParkingC/C++
/********************************************************************************
    
    2017  Techduino
    
    This sketch reads a HC-SR04 ultrasonic rangefinder and returns the
    distance to the closest object in range. To do this, it sends a pulse
    to the sensor to initiate a reading, then listens for a pulse 
    to return.  The length of the returning pulse is proportional to 
    the distance of the object from the sensor.
     
    The circuit:
    * VCC connection of the sensor attached to +5V
    * GND connection of the sensor attached to ground
    * TRIG connection of the sensor attached to digital pin 13
    * ECHO connection of the sensor attached to digital pin 11
    
********************************************************************************/
 

#include <OneSheeld.h>

#define CUSTOM_SETTINGS
#define INCLUDE_TEXT_TO_SPEECH_SHIELD

char charValue[4];  //charVal variable stores the words which are to be spoken


void setup() 
{
  OneSheeld.begin();    //starts the 1Sheeld
}

void loop() 
{
  int trigPin = 13;     //trigger pin connected to 
  int echoPin = 11;
  
  pinMode(trigPin, OUTPUT);
  pinMode(echoPin, INPUT);
  
  long duration, cm;
  
  // Read the signal from the sensor: a HIGH pulse whose
  // duration is the time (in microseconds) from the sending
  // of the ping to the reception of its echo off of an object.
  duration = pulseIn(echoPin, HIGH);
  
  // convert the time into a distance
  cm = duration / 29 / 2;

  dtostrf(cm, 4, 1, charValue);
  if (cm < 70)
    {
      TextToSpeech.say("Stop! Your are too close! Distance is ");
      delay(3500);
      TextToSpeech.say(charValue);
      delay(1300);
    }
  else if (cm > 70 && cm < 170)
    {
      TextToSpeech.say("Keep it slow! Distance is ");
      delay(3500);
      TextToSpeech.say(charValue);
      delay(1300);
    }
  else if (cm > 170)
    {
      TextToSpeech.say("Distance is ");
      delay(1500);
      TextToSpeech.say(charValue);
      delay(1300);
    }
}

Schematics

Schematics for the Car Parking Assistant
Car parking with 1sheeld schematics kjz6uyagnx

Comments

Similar projects you might like

Web-Controlled LED Animations with Raspberry Pi and Arduino

Project tutorial by Bruno Portaluri

  • 3,609 views
  • 6 comments
  • 18 respects

Valentine Blink: Wireless LED Hearts

Project showcase by AdiK

  • 1,761 views
  • 13 comments
  • 16 respects

Programming ATtiny13 with Arduino Uno

by Tauno Erik

  • 1,993 views
  • 4 comments
  • 7 respects

Solar Panel Sun Tracker - Phone Charger

Project tutorial by FIELDING

  • 9,712 views
  • 3 comments
  • 50 respects

Bluetooth Controlled Pick and Place Robot

Project tutorial by Ahmed Ebrahem Ahmed

  • 3,985 views
  • 12 comments
  • 25 respects

LEGO Wall-E with Arduino

Project tutorial by monsterbacke

  • 9,015 views
  • 7 comments
  • 56 respects
Add projectSign up / Login