ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III....

41
ENGR 100 - Robotics Project
  • date post

    22-Dec-2015
  • Category

    Documents

  • view

    219
  • download

    0

Transcript of ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III....

Page 1: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

ENGR 100 - Robotics Project

Page 2: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Presentation Outline

I. Background InformationII. Design ProjectIII. Engineering (Robot Basics)

IV. Programming the RCX

Page 3: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Presentation Outline

I. Background InformationII. Design ProjectIII. Engineering (Robot Basics)

IV. Programming the RCX

Page 4: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Who Builds Robots?EE - designs “the brain”, sensors, actuators &

wiring. ME - designs body, gearing, actuators

CSE - writes software

CHEM E - designs (or selects) power supply.

MAT’L SCI - materials

All engineers listed above work together to design/build robots.

Page 5: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Robotics made easy?

Design Problem - Design and build a robot

to vacuum your house.

What are some of the challenges?

Page 6: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Design Challenges for Mobile Robots

Position -How does robot know where it is (or has been)?

Power supply - How does it avoid running over cord?

Navigation - How does it navigate around obstacles?

Object Recognition - How does it recognize money, toys, even cats?

Page 7: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Presentation Outline

I. Background InformationII. Design ProjectIII. Engineering (Robot Basics)

IV. Programming the RCX

Page 8: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Project Objectives

The goals of this project are for students to: Build a programmable robot. Learn how robotics involves a multitude of skills

and knowledge from many subject areas. Experience the design process. Be introduced to basic computer programming. Get excited about Science and Technology.

Page 9: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Problem Definition

The objective of this project is to build a computer controlled robot that can safely deliver an immobile person through an obstacle course in the shortest amount of time.

To simulate real world situations, the robot must be able to climb a small ramp, cross a street without getting hit by a car, turn corners, fight off aggressive animals, climb stairs and free itself from a sandpit.

Page 10: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Obstacle Course Layout

4 ft

4 ft

1 ft 1ft

2 ft

68”

8 ft

8 1/3 ft

Defender Free Zone

Page 11: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Programming Tasks

The RCX can store 3 different programs:

Program 1 - Robotic Wheelchair (do first!)Program 2 - CarProgram 3 - Defender (be creative!)

Page 12: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Scoring

ExT

T

Pts

