Breaking

Site moved to https://diyusthad.com

Scaling image using ultrasonic sensor and Processing

Introduction

As our WhatsApp group member have requested we are going to scale the size of an image using the distance value acquired  from a ultrasonic sensor HC SR04. shower the distance smaller the image size and farther the distance bigger the size of image.



Construction

As you can see in the circuit connect the trigger pin of HC-SR04 sensor to digital pin 12 , echo pin to digital pin 11 and VCC of sensor to 5v of arduino and GND to GND of arduino.

 Arduino UNO 

 HC-SR04  

 Digital 12 Trigger
 Digital 11 Echo
 5V VCC
 GND GND

The Arduino code is library example with a small change, We will be needing "new ping" library to compile our Arduino code. You can download it here 

Code

Scaling image using ultrasonic sensor and Processing Reviewed by Abu Yazid on July 28, 2018 Rating: 5
All Rights Reserved by Site Moved © 2014 - 2019

Contact Form

Name

Email *

Message *

Powered by Blogger.