Presentation is loading. Please wait.

Presentation is loading. Please wait.

Robotics Abstractions: Levels of language, world view

Similar presentations


Presentation on theme: "Robotics Abstractions: Levels of language, world view"— Presentation transcript:

1 Robotics Abstractions: Levels of language, world view
Introduction to Lego Mindstorms Build basic robot Write & download program Homework: postings

2 Levels of language Distinguish between
task: what you want to do procedure: how you/your program directs robot to do it Even procedure level distinguishes between moving robot joints to get to an endpoint vs moving robot joints

3 World view What does the robot (you?) know about the work area?
What are assumptions / constraints? Related to: how robust is it necessary to make the program / strategy

4 Levels of language: Task level
[Unconstrained]: block A somewhere on table, block B somewhere on table PUT BLOCK A ON BLOCK B [More constrained]: block A a specific place on the table, block B a specific place

5 Levels of language: Procedure
[Unconstrained]: block A somewhere on table, block B somewhere on table LOCATE BLOCK A LOCATE BLOCK B PICK UP BLOCK A MOVE BLOCK A OVER TO CALCULATED POSITION ABOVE B MOVE BLOCK A TO CALCULATED POSITION ON B [More constrained]: block A a specific place on the table, block B a specific place MOVE BLOCK A OVER TO ABOVE BLOCK B MOVE BLOCK A DOWN UNTIL CONTACT

6 Levels of Language: joints, sensors, etc.
[Unconstrained]: block A somewhere on table, block B somewhere on table Invoke vision system to locate block A and block B OR invoke search program …. Calculate joint positions for path to get to block A Calculate gripping position Set joints so as to move block A over to calculated position above B Set joints so as to move/lower block A…possibly do move until touch [More constrained]: block A a specific place on the table, block B a specific place

7 Language, world view My choices of levels of language (task, procedure, robot joints) not the only ones Can pose higher levels and lower levels! These are general concepts to keep in mind. Will return to it.

8 Assembly is …. Challenging Concept of ‘preserving orientation’
Locating parts Calculating trajectories Allowing for variability Concept of ‘preserving orientation’

9 Exercise[s] Pick task and describe in task terms and in procedural terms (Shoe tying) Opening/unwrapping gift Put on coat Sharpening a pencil using automatic or manual pencil sharpener Cooking scrambled eggs Building the basic Mindstorms robot! ANSWER this on moodle!!!!

10 Lego parts Electronic Structural Connectors Gears Miscellaneous
the Brick, motors, sensors, cables Structural beams, other Connectors some friction, some smooth Gears transfer and/or change torque Miscellaneous tires, Lego people, other

11 NXT-G Level of language is low.
Note: considerable computation at motors and sensors You/your NXT-G program direct tribot actions directly: procedure, not task. Preview: Task: hit the red ball You will program: Procedure: move forward using certain motors until certain sensor indicates time to stop check light level to determine which ball if red ball, move arm motor to swing

12 Lego Mindstorm NXT Create program using drag-and-drop of “blocks”
Iconic form of programming Each icon/block has its own set of settings (parameters) and (possibly) data links to be set Add comments. File/Save As (…save) Then download program to NXT brick Compile and download. Any syntactic errors will be caught. Missing data link Failure if lack of space on the NXT brick Will need to be conscious of space

13 Move block: initial setting
Motors B & C 75% power 1 Rotation Brake after 1 rotation (not coast)

14 Important fact… You (the builder of the robot) must make sure that motor B and motor C do what you want. This depends on Where/how you build What port External conditions The program doesn’t know anything. It just sends a signal to a port.

15 Direction now set to curve
Power at 25% 5 seconds Coast after 5 seconds

16 How… Do you get robot to travel specific distance?
Use trial-and-error to set time or rotations Use feedback: keep computer connected to NXT and monitor rotations Next class!

17 Data links: input & output
Feedback information

18 Sound block built-in sounds + capability for individual tones & sound files WARNING: sound files are big.

19 Build Basic robot NXT brick serves as main chassis
Carried around by wheels operated by 2 motors Attached to appropriate ports Will add Grabber Sensors More programs

20 Today’s challenge Build basic robot Program to Go forward,
Say “Have a nice day” , Turn around in a curve Go back

21 Program has been saved on computer File/Save Used comment writer to document action Program consists of Move block Sound block Move block (turning)

22 Comment Blocks may Do something Start something
Make sound and wait for completion versus… Turn motors for X rotations/degrees/seconds Start something Start sound Turn motors on unlimited (will do this next class) Actually, mostly blocks: Try to do something Motors try to turn in rough terrain….

23 Go! Use directions in the kit. DON’T MIX PARTS. DON’T LOSE PARTS.
Page 8 to 22 which is Steps 1 to 17 NOTE: step 14: putting in batteries has already been done These kits use Lithium battery, which needs to be charged up. Turn on and try demo program Write program and download DON’T MIX PARTS. Be careful: especially with small pieces DON’T LOSE PARTS. Need to be careful that cables are not in the way! Make haste slowly.

24 Team work For this activity: everyone should be aware of all details.
Take turns. Don’t assume you can’t do anything. For bigger projects, there may be specialists.


Download ppt "Robotics Abstractions: Levels of language, world view"

Similar presentations


Ads by Google