Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2008 Robot Programming Tips Week 4 Day 2 By Matt Gates and.

Slides:



Advertisements
Similar presentations
IRobot, Prosthetic Arm, and Rescue Robot Group 4 Adrian Burke Darren Draper Collin Palmer Max Reinisch Viyat Jhaveri Can Gurkan.
Advertisements

1/1/ / faculty of Electrical Engineering eindhoven university of technology Introduction Part 3: Input/output and co-processors dr.ir. A.C. Verschueren.
Chapter 1 - An Introduction to Computers and Problem Solving
Autonomy using Encoders Intro to Robotics. Goal Our new task is to navigate a labyrinth. But this time we will NOT use motor commands in conjunction with.
Engineering H193 - Team Project Gateway Engineering Education Coalition Spring Quarter P. 1 Drive Train Calculations Week 3 Day 1.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2006 Individual Competition Week 8 Day 2.
Engineering H193 - Team Project Spring Quarter Gateway Engineering Education Coalition P. 1 Laboratory Quiz & Data Analysis and Presentation for Written.
Engineering H193 - Team Project Spring Quarter 2005 Gateway Engineering Education Coalition P. 1 Guidelines for Flow Charts and Pseudocode (Performance.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1Spring Quarter 2007 Week 8 Day 1 Notes on Individual Competition and Visual.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1Spring Quarter 2005 Engineering H193 Project Notebook & Brainstorming Sketches.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2008 Week 6 Day 1 Lecture On and Examples Of Electrical Circuits.
Engineering H193 - Team Project Spring Quarter 2003 P. 1 Laboratory Quiz, Guidelines for Final Report Draft, Performance Test on Friday Week 5 Day 2.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2008 Individual Competition Week 8 Day 2.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2007 Individual Competition Week 8 Day 2.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2007 Guidelines for Flow Charts and Pseudocode Week 5 Day 1.
Engineering H193 - Team Project Gateway Engineering Education Coalition Spring Quarter 2005 P. 1 Drive Train Calculations Week 3 Day 1.
Engineering H192 - Computer Programming The Ohio State University Gateway Engineering Education Coalition Lect 30P. 1Winter Quarter ENG H193 & H193A Projects.
Engineering H193 - Team Project Spring Quarter 2003 P. 1 Performance Test 2 Week 4 Day 3.
Software Design Project
Engineering H193 - Team Project Gateway Engineering Education Coalition Spring Quarter 2004 P. 1 Drive Train Calculations Week 3 Day 1.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2007 Lecture on Oral Presentations Week 7 Day 1.
Engineering H193 - Team Project Spring Quarter 2005 Gateway Engineering Education Coalition P. 1 Laboratory Quiz & Data Analysis and Presentation for Written.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter Individual Competition Week 8 Day 2.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2007 Progress Reports Week 4 Day 1.
Engineering H193 - Team Project Gateway Engineering Education Coalition Final Report – An Overview Week 4 Day 2.
Engineering H192 - Computer Programming The Ohio State University Gateway Engineering Education Coalition Lect 3P. 1Winter Quarter Structured Engineering.
Engineering H193 - Team Project Gateway Engineering Education Coalition Performance Review Week 3 Day 3.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2005 Final Report – An Overview Week 4 Day 2.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2008 Laboratory Quiz & Data Analysis and Presentation for Written.
Engineering H193 - Team Project Spring Quarter2005 Gateway Engineering Education Coalition P. 1 Lecture on Oral Presentations Week 7 Day 1.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter Week 6 Day 2 Lecture on and Examples of Electrical Circuits.
Robotics- Basic On/Off Control Considerations. On/Off Control Forms the basis of most robotics operations Is deceptively simple until the consequences.
The George Washington University Electrical & Computer Engineering Department ECE 002 Dr. S. Ahmadi Class 2.
Operating System Review September 10, 2012Introduction to Computer Security ©2004 Matt Bishop Slide #1-1.
Programming Concepts (Part B) ENGR 10 Introduction to Engineering 1 Hsu/Youssefi.
Engineering H192 - Computer Programming Gateway Engineering Education Coalition Lect 30P. 1Winter Quarter H193 Project Lecture 30.
Engineering H193 - Team Project Spring Quarter Gateway Engineering Education Coalition P. 1 Data Analysis and Presentation for Written and Oral Reports.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1Spring Quarter Tips for Motors & Handy Board Care Week 3 Day 2.
Forging new generations of engineers
EEL 5666: Intelligent Machine Design Laboratory Final Presentation by Rob Hamersma April 12, 2005.
Describe the Program Development Cycle. Program Development Cycle The program development cycle is a series of steps programmers use to build computer.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter Work Day Check Robot Against Budget Work on Oral Report Work.
7.2 V battery pack and charger Put the battery in the charger station at the end of the lab. period. Red light indicates charging. Ken Youssefi Introduction.
The George Washington University Department of ECE ECE 1010 Intro: Electrical & Computer Engineering –Introducing KIPR Link/Interface and Set-up –Continuation.
Programming Design ROBOTC Software Principles of Engineering
Engineering H193 - Team Project Gateway Engineering Education Coalition Lab 1P. 1Spring Quarter Introduction to Sensors Lab 1.
Engineering H192 - Computer Programming Gateway Engineering Education Coalition Lect 29P. 1Winter Quarter Software Design Project Lecture 29.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter Final Report – An Overview Week 4 Day 2.
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.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter Observations from the Individual Competition Week 8 Day 3.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter Last Day of Class – Spring Quarter Check Grades Turn in Project.
Deriving Consistency from LEGOs What we have learned in 6 years of FLL by Austin and Travis Schuh © 2005 Austin and Travis Schuh, all rights reserved.
Engineering H193 - Team Project Spring Quarter Gateway Engineering Education Coalition P. 1 Guidelines for Flow Charts and Pseudocode Week 5 Day 1.
Automation and Robotics.  First you select the platform type so that you can use Natural Language PLTW.
Mechanical Components and Programming Ken Youssefi Introduction to Engineering – E10 1.
Engineering H193 - Team Project Spring Quarter Gateway Engineering Education Coalition P. 1 Progress Reports Week 4 Day 1.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1Spring Quarter Lab Day – Controller Lab 1 Brief Follow-up from Wednesday Grading.
Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1Spring Quarter Engineering H193 Project Notebook & Brainstorming Sketches Week.
ROBOTC for CORTEX Teacher Training © 2011 Project Lead The Way, Inc. Automation and Robotics VEX.
Presentation Outline I. Background Information II. Design Project
Programming Concepts (Part B) ENGR 10 Introduction to Engineering
Deriving Consistency from LEGOs
Programming Design ROBOTC Software Computer Integrated Manufacturing
Autonomy using Encoders
Programming Fundamentals (750113) Ch1. Problem Solving
Control Unit Introduction Types Comparison Control Memory
An Introduction to VEX IQ Programming with Modkit
Programming Design ROBOTC Software Principles of Engineering
Programming Concepts (Part B) ENGR 10 Introduction to Engineering
Presentation transcript:

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 1 Spring Quarter 2008 Robot Programming Tips Week 4 Day 2 By Matt Gates and James Beams FEH Class of 1999

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 2 Spring Quarter 2008 Robot Programming Tips

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 3 Spring Quarter 2008 Limitations of the Handy Board Limited memory (16K available for program code) Limited CPU speed Very slow floating point calculations (no floating point hardware) Limited I/O (LCD screen, 7 analog, 8 digital ports) Strategy: Code must be small, fast, and make efficient use of the resources you have.

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 4 Spring Quarter 2008 Limitations of the System Controlling a mechanical system is much different than controlling a computer! –Why? System will never run the same way twice! –System runs in real time, independent of your program. You must constantly monitor the system and ensure that what you want to happen is actually happening. –Test, test, and test some more!!!

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 5 Spring Quarter 2008 Strategies I: What NOT To Do DO NOT write one large main ( ) DO NOT write code without error checking DO NOT assume your code will work right DO NOT use lots of memory or complex algorithms DO NOT wait until the last minute to test your code

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 6 Spring Quarter 2008 Strategies II: Maintainable Code Break your code into small segments (functions) that perform specific, simple tasks. –Example: motors_half_speed ( ) Use symbolic constants (#define) instead of literals. –“motor (LEFT_SIDE, FULL_POWER)” –NOT: “motor (1, 100)” Makes it easier to update your code if you make changes to the robot design or your goals.

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 7 Spring Quarter 2008 Strategies III: Getting Around The most difficult part of your task will be getting from Point A to Point B. –Driving straight –Turning –Avoiding obstacles

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 8 Spring Quarter 2008 Strategies III: Getting Around You should spend time developing and testing a routine that allows you to move around reliably. –Use shaft encoder data to keep same RPM. –Shaft encoders can also help in turning. –Have adequate bump sensors and intelligent responses.

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 9 Spring Quarter 2008 Pseudo code Example #1 The following pseudo code example is for a ‘drive_straight’ function for a specific distance to be traveled and which corrects for uneven motor speeds.

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 10 Spring Quarter 2008

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 11 Spring Quarter 2008 Strategies IV: Break up Course The course can be handled more easily if you break it up into sections or tasks. –Ex: Determine object values, navigate to and pick up object, navigate and drop off object. Write code to handle each section separately. –Now you can test parts of the course individually. –Use the knob to select what section of code to execute.

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 12 Spring Quarter 2008 Pseudo code Example #2 The following pseudo code example breaks the course (for that year) into six routines.

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 13 Spring Quarter 2008

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 14 Spring Quarter 2008 Strategies V: Multithreading IC can run more than one functional “thread” at once. –Useful to perform background monitoring while doing main tasks. –Ex: Run “drive straight” code to make corrections to motor power while driving.

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 15 Spring Quarter 2008 Strategies V: Multithreading The more threads running, the more CPU resources used. –Can hurt IR reception, shaft encoder counts, etc. –Should keep number of threads small. See IC documentation on start_process ( ) for more info.

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 16 Spring Quarter 2008 Strategies VI: Testing Thorough testing is essential! Tips: –Begin by testing individual course sections, then combine until you can do the whole course. –Use the LCD screen to output useful values (ex. shaft encoder ticks, motor power, course side, IR output). –Make sure your robot will work even if the battery charge is low. –Don’t stop testing until the competition is over!

Engineering H193 - Team Project Gateway Engineering Education Coalition P. 17 Spring Quarter 2008 Grade Sheet for Pseudo Code / Flow Chart ITEMPOINTS Cover Page2 Introduction / Purpose2 Logic / Illustration / Description14 Modular by Function4 Completeness4 Format / Clarity / Neatness4 TOTAL30