The George Washington University Electrical & Computer Engineering Department Dr. S. Ahmadi Class 3.

Slides:



Advertisements
Similar presentations
Robofest 2005 Introduction to Programming RIS 2.0 RCX Code.
Advertisements

EducateNXT The Corridor Challenge The Corridor Challenge requires programming of a robot to negotiate obstacles and the corridor walls in order to reach.
The George Washington University Electrical & Computer Engineering Department ECE 002 Dr. S. Ahmadi Lab 1.
Group Four Catherine Fahey, Steven Falzerano, Nicollette Fernandez, Eliot M. Fine and Stefan Toubia.
Photos and Sensor Instructions
Using the NXT Light Sensor. 2 Connect One Light Sensor – 1 From My Files use Left / Right NXT buttons and get to View menu and push Orange button. From.
Robot Programming. Programming Behaviors Behaviors describe the actions and decisions of your robot.
Group 6 Taylor Gould, Olivia Graffis, Taylor Guidon and Bdho Gdeh.
 Project 1: To build and program a robot that will follow a solid black line, make a U-turn, and follow the line back to the start.  Project 2: To understand.
BEGINNER EV3 PROGRAMMING Lesson
UltraSonic Orchard fertilizer Dispensing Automaton Erik Mueller & Patrick Thurston.
UltraSonic Orchard fertilizer Dispensing Automaton Erik Mueller & Patrick Thurston.
©2006 CSUC Institute for Research in Intelligent Systems Introduction to Coding June 15, 2006.
LEGO Mindstorms NXT Programming We will be using the Common Palette for our Robots This is how you download your program onto the brick Drag and drop a.
The George Washington University Electrical & Computer Engineering Department ECE 002 Dr. S. Ahmadi Class 1.
The George Washington University Electrical & Computer Engineering Department ECE 002 Dr. S. Ahmadi Class 2.
Lego Robot Construction Project. Adam, Roger, Lu, Riana, Paul.
Members (from left to right): Rachel Bevill, Brae Bower, Samantha Cherbonneau, Professor Ahmadi, Anthony Contreras.
The George Washington University Department of ECE ECE Intro: Electrical & Computer Engineering Dr. S. Ahmadi Class 3.
The Batmobile and Centrifuge November 11, Members (from left to right): Rachel Bevill, Brae Bower, Samantha Cherbonneau, Professor Ahmadi, Anthony.
Programming a light sensor to follow a black line.
Forging new generations of engineers
Today’s Agenda 1.Scribbler Program Assignment 1.Project idea due next class 2.Program demonstration due Wednesday, June 3 2.Attendance & lab pair groupings.
Robotics Light sensor. Calibration. Reverse engineering challenge. Lab work: Create and show your program. Add light sensor (different orientations). Robot.
The George Washington University Department of ECE ECE Intro: Electrical & Computer Engineering –Intro to the Robotics –Introducing the IC –Discuss.
The George Washington University Department of ECE ECE 1010 Intro: Electrical & Computer Engineering –Introducing KIPR Link/Interface and Set-up –Continuation.
A note on oral presentations These are the progress report presentations. Please note that the individual presentations should be ~8 min long. Since the.
Wall Encounter By Made easy by Dwayne Abuel.
Negative Power or Negative Rotation makes robot go backwards. But if both are negative, the robot will go forward! Move Steering Block.
The George Washington University Department of ECE ECE Intro: Electrical & Computer Engineering Dr. S. Ahmadi Class 4.
Erin Halseth, Will Gottschalk, Briana Warschun, and Michaella Gaines
Title Slide Progress Report Name. Goal Goal Statement – ex. design/create/fabricate … - should be clear and short Needs/Problems – clear and short Space.
Find the Mindstorms Icon on the computer.. To start a new program click go.
By Eric Greene RMS / I. S. 192 Q. Smart Start Question How would you get the robot to flirt with disaster by touching the edge of the “table” as many.
Robot Programming. Programming Behaviors Behaviors describe the actions and decisions of your robot.
ECE Project 1 Overview. Project Description The aim of this project is to design a robot that moves along a given path, from the Start point, towards.
The George Washington University Department of ECE ECE Intro: Electrical & Computer Engineering Dr. S. Ahmadi Class 4/Lab3.
The George Washington University Electrical & Computer Engineering Department ECE 002 Dr. S. Ahmadi Class3/Lab 2.
ECE 002 Robots and Sensors Group 14. Objectives Research sensors and their usefulness to analyze data Research sensors and their usefulness to analyze.
EV3 Software EV3 Robot Workshop
Programming 101 The Common Palette Content provided by Connor Statham (9 th Grade Student) Formatting by Shannon Sieber.
ROBOTC Software EV3 Robot Workshop
BEGINNER FLL PROGRAMMING WORKSHOP BY DROIDS ROBOTICS & EV3LESSONS.
1 The George Washington University Electrical & Computer Engineering Department ECE 1010 Intro To Electrical and Computer Engineering Dr. S. Ahmadi Class.
Casne.ncl.ac.uk Taking care of the CrumbleBot Please do NOT stress the robot's motors 1.Do NOT push the robot 2.Do NOT hold the.
Robotics Programming Wall Follow Line tracking for a set amount of time Line tracking for a distance.
The George Washington University Department of ECE ECE Intro: Electrical & Computer Engineering Dr. S. Ahmadi Class 4.
Programming Design ROBOTC Software Principles Of Engineering
The Corridor Challenge
The George Washington University Department of ECE ECE Intro: Electrical & Computer Engineering Intro to the Robotics Introducing the IC Discuss.
ROBOTC for VEX On-Site Professional Development
Introducing KIPR Link/Interface and Set-up
Electrical Engineer Responsibilities
Programming Design ROBOTC Software Computer Integrated Manufacturing
Programming Concepts (Part B) ENGR 10 Introduction to Engineering
Music by Touch Music by Touch Presentation > TeachEngineering.org
Module F: Presentation Understanding Robot Fundamentals
Forward Until Touch Robot goes forward until it hits a wall.
Line Following Behavior
The George Washington University Department of ECE ECE Intro: Electrical & Computer Engineering Dr. S. Ahmadi Class 5.
Switch Blocks check a value and choose a path based on that value
The George Washington University Department of ECE ECE Intro: Electrical & Computer Engineering Dr. S. Ahmadi Class 4.
Programming Design ROBOTC Software Principles Of Engineering
The Basics Subtitle.
“self-maneuvering miniature vehicle”
Automation with RobotC
The George Washington University Department of ECE ECE Intro: Electrical & Computer Engineering Dr. S. Ahmadi Class 4.
Automation with RobotC
Programming Design ROBOTC Software Principles of Engineering
Oregon Robotics Tournament and Outreach Program
Presentation transcript:

