Difference between revisions of "S16: Helios"

From Embedded Systems Learning Academy
Jump to: navigation, search
(Color Detection)
(Object Detection and Analysis with OpenCv and image processing)
Line 238: Line 238:
 
==== Object Detection and Analysis with OpenCv and image processing ====
 
==== Object Detection and Analysis with OpenCv and image processing ====
 
Image processing is the process of manipulating image data in order to make it suitable for computer vision applications. Computer vision helps to obtain relevant information from images and make decisions based on that information. In our project, we have used OpenCV with C++ to develop our computer vision application. OpenCV is an open source C++ library for image processing and computer vision, originally developed by Intel and now supported by Willow Garage. OpenCV has many inbuilt functions for image processing and computer vision that are mainly aimed at real-time processing.
 
Image processing is the process of manipulating image data in order to make it suitable for computer vision applications. Computer vision helps to obtain relevant information from images and make decisions based on that information. In our project, we have used OpenCV with C++ to develop our computer vision application. OpenCV is an open source C++ library for image processing and computer vision, originally developed by Intel and now supported by Willow Garage. OpenCV has many inbuilt functions for image processing and computer vision that are mainly aimed at real-time processing.
 +
  
 
===== Color Detection =====
 
===== Color Detection =====

Revision as of 06:06, 17 May 2016

Grading Criteria

  • How well is Software & Hardware Design described?
  • How well can this report be used to reproduce this project?
  • Code Quality
  • Overall Report Quality:
    • Software Block Diagrams
    • Hardware Block Diagrams
      Schematic Quality
    • Quality of technical challenges and solutions adopted.

Automated Assembly Line

This project is an automated assembly line capable to defect detection, rejection and sorting with the help of wireless communication and image processing.

Abstract

The project is an automated assembly line capable of object defect detection, object rejection and sorting with the help of image processing algorithms and wireless communication. The entire system comprises of three micro controllers (2 SJOne boards and one Raspberry pi 2). A wired interface exists between raspberry pi 2 and SJOne transmitter board, while the two SJOne boards communicate via nordic wireless. Raspberry pi 2 is equipped with a linux operating system with Open CV support to run image processing algorithms for color and shape detection. All three micro controllers are mounted to a miniature assembly line with object moving on it. The SJOne transmitter board is capable of object rejection using servo motor and IR object detector module, while the SJOne receiver board is capable of simple sorting using servo motor based on the result of object color and shape detection algorithms running on raspberry pi 2.

Objectives & Introduction

  • To design a automated assembly line with motor drive.
  • To implement nordic wireless communication on SJOne board for communication of control signals.
  • To design and implement color and shape detection algorithms using Open CV.
  • To use servo motors with mechanical parts to perform object rejection and sorting.
  • To be able to process images of objects on the belt and decide the acceptance of object for future processing on the assembly line.

There is a need for Assembly lines to incorporate intelligence to identify and reject defective products. Image processing is one of the foremost technologies responsible for achieving this intelligence. An assembly line with wireless and object detection, sorting capabilities is the prime goal of this project. The need for a wireless assembly line arises due to large wiring overhead in wired systems.

A camera captures the pictures of items that move on an Assembly line. The raspberry pi 2 board processes these pictures and assesses color and shape information and communicates to boards further down the aseembly line to take appropriate action. The SJOne transmitter board receives the information and rejects defective items from the assembly line while retaining fit items for the future stages of the assembly line. The SJOne receiver board uses servo motor to bifurcate the products into two separate belts based on color for future actions.

Team Members & Responsibilities

Kartick Parameswaran

  • OpenCV installation, Rasberry Pi environment setup, Hardware support

Anush Shankar

  • Open CV installation support, Nordic wireless communication, Stepper and servo control, Conveyor and Hardware

Sindhuja Gopalakrishnan Elango

  • Open CV algorithm design, Nordic wireless communication, Sensor implmentation, Hardware support

Akshay Dabholkar

  • Open CV algorithm design,implementation and verification, Hardware support

Schedule

This section of the report provides the team schedule for the Assembly line project, indicating the milestones to be achieved during the course of the project.

SI No. Start Date End Date Task Status Actual Completion Date
1 03/20/2016 03/29/2016
  • Discussions on overall system design and implementation.
  • Identification of parts and components required for the project.
  • Ordering components required.
  • Research on prospective image processing platforms and their feasibility.
Completed 03/29/2016
2 03/30/2016 04/05/2016
  • Familiarization with image processing tools and software(Open CV).
  • Establish speed and direction control for Motors.
  • To start building assembly line model for future integration.
Completed 04/05/2016
3 04/06/2016 04/12/2016
  • Decide on image acquisition, enhancement and basic color detection algorithm, start implementation.
  • Complete motor controls and begin wireless communication design and implementation.
Completed 04/12/2016
4 04/13/2016 04/19/2016
  • Design Image morphology detection scheme and start implementation.
  • Implementation of object sorting and rejection system.
Completed 04/25/2016
5 04/20/2016 04/26/2016
  • Verification of image processing algorithm on different objects based on color and morphology.
  • Mounting of motor controls on assembly line system and verification of design.
Completed 05/05/2016
6 04/27/2016 05/03/2016
  • Integrating image processing and other systems (sorting and rejection system, and assembly line).
  • Verification of wireless communication across individual boards.
  • Decision on safety controls for the system.
Completed 05/12/2016
7 05/04/2016 05/10/2016
  • Extensive Testing of the design with varied control signals and perform necessary calibration.
Incomplete
8 05/11/2016 05/17/2016
  • Final testing, checks and enhancements in design.
Incomplete

Parts List & Cost