PtsScore ))()((2/1 min

max

1 ft

1ft

10 pt25

pt

25 pt 10 pt 10 pt

Master controller

-  Pts-25 pts for crosswalk, 25 pts for car and 25 pts for defender (that stops wheelchair), 10 pts for each obstacle     

RANKING:

1. The competitor with the best score win the competition and to be awarded the top prize of $100 in cash!!!!!!!!!!!.

2. The WINNER's score will also get the maximum 20%.

3. The scores of all other teams will be calculated on the basis of the winner's score.

 

Page 13: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Rules (see handout for complete listing)

Robotic wheelchairs cannot be touched once competition has started.

Malfunctioning defenders and cars will be removed from course.

Max robot dimensions at start of competition - 1 ft x 1 ft x 1 ft

Wheelchairs and cars sending messages will be disqualified.

Page 14: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Design Approaches

"Top-down" design the process of starting with the goal of the

project and then developing a solution. "Bottom-up" design

the process of first learning about the available materials and then determining what can be done with them.

NEW Add “Project Planning” and “Testing” phases to design process.

Page 15: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Robotics Project Schedule

  Mon Wed Fri

Week 8 Procedure A & B- Introduction to final project- Instruction on basic gear mechanics and sensors- Inventory, training video

Procedure C- Instruction on RCX code programming - Instruction on basic gear mechanics and sensors

Procedure C - Program a pathfinder for simple tasks- Guest speakers

Week 9 - Career center visit- Pathfinder Program due

Procedure C & D- Continue programming exercise-Begin Brainstorm and Design

   Holiday

Week 10 Procedure D - Continue Brainstorm and Design- Design Specification due 

Procedure E - Continue prototype construction 

Procedure F - Trial run   

Week 11 Procedure G - Revision and Construction-Performance test due

Procedure H-        Competition-         Inventory (return robotics Invention kit)-         Final Evaluation

 

Page 16: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

ENGR 100 - Robotics Project Deliverables

HW Simple Pathfinder Test (20%) Design Specification (10%) performance test (10%- extra credit)

Final Robot - Score (30%)Group Final Report (30%)Team member’s evaluation (10%)

Page 17: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Homework Assignments

Go forward for 2.5 second (set the power at 7).Go backwards for 3 seconds (set the power at 1) - Can your robot move?Maneuver a 30 o turn. Avoid obstacles to the left, right, and between the two tactile sensors as the robot moves forward.Halt for 5 s when the light intensity reaches 50%.Stop after receiving Message 1 and move forward after receiving Message 2 from the Master Controller.

Simple Pathfinder Tasks

Page 18: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Presentation Outline

I. Background InformationII. Design ProjectIII. Engineering (Robot Basics)

IV. Programming the RCX

Page 19: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Robot Basics - Sensors & Motors

3Input/3Output Ports2Touch sensors1Light sensors3MotorsRCX signals

Tips -Use view mode to check light sensor.

Battery power affects speed of motors. Batteries run out fast! Don’t block

infrared sensor.

Page 20: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Robot Basics - Gears

SpeedTorque (climb over obstacles)Turns

Tips -Try different size gear combinations,

different types of gears (worm), and different motor placement (rear wheel drive or 4 wheel drive).

Page 21: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Example of 4 Wheel Drive

4 wheel drive

Page 22: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Robot Basics - Control Structures

No matter what language you use, there are 3 basic control structures for organizing the programming commands: Selection Repetition (Loops) Conditional

Page 23: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

SelectionSelection statements are defined

as a list of commands that are executed in order.

For example:Set Forward DirectionGo forward for 3 sStop

Page 24: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

RepetitionRepetition statements

allow for a series of commands to be repeated for a set number times.

For example:Repeat 3 times

Set forward directionMove forward for 3 sStop

End Repeat

Page 25: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

ConditionalConditional statements allow for two

(or more) different sets of commands to be executed depending on a condition.

For example, If certain conditions are true - one set of

commands will be execute. Else if any (or all) are false - another set

of commands will be executed.

Page 26: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Example of Conditional StatementsFor example -

If the light is <50% Set Direction ForwardMove Forward for 3 sStop

Else If light is >= 50%Stop

End

Page 27: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Quiz

What are the 3 types of control structures?

Which would work best for the following situations? Robotic wheelchair executes a left turn. Robot wheelchair backs up if it hits the

wall. Car moves back and forth across

crosswalk.

Page 28: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Presentation Outline

I. Background InformationII. Design ProjectIII. Engineering (Robot Basics)

IV. Programming the RCX

Page 29: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

How To: Write Programs

• Click on “Program RCX.”

• Stack puzzle pieces.

• Move unused pieces to the trash.

• Download program to the RCX.

Page 30: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

RCX Programming

Sensor Watchers: Test conditions (e.g. light, touch, count) and determine actions based on conditions.

Commands: Tell robot what to do (e.g. stop, go, turn, etc.).

Stack Controllers: Allows robot to repeat commands or wait until condition is true.

My Commands: Makes several actions a “subroutine” which can be used as a single command.

See handout for more information!

Page 31: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Demo Robot

Robot backs up for 1 s.

Both motors stop in preparation of power change.

Power increases to overcome wheel friction when turning.

Wheel A changes to forward, so robot turns to the right for .1 s.

Power decreases to protect sensors when robot bumps objects.

Wheel C changes to forward, so robot moves forward.

Page 32: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

RCX Program Code

• Commands

• Sensor Watchers

• Stack Controllers

• “My Commands”

See “Info on RCX Code” link on web site.

NEW

Page 33: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

How To: Download Firmware

Click on “getting started” and then “set up options”

Page 34: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

How To: Download Firmware

Page 35: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

How To: Download Programs

Select button to download

Select program number (1-5)

Page 36: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

How To: Save Programs

Page 37: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Features of RCX Software

Multi-threaded language Different parts of the program execute at the same

time. Can cause unexpected results! Loops in main program interfere with subprogram.

Variables limited to 1 or 0 Use counter as variable. Not quite C (NQC) language allows for more

variables.

Page 38: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

NQC (Not Quite C) Programming

See Tutorial for Robots using NQC NEW

Page 39: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Additional information

Links to homemade sensors and NCQ programming

Tips on hardware and software

Page 40: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

references

LEGO MINDSOTRMS Robot , Jonathan B. Kundsen , 1st edition, 1999, O’Reilly

http://www.crynwr.com/lego-robotics/http://www.plazaearth.com/usr/gasperi/lego

.htm#backgroundhttp://www.oreilly.com/catalog/lmstorms

/resources/index.htmlhttp://member.nifty.ne.jp/mindstorms

/Galleryhttp://www.robotbooks.com/

Page 41: ENGR 100 - Robotics Project. Presentation Outline I. Background Information II. Design Project III. Engineering (Robot Basics) IV. Programming the RCX.

Interesting Lego related websites

(many links) http://www.oreilly.com/catalog/lmstorms/resources/index.html

(interesting sites for ideas) http://member.nifty.ne.jp/mindstorms/Gallery http://www.mi-ra-i.com/JinSato/MindStorms/index-e.html http://staticip.cx/~benw/lego/ http://www.verinet.com/~dlc/botlinks.htm http://www.medialab.nl/Company/Crew/daan/legodiff.htm http://www.mindspring.com/~clagett/bill/lego/geometry/index.html http://www.robotbooks.com/ (good introduction to gear and beam construction) http://ldaps.ivv.nasa.gov/Curriculum/legoengineering.html http://www.fischermellbin.com/Marcus/Lego/Gear_Mth/gear_math.html http://phred.org/~alex/lego/ (ideas for sensors) http://www.plazaearth.com/usr/gasperi/lego.htm#background http://www.umbra.demon.co.uk/legopages.html http://www.primenet.com/~johnkit/Projects.html http://www.mnsinc.com/wesmat/TouchSensor.html http://www.daimi.au.dk/~mic/speciale/RCX http://www.crynwr.com/lego/lego-robotics/extreme-rotation-sensor.htm http://www.csepainball.com/chris/radarbot.html http://kabai.com/lego/lego.htm http://www.io.com/~woodward/lego/ ftp://ftp.eecs.umich.edu/people/johannb/pos96rep.pdf