Skip to content
Learning Site
Home

About

  • About Robotical
  • Case Studies
  • Meet the Team
  • Blog
  • Contact Us

Our Products

  • Marty the Robot
  • Axiom
  • Cog

Teach

  • Lessons & Resources
  • Marty for Educators
  • Funding & Grants
  • Professional Development
  • Why Teach STEM?
  • Coding Environments
  • Student Led Learning

Let's Code

  • Marty the Robot
  • Code Online
  • Marty Apple App
  • Marty Android App
  • Update your Marty
  • Cog
  • Code Online
  • Cog iOS App
  • Cog Android App
  • Axiom
  • Axiom Science

Support

  • Marty Get Started
  • Cog Quick Start Guide
  • Axiom Science Quick Start Guide
  • Support & FAQs
  • Marty V2 User Guides
  • Marty V1 Resources
  • Request Support
  • Request Top-Up Training

Shop

  • Marty the Robot and Physical Computing
  • Class Packs
  • Add Ons & Extras
  • Account
  • Shipping, Returns & Cancellations
  • Distributors
HomeLessonsUnits of workCurriculum standardsTutorials

Information

  • Lessons & Resources
  • Knowledge Base & User Guides
  • About Us
  • Shipping, Returns & Cancellation
  • Privacy Policy
  • Learning site privacy
  • Terms of Service
  • Partner Hub

Support & Help

  • Support & Help Center
  • Getting Started with Marty V2
  • Getting Started with Marty V1

Learning, Resources & Guides

  • Marty V2 Lessons Site
  • Marty V1 Lessons Site

Contact Us in the UK

Stanhope House,12 Stanhope Place,Edinburgh,United Kingdom,EH12 5HH
(+44) 0131 564 0922
hello@robotical.io
Contact Us

Contact Us in the US

2810N Church St, PMB 61694,Wilmington,Delaware,USA19802-4447
(+1) 833 886 1661
hello@robotical.io
Contact Us

Why not join our mailing list?

For News, New Products and Special Offers

Join mailing list

Copyright 2016-2026 © Robotical Ltd

All lessons
Marty app
CurrentPrevious

4.03: Programming Marty with Python

4.03: Programming Marty with Python
Age / stage
14 - 16
Estimated time
45 minutes
Difficulty
Intermediate
Products
Marty V2

On this page

  1. Lesson overview
  2. Before you begin
  3. Warm-up
  4. Get learning
  5. Further challenge ideas
  6. Cool down
  7. Additional reading
  8. Curriculum standards

Additional reading

Getting Started with MartyPy

Curriculum standards

20
Choose your curriculum to see the relevant standards.

20 of 20 linked standards shown.

Australian CurriculumAustralia2
Curriculum areaLinked standards
Digital Technologies, Design & technologies: Digital Technologies

Select a code to read the full standard.

Digital Technologies, Design & technologies: Digital Technologies

  • ACTDIP041Implement modular programs, applying selected algorithms and data structures including using an object-oriented programming language
  • ACTDIP044Plan and manage projects using an iterative and collaborative approach, identifying risks and considering safety and sustainability
CSTA Education StandardsUSA2
Curriculum areaLinked standards
General standards

Select a code to read the full standard.

  • 3A-AP-17Decompose problems into smaller components through systematic analysis, using constructs such as procedures, modules, and/or objects.
  • 3A-AP-19Systematically design and develop programs for broad audiences by incorporating feedback from users.
Curriculum for ExcellenceScotland13
Curriculum areaLinked standards
Health and Wellbeing: Mental, Emotional, Social and Physical Wellbeing
Literacy & English: Listening and Talking
Literacy & English: Reading
Literacy & English: Writing
Technologies: Computing Science

Select a code to read the full standard.

Health and Wellbeing: Mental, Emotional, Social and Physical Wellbeing

  • HWB 0-11a / HWB 1-11a / HWB 2-11a / HWB 3-11a / HWB 4-11Social wellbeing
  • HWB 0-14a / HWB 1-14a / HWB 2-14a / HWB 3-14a / HWB 4-14aSocial wellbeing

Literacy & English: Listening and Talking

  • LIT 4-04aFinding and using information
  • LIT 3-05a / LIT 4-05aFinding and using information
  • LIT 4-07aUnderstanding, analysing and evaluating

Literacy & English: Reading

  • LIT 3-14a / LIT 4-14aFinding and using information
  • LIT 3-15a / LIT 4-15aFinding and using information
  • LIT 4-16aUnderstanding, analysing and evaluation

Literacy & English: Writing

  • LIT 3-20a / LIT 4-20aEnjoyment and choice
  • LIT 3-22a / LIT 4-22aTools for writing
  • LIT 4-23aTools for writing