Item# Part Description Vendor Qty Cost
1 Conveyer system Amazon 1 $34.62
2 IR Object detector Fry's 2 $21.78
3 Antenna - Wireless communication Amazon 2 $10.9
4 5V Stepper Motor with driver break out board Amazon 2 $11.98
5 Microsoft USB HD camera Amazon 1 $24.24
7 Wire Cutter Amazon 1 $2.99
8 Hardware Items Home Depot 1 $15.49
Total Cost $113.87

System Block Diagram

System Block Diagram

Design & Implementation

The design section can go over your hardware and software design. Organize this section using sub-sections that go over your design and implementation.

Hardware Design

Discuss your hardware design here. Show detailed schematics, and the interface here.

SJOne Board

Raspberry Pi

Conveyor Belt

Conveyor belt is a mechanical system with which materials can be transferred from one location to another. Conveyor systems are used in many industrial applications for safely transferring materials where several processing steps happen on the material when it travels on the belt. As the conveyor system is fully automated, it can be ensured to a have a uniform throughput of the deliverable. Industries thus use the conveyors for increasing their production rate. Conveyor systems are very popular in material handling, packaging, automotive, food processing and many other industries.

Basic conveyor structure
Conveyor assembly

Webcam

Nordic wireless

IR Detector

IR Detector
IR Detector Calibration
IR Detector

IR Detector OSEPP IRDET-01 detects obstacles when they are in the calibrated range. The module has 3 pins which are the ground(G), VCC(V) and Signal(S). The signal wire line is digital. It can be either high or low. High if the detected range is further than the calibrated distance, low if the detected range is less than the calibrated distance. The pins are connected to the GND, VCC and GPIO pin of the SJone board, The pin direction is set as input. When no object is detected the pin will read 0 and when object is detected the pin will read 1.

Calibration
CMPE 244 S16 Helios NoObject.png
CMPE 244 S16 Helios object.png

IR detector module device has two potentiometers that can be used to calibrate the device. One for frequency (F) and one for distance (D). Much like an IR Remote, the IR light is oscillated at a defined frequency and detected at that same frequency; this enables the sensor to work in noisy environments. The frequency of the detector module can be adjusted to avoid interference with other detectors or other IR sources. Turning the frequency potentiometer clockwise increases the frequency and turning it anti clockwise decreases the frequency.The distance at which the sensor is triggered is determined by adjusting the Distance potentiometer. When the sensor is triggered the LED will light up. Turning this pot clockwise increases the triggering distance, turning it counter-clockwise decreases the distance.

Servo Motor

Stepper Motor

Hardware Interface

The hardware interface is divided into two parts. Components that were interfaced with SJOne Master board and components that were interfaced with the SJOne Slave board. Both the SJone boards had to be mounted one on each end of the conveyor system. Decsions made by the SJone master board will be implemented by the SJOne slave board.

Building our own conveyor system

Initially it was decided to buy or rent conveyor systems and interface components to it. First option was to buy the conveyor system. On enquiring with many dealers who supplied industrial mini conveyor systems to small scale and large scale industries , it turned out that a simple system was around 1200 US dollars. Second option was to rent the conveyor belt. Renting it for a day would cost around 200 dollars. But the requirement for the project was definitely more than a day. There were development and testing phases of each component that had to be mounted with the conveyor belt and tested frequently. So the options of buying and renting were eliminated. Having an objective of building an economical automated conveyor system, the decision to self build the conveyor system was made by the team.
Nevertheless, it wasn't that easy to build a conveyor system. The conveyor system required the following

  • A rigid frame on both sides to hold the conveyor belt
  • Rotating cylinders that had to be mounted to either ends of the frame.
  • A conveyor belt that could slide on the cylinders bordered by the rigid frame

Interface with SJOne Master Board

Interface with SJOne Slave Board

Software Design

Show your software design. For example, if you are designing an MP3 Player, show the tasks that you are using, and what they are doing at a high level. Do not show the details of the code. For example, do not show exact code, but you may show psuedocode and fragments of code. Keep in mind that you are showing DESIGN of your software, not the inner workings of it.

Assembly line Mechanism

Master SJOne board Flow Sequence
Slave SJOne board Flow Sequence

Object Detection and Analysis with OpenCv and image processing

Image processing is the process of manipulating image data in order to make it suitable for computer vision applications. Computer vision helps to obtain relevant information from images and make decisions based on that information. In our project, we have used OpenCV with C++ to develop our computer vision application. OpenCV is an open source C++ library for image processing and computer vision, originally developed by Intel and now supported by Willow Garage. OpenCV has many inbuilt functions for image processing and computer vision that are mainly aimed at real-time processing.


Color Detection
Shape Detection

Implementation

This section includes implementation, but again, not the details, just the high level. For example, you can list the steps it takes to communicate over a sensor, or the steps needed to write a page of memory onto SPI Flash. You can include sub-sections for each of your component implementation.

Testing & Technical Challenges

Describe the challenges of your project. What advise would you give yourself or someone else if your project can be started from scratch again? Make a smooth transition to testing section and described what it took to test your project.

Include sub-sections that list out a problem and solution, such as:

My Issue #1

Installing OpenCV on ARM 11

Using a pre-built conveyor system

Lighting was image processing

Conclusion

Conclude your project here. You can recap your testing and problems. You should address the "so what" part here to indicate what you ultimately learnt from this project. How has this project increased your knowledge?

Project Video

Upload a video of your project and post the link here.

Project Source Code

References

Acknowledgement

Any acknowledgement that you may wish to provide can be included here.

References Used

List any references used in project.

Appendix

You can list the references you used.