Giter VIP home page Giter VIP logo

djroomba-cpre-288-final's Introduction

CPRE 288 Final Project
Group Name: DJ Roomba
Contributing Members: Ben Williams, Alex Lende, Nic Dubois, Nick Montelibano, Chris Sheafe

Project Overview
----------------

Our final goal was to develop the functionality of an automated Robot to navigate various terrain through use of a user-friendly GUI that recieves sensor data (sonar, infrared, etc) and sends commands to the Robot through bluetooth communication.

We opted to use a GUI written for MatLab to control our Robot.  The general control strategy for our
system was to send single characters from the desktop environment via a Bluetooth module on the iRobot
Create platform.  We would then block in our MatLab environment, listening for a handshake from the robot,
confirming the completion of its action, and any necessary environmental stimuli it may have encountered.
We would plot all sonar and infra-red information on a polar graph in our GUI.

Robot Functionality (Inputs, Actions and Outputs)
-------------------------------------------------

Our robot listens continously for non-null input from its USART port.  It analyses the information
recieved as an 8 bit character, and decides which action to do based on this value.

's' - Smallscan
A small scan cancels all robot movement, and reads in values from the sonar and infra-red range finder
while sweeping the stepper motor in 2 degree increments from 45 degrees to 135 degrees.  The robot
sends degrees, sonar distance and infra-red distance as a string over USART at each angle.

'S' - Bigscan
A big scan cancels all robot movement, and reads in values from the sonar and infared range finder
while sweeping the stepper motor in 2 degree increments from 0 degrees to 180 degrees.  The robot
sends degrees, sonar distance and infared distance as a string over USART at each angle.

'f' - Forward
Forward sets the robot to block while it waits for a scalar character to tell it how far forward to
move.  Our range of scalars was between a 1 and 9.  The robot would attempt to move forward a
distance equal to 10 * scalar centimeters.  It would check every wheel cycle for stimuli from the
white line sensor, the wheel drop sensor (falling in a cliff), and the right and left bumper.
If it encountered any of these, it would immediately stop and send 2 strings back to the GUI,
detailing how far it moved and which input stimuli was encountered.  If a bumper was triggered,
the robot would also immediately move backwards 10 centimers.

'b' - Backwards
Backwards set the robot to move backwards 5 centimeters, without question.  The robot ignored input
stimuli.  We needed this because otherwise the robot would have no way to move while its environment
sensors were triggered.

'l' - Turn Left
Left set the robot to block while it waited for a scalar informing how many degrees to turn.
Our range was from 1 to 9 as in the forward function.  It would turn 10 * scalar degrees to the left.
It would continuously check all input stimuli (barring bumpers) as in forward, and stop if any 
were encountered.  We ignored bumper because the robot would not change position while turning, and
we didn't want phantom data to prevent us from turning.  The robot would then send a string back to
the GUI informing the user how many degrees were turned, and which sensors were triggered, if any.

'r' - Turn Right
Right acted the exact same as Turn Left, except that the robot turned to the right.

'd' - Send Data
Send Data would simply return a string showing the current values on all of the robots input sensors.
This was useful for debugging as well as check whether we were still on a line after reversing.

'Q' - Play Song
If the robot received a 'Q', it would play a snippet of the song 'Take On Me" by Aha.  This was done
for fun and for the 5 points extra credit.  It was done when the driver(s) of the device believed it
to be in the end zone.

GUI Functionality
-----------------

Message Box
Showed the user all of the output string from both the Robot and the various
scripts used to send commands to the bot.

Buttons
Standard windows push-buttons set on the right side of the diagram.  There was a button for every function
detailed in the Robot functionality.

Input Box
Values 0 - 9 to specify rotation angle and forward distance

Graph
A radial plot of the most recent data sent by the robot.  It would plot distance over radians.

Connection Drop Down
We made a drop down menu with callbacks for either connecting to bluetooth with a baud rate of 57600
or a serial cable with a baud rate of 38400.  The drop down also gave the option to disconnect the GUI
from all connections.

djroomba-cpre-288-final's People

Contributors

ajlende avatar doobert avatar nmont avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.