Filters

Other

Your name is required for this document. It is only stored on this local computer and no where else. Please enter your name below:

Lesson 2A-Mazing Marty

Knox badge
Lesson 2A-Mazing Marty
Marty RobotInteractive Instructions
Marty Robot

BGE ComputingJ Balfour 2022

Follow these instructions to achieve your success criteria for this lesson.

  • Understand how programming skills can be applied elsewhere
  • I can make a Marty Robot move a certain number of steps
  • I can explain why sequence is so important in computer programming

Movement

Your first task is to make the Marty Robot move. Using a ruler, determine how far Marty moves in a single step.

Since you have now discovered that Marty moves 0 centimetres at a time, your next step is to find out how many steps Marty will need to take to get the the yellow marker on the map.

How many steps were needed to get to the yellow zone on the map?

Now that you know that he took 0 steps to reach the yellow zone, you can now calculate how many steps are needed to get to the next zone very easily.

Try out what you have just created.

Using this information, you can now determine how many steps will be needed to get to just before the wall on the big map.

Now make Marty move to the wall and back again.

What you have most likely done is set the number of steps both ways manually, so if he took ten steps to move forwards, you then made him move back ten steps.

From your Scratch lessons, how could you make this more efficient (i.e. what block in Scratch allows you do something multiple times)?

Using a structure similar to one found within Scratch, make Marty move to the yellow line and back three times.

Making it even more efficient

Marty is a powerful little robot. He has many different tools and features that help make him more useful. For example, he has a sensor that allows him to detect colours with his feet.

These sensors can be used to detect a colour which Marty is expected to walk to. By using some kind of structure that allows Marty to carry something out repeatedly, we can make Marty move until he gets to a location.

Colour is composed of three different components, red, green and blue. These three components need to be checked when Marty is using his colour sensor to ensure that he is on the correct colour.

You can use the following colour input to select a colour and you can input the RGB values to test out what each of them make up.

Using the sensor built-in to Marty, make Marty move to the yellow block and then back.

To do this, place Marty on the yellow block and then use the sensor to determine each component, red, green and blue. Once you have establish what red, green and blue components are needed for the colour of the paper, you can compare them as shown:

Sensor code

Watch the following video to see exactly what you will need to do:

Finishing the maze

This task is in your groups.

Your job is to make Marty go from one side of the map to the other side of the map, collecting the yellow zone and stopping when it gets to the red zone. You start in the green zone.

Your code should be programmatically written to take advantage of things like the sensors and blocks that allow you to repeat something multiple times.

The following rules apply to this program:

  • If Marty goes off to the side slightly (drifts), you can give him a little push to put him back on track again.
  • If Marty senses black underneath him then the program should stop.
  • If Marty senses yellow and there is not enough room for him to turn around, you may manually help him rotate.
S1 Marty Robot Lessons
Provide Feedback

What did you think of this lesson?

!
-- DragonDocs version 0.9 --

20.08.2017

Started on DragonDocs
Created a YASS/PHP and HTML-based system for saving and retrieving data

21.08.2017
Added CSS styles to page
Added JavaScript code to the page

02.02.2018
Added the multipage option (used in my dissertation)
Added the XMLHttpRequest-based multipage requests

08.02.2018
Added the Accessibility features
Filters added

10.02.2018
Purple filter added

17.03.2018
Added the Note class
Added the Did You Know class

-- DragonDocs version 1.0 (Yosemite) --

02.10.2019
First trial of DragonDocs in teaching

04.10.2019
Added the Task, Starter, Review your learning sections

07.10.2019
Added the feedback feature
Added the Dark Mode toggle

19.09.2020
Performance gains through the removal of unnecessary code
Added the Learning Intentions and Success Criteria features
Added the school badge

31.09.2021
Changed the headings (h2) to be more consistent with my website
Added sections to the pages - sections must be preceded by a h2
Added the "I have read this section" buttons
Changed the main heading zone to gradient text like my website
Added the table of contents feature

02.02.2022
Added the Print feature
Updated the footer to feature a new gradient
Added the Test It! class
Added the green flag
Automated the table of contents using JavaScript

06.02.2022
Added the 'includes' feature to the document, allowing inclusion of other files easily
Removed the requirement that the IP address must be one of the schools I have taught at, opening these documents to the public

02.03.2022
Once a section has been read or completed, the user can now hide that section

10.10.2022
Added the Extension task class
Changed the scrollbar on Windows to match that of macOS

-- DragonDocs version 2.0 (Kilimanjaro) --

07.08.2023
Added the Save button and the ability to save 'results' or answers to a Word document

12.01.2024
Added the large numbers class
Removed the background of the page navigation

-- DragonDocs version 2.1 (Aurora) --

08.02.2024
Added the active class to active links in the bottom section

09.02.2024
Added the image upload feature

10.02.2024
Added a fix that prevents the upload of non-image files into an image upload
Added pasting images to the upload feature

11.02.2024
Added the ability to view the changelog from a document
Improved the feedback system by recording the DragonDocs User ID and the Document ID data
The feedback from DragonDocs can be accessed much easier

12.02.2024
Added the new step_by_step_mode feature, allowing sections to be viewed individually
Added the ability to lock and unlock DragonDocs

22.02.2024
Added new checkboxes to each list item in a .task or .step
Added functionality to said checkboxes to add a strikeout to steps completed

23.02.2024
Added the new 'step' class
Steps are now auto incremented in CSS so the name displays the step number
Activities are now also auto incremented to display the activity number

25.02.2024
Added the 'matcher' feature to DragonDocs
Fixed an issue in which a closed section would retain it's original height within the document navigation
Added starters and the lesson review to the navigation on the side
The learning intentions and success criteria in teaching documents have now been redesigned to match my slides design

26.02.2024
All buttons are now on the right hand side
The accessibility button now has WAI under it

-- DragonDocs version 2.2 (Serengeti) --

26.02.2024
Code has been rewritten from the ground up to be object-oriented, making additional features easier to add

28.08.2024
Changed the look of grouped multiple choice buttons

06.03.2024
Added the new dragondocs_name feature and the requires_name property which allows names to be prepended to saved documents

09.03.2024
Added code so when the user types in their name and hits the enter key it will save that data and close the modal window
Added the new DragonShow and DragonDocs Link - a connection between both services that allows the presenter to communicate with users of DragonDocs from a DragonShow
Added the new timer option which is sent from DragonShows

04.04.2024
The matcher feature is no longer embed from jamiebalfour.scot but actually a feature of DragonDocs
Made DragonDocs 100% object-oriented, meaning much better management and better performance

05.04.2024
Made subtle changes to the interface to tidy it up a bit

06.04.2024
The multiple choice questions are now also part of the object oriented interface

09.04.2024
As requested, h3 elements are now included in the 'floating navigation'
The active navigation element now becomes bold and the left border has been retired

Time left

: