Friday, 22 May 2020

Junkbots two - move the robot

from Junkbots two - move the robot
by Scott Turner

What is the Junkbots project

The Junkbots project has been running for a number of years as an initiative to bring sustainability, computing and engineering together by building bots out of junk; details of the project can be found at. https://junkbots.blogspot.com/ . Junkbots is an extension of the Research into the teaching problem-solving going on at the University of Northampton please feel to visit https://computingnorthampton.blogspot.com/2019/01/problem-solving-research-outputs-and.html for more details.



What are we going to do?

Play with a Scratch robot on the screen! Build on the routines from the previous session. Challenge to get around the rock. Challenge to do the same thing but by repeating actions Extend your solution

Activity 1: Reminder of the blocks we used previously?

This means when the green flag is pressed do whatever follows.


This means place our robot (go to block) to point on the screen roughly in the centre of the screen.


Do you want a challenge: What do think would happen if instead 0 and 0 in the white spaces in the go to block, we put in 50 and 50? Have a guess.



This means stop the scratch program for 1 second and the carry on.



We can use this block to move the robot 50 steps on the screen in the direction it is facing.

Do you want a challenge: How do you think we could get the robot to move 100 steps? Have a guess.



We can use this block to turn the robot to the right 45 degrees.

Do you want a challenge: How do you think we could get the robot to move 90 degrees to the right? Have a guess.

We are also going to look at two more ‘things’ today: one new block and a new type of blocks to make our programming easier – the control blocks.



We can use this block to change the direction the robot faces.



When we click on the control button at the side we see several more blocks we can use.

One of these we have played with before the wait block.

The other two we are going to use today in later activities.

When we want to repeat a combination of blocks so many times, we can use the middle block and then change the 10 to the number of times we want to repeat.

If we want it repeat something forever (or until we stop the program with the red button) we can use the last block.



Activity 2: Have a go at guessing what it is going to do?

Follow this link to a new Scratch project https://bit.ly/ScratchJunkbot2

Challenge 1: Can you describe using the chat what you see it do?

Challenge 2: Can you rewrite the routine so when you press the green flag it hits the rock? What happens when it hits the rock share on the chat? Can you do this using less than seven blocks?

Challenge 3: Rewrite the routine so when we press the green flag it goes around the rock in a square. Hints: You did a similar task last week so please feel free use what you have done before. You might have to change the starting position of the robot. It is worth putting the wait blocks in to help you see it in action.

Activity 3: Modify and Make

Now go to the weblink: https://bit.ly/Junkbot3 Press the green flag and see what it does. Challenge 4: Using the chat describing what it did, please include when do you think it will stop? Challenge 5: How can we change this so that it goes around the rock twice?

Activity 4: Modify and make play

Challenge 6: Try and change what you did in Activity 3 so that the robot goes around the block in a different shape Challenge 7: The really tough challenge. How to we get the robot to move in a figure 8? It must not hit the rock. Have a go yourself and if you want to see one possible answer (there are more than one way to do this) go to https://scratch.mit.edu/projects/398164007/

Questions

Does the robot work the way you thought it would? If it did move the way you thought– great! Can you make it move in a rectangle where two sides are longer than the other two? If it didn’t move the way thought still good. What was different?If you would like to know more about the Junkbots project contact scott.turner@northampton.ac.uk

No comments:

Post a Comment