Technologies: Computing Science

  • TCH 4-13bUnderstanding the world through computational thinking
  • TCH 4-14aUnderstanding and analysing computing technology
England's National CurriculumEngland1
Curriculum areaLinked standards
Computing, Design and Technology: Computing

Select a code to read the full standard.

Computing, Design and Technology: Computing

  • ✔️Understand what algorithms are; how they are implemented as programs on digital devices; and that programs execute by following precise and unambiguous instructions
ISTEUSA2
Curriculum areaLinked standards
International Society for Technology in Education (ISTE)

Select a code to read the full standard.

International Society for Technology in Education (ISTE)

  • 4cStudents develop, test and refine prototypes as part of a cyclical design process.
  • 5cStudents break problems into component parts, extract key information, and develop descriptive models to understand complex systems or facilitate problem-solving.

Resources

Learner resources

  • Python Student Workbook - Programming Marty with PythonFile links loading
  • Marty Says CardsFile links loading

Educator resources

  • Teacher's Guide - Programming Marty with PythonFile links loading
  • Presentation for Programming Marty with PythonFile links loading

Solution resources

  • Programming Marty with Python SolutionsFile links loading

Lesson overview

In this lesson, students get more practice with creating and running commands that will move different parts of Marty's body. Students should start to develop an understanding of the outcome of different coding commands on Marty and the environment that he is in. They should also start to gather a better understanding of the Python syntax.

Learning objectives

  • I can describe the meaning of code in a program and the purpose of parameters in a command.
  • I can write a command to efficiently carry out an action.

Key vocabulary

  • Parameter
  • Syntax
  • Import
  • IDLE

Prior learning

Knowledge of basic Python programming commands

Before you begin

Equipment

  • Marty the Robot
  • Student Workbook
  • Python editor (such as IDLE)
  • Access to computers/laptops (with Python & MartyPy installed)
  • Marty Says cards

Warm-up

TimingActivityPossible adaptations
Timing—

Warm-up

Remind learners that computers take instructions exactly as you write them. There is no understanding or thinking about what you mean, there is only what you write, 'literally', what you write.

Have learners pair up and sit back to back. Have one describe a robot to the other, who will draw it. The drawer cannot ask for more information, the describer cannot turn around and have a look.

Once a drawing is complete, have them switch roles and repeat the exercise. Open it up for a different subject to draw.

Possible adaptations—

Get learning

TimingActivityPossible adaptations
Timing—

Get Learning

Have learners explore Marty fully, in terms of joints and possible movements available. Think back to the drawings the learners just completed and the need for specific instructions.

After learners have had a chance to thoroughly explore the available movement Marty can display, share the ppt presentation, starting with the commands, and stop at slide 13; encourage learners to jot down commands that they think they might want their Marty to display. Draw attention to the parentheses that follow each of the movements Marty might be able to carry out. Sometimes the parentheses are empty and sometimes they are not, ask why this might be by comparing examples: for walk, why might values be important; for hello, why might values not be important? Have learners remember this for future coding exercises.

Have learners click the windows button or open their Mac terminal. In both instances, they should type 'idle'. Have learners code along from slide 15: load MartyPy and connect their Marty with the IP address, most easily found by connecting through the app.

Show the 4 commands and their parameters, in parentheses, from the presentation (slide 17); each time a command is written, for learners to copy, have the template up and describe what each of the parameters means. The commands are:

  • marty.eyes()
  • marty.leg lift()
  • marty.arm lift()
  • marty.lean()

Encourage learners to take time to experiment with the values within the parentheses: have them use the same command, changing the values and have learners note the effect.

Make the larger Marty library available to learners. Encourage group work, suggesting learners combine commands to see the result or think of how combining different commands could complete a task that one command can't. Ask for volunteers to share any interesting code or code that had been challenging, but the group figured out what it meant.

Cool down

TimingActivityPossible adaptations
Timing—

Wrap-up

Bring learners together to share challenges and successes. Ask if anyone grouped a set of commands to perform actions. Did they notice any other similarities to Scratch that they may have seen in prior lessons? Ask learners to think about commands that might be useful to learn for coding Marty. Ask them to think about scenarios that might be useful for a robot like Marty to be used in.

Possible adaptations—
Possible adaptations

Support

Have cards available for learners, with the boilerplate for the commands on them. Below the boilerplate, have basic descriptions for each of the parameters.

All programming should be group or paired, this is the norm for programmers, remind learners that, generally speaking, programmers work in pairs to write code.

Further challenge ideas

Extension

Challenge learners to start chaining commands to accomplish something. Have them think up tasks to complete: how could you code that? How could you code that more efficiently?

Challenge peers to write code that would end up in the same position as a set pose.