The George Washington University Electrical & Computer Engineering Department Dr. S. Ahmadi Class 3

Agenda Introduce and Discuss Light Sensor Project –Course Layout –Project Description Discussion on Programming Required for Project –Flow Chart of Program Flow –Sample Code

Light Sensor Project Course Layout 2m Start Finish

Project Description The aim of this project is to design a robot that moves along a given path, from the Start point, towards the Finish line. The thick black line acts as the guide for the robot to follow. As an optional element to the project, after reaching the finish line, the robot should turn around, and go back along the path it came to the starting point. Robot will be judged on smoothness of journey, and robot design. It is the student responsibility to make sure that the Handy Board is fully charged Each group will have one chance to demonstrate their project to the judges. Therefore, fully test your project before demonstration.

Diagram of Robot with Light Sensor RO BOT Right LIGHT SensorLeft LIGHT Sensor When RIGHT sensor senses black line turn right (and vice-versa)

Discussion on Programming Required for Project

Block Diagram For a Right Turn Go Forward Turn Right Yes No Turn Right?

Flow Chart to Code for Turning Right Go Forward Turn Right Yes No Turn Right? while (true) { // go forward motor ( 1, 100 ) ; motor ( 3, 100 ) ; // should we turn right? if ( analog(4) > 200 ) { // turn RT, until off black tape ao() ; while (analog(4) > 200) motor (3, 100) ; } Flow Chart C Code Implementation of Flow Chart

Block Diagram For a Right Turn or Left Turn Go Forward Turn Right Right turn? Yes No Left turn? Turn Left Yes No

Block Diagram for a Complete System Go Forward Turn Right Right turn? Yes No Left turn? Turn Left Yes No Left turn? STOP Yes No

Sample Program void main() { int sensor1, sensor3, Flag=1; printf("Press Start button to begin:"); while(start_button()==0); // Waits for start button to be pressed. while(Flag==1) { sensor1=analog(4); // Reads the signal coming from analog port 4. sensor3=analog(6); // Reads the signal coming from analog port 6. motor(1, 10); // GO FORWARD. motor(3, 10);

if(sensor1>200) // RIGHT TURN?? { // If Yes then…. if(sensor3>200) // …LEFT TURN?? { // ao(); // Flag=0; // If YES then STOP!!! } else // Right turn = yes BUT Left turn = no, then... { ao(); sleep(2.0); while(analog(4)>200) // Turn RIGHT!! { motor(3,100); }

else if(sensor3>200) // LEFT TURN???? { ao(); sleep(2.0); while(analog(6)>200) // TURN LEFT { motor(1,100); }

Optional Portion of Project As an optional objective, we wish to make the robot U-turn, and go back along the path to the starting point. This can be carried out in the following way: –After sensing a black surface on BOTH light sensors, the robot stops, and then starts to rotate in either direction. –The robot rotates until the first sensor senses the black line, it CONTINUES rotating, but stops once the second sensor detects the black line. –Once the rotation has been completed, the robot moves along the line in the same way as in the main part of the project until it reaches the start line.