practices of robotics with robolab and lego rcx robot

20
10 practices with Robolab 10 practices with Robolab Presentation adapted from one by Víctor Gallego Le Forlot (IES Jovellanos, Fuenlabrada)

Upload: algunastecnocosas

Post on 14-Jun-2015

708 views

Category:

Education


2 download

DESCRIPTION

Translated from a presentation by Victor Gallego (IES Jovellanos de Fuenlabrada)

TRANSCRIPT

Page 1: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

10 practices with 10 practices with RobolabRobolab

Presentation adapted from one by Víctor Gallego Le Forlot (IES Jovellanos, Fuenlabrada)

Page 2: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

IndexIndex• 1. Patrol• 2. Square• 3. Spiral• 4. Avoid Objects• 5. On the edge of the aby

ss• 6. Go back to the base• 7. Follow the line• 8. Follow the light• 9. Catch the can• 10. Parking

Page 3: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

1.Patrol1.Patrol

• Goal: make the robot go forwards 40 cm, spin around 180º and repeat everything in a loop

• What do I need to know?

Page 4: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

1. Patrol1. Patrol

• You need to calculate how much time the rover needs to move forward 40 cm and spin around 180º. These times depend on many factors and they are different in each rover and surface.

• Once the rover has done a lap, everything is always repeated, using a loop.

• Since there is not feedback from any sensor, it is an open loop control. Because of this, errors are not corrected.

Page 5: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

2. Square2. Square

• Goal: make the robot move following a 60 cm-side square

• What do I need to know?

Page 6: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

2. Square2. Square

• You need to calculate how much time the rover needs to move forward 40 cm and spin around 90º. These times depend on many factors and they are different in each rover and surface.

• It is an open loop control, since there is not feedback from any sensor, so errors are not corrected and the program must be corrected every time the environment changes

Page 7: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

3. Spiral3. Spiral

• Goal: make the robot move following a 50 cm-side square, but every time it finishes a lap, the side of the square must be increased in 10 cm

• What do I need to know?

Page 8: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

3. Spiral3. Spiral

• You need to use a variable in which you will save the time that the robot must go forward in each lap.

• That variable must be increased every time a lap is completed.

• Open loop control.

Page 9: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

4. Avoid objects4. Avoid objects

• Goal: make the rover go forwards until it hits an object, then avoid it and continue going forwards.

• What do I need to know?

Page 10: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

4. Avoid objects4. Avoid objects

• When the contact sensor hits an object, make it go backwards for a short space, turn right, go forward for a short period and turn left until it gets back to the initial path.

• Alternate turns to right and left to avoid the rover to divert from its path.

• Closed loop control (with feedback).

Page 11: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

5. Close to the edge5. Close to the edge

• Goal: make the rover move on the table and when it reaches the edge, make it go backwards and change direction to avoid falling

• What do I need to know?

Page 12: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

5. Close to the edge5. Close to the edge

• Make the rover go forwards until the light sensor detects an important change because it reached the edge. Then, make it go backwards for a short period and turn to change the direction before it continues going forwards.

• Alternate turns to right and left to avoid the rover to always follow the same paths

• Radomize the time it turns so the rover doesn’t follow trhe same paths again and again.

• Closed loop control (feedback).

Page 13: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

6. Back to the base6. Back to the base

• Goal: make the rover go forwards until it hits any object, and then go backwards to the starting point

• What do I need to know?

Page 14: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

6. Back to the base6. Back to the base

• See how much time it takes the rover to hit something. Make it go backwards for that same amount of time.

• Open loop control, that is why it is not very precise.

Page 15: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

7. Follow the line7. Follow the line

• Goal: make the rover follow a black line in the floor

• What do I need to know?

Page 16: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

7. Follow the line7. Follow the line

• Measure the light value in each sensor when it enters the black line. If the right sensor finds the black line, make the rover turn left. If the left sensor finds the black line, make the rover turn right. Otherwise it must go forwards.

• There is feedback, so it is a closed loop control.

Page 17: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

8. Follow the light8. Follow the light

• Goal: make the rover spin until it finds an intense source of light, and then make it follow that light.

• What do I need to know?

Page 18: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

8. Follow the light8. Follow the light

• Define a light threshold above the environmental light and below the light that must be followed. The rover must spin until it finds a value of light above the threshold and go forward when it finds it.

• Closed loop control.

Page 19: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

9. Catch the can9. Catch the can

• Goal: make the rover go forward until it hits a can, then it must catch it and go back to base with it.

• What do I need to know?

Page 20: Practices of robotics with ROBOLAB and LEGO RCX ROBOT

9. Catch the can9. Catch the can

• Make the rover go forward until a contact sensor detects the hit with the can. It must turn the can around and go back, pushing the can to the starting place.

• Closed loop control.