Instruction Guide: EV3 - Software: On-Brick Programming

In this Lesson we have 1 Primary Instruction Resource:

  1. The EV3 On Brick Programming.

Writing an EV3 Brick Program

The primary material for this is the EV3 On Brick Programming.

The purpose of this lesson is to re-inforce the fact that robots do NOTHING but what they are told to do. A robot will perform actions and wait for changes to its environment, but only when told to do so.

In the EV3 Brick Program students can do the following:

  • Uses up to 16 blocks.
    • Wait blocks respond to sensor readings (touch, color, etc.)
    • Action blocks tell the robot what to do
  • Have one main loop. The program can run once, twice, or until your batteries run dead.
  • Build a sequence of actions such as starting and stopping motors, playing sounds, and displaying images on  a screen.
  • Timer Blocks May Be required to Get Expected Reults!!
  • After many actions, a wait block will be required to get a result
    • a motor or sound block in a loop will not create movement or the intended sound since the block keeps restarting before any ouptut can be seen/heard (or just get a clicking sound as the start of the sound repeats over and over)
    • add a timer block or wait-for-sensor block after these actions 
  • Set one paramater for each programming block (for e.g. turn on motor for 2 rotations).

Slide 1:

Have students:

  • Turn on the brick. The Brick does NOT need to be connected to a computer. All of the programming will be done on the Brick. Note...students will learn later that this program is MUCH easier to do using EV3-G. 
  • Move through EV3 Brick top level menu to “Brick Program” .
  • An arrow pointing 'up' will appear if you are on the right menu.
  • Blocks chosen will be inserted at the vertical line.
  • Use the UP button to access the Block Palette. Continue to press the UP button until you find the block you want.

Slide 2:

This is the full Brick Palette for writing on Brick programs. Have students discuss what they think the blocks in this palette might do.

  • The Blocks with the hourglasses are 'wait for input blocks'. An example of this would be...wait until the touch sensor is pressed something (an action). This is how a robot senses its environment.
  • The Blocks with the arrows are Action Blocks.  An example of this would be...turn on motor.
  • The Trash Can is how we remove a current brock from a program.
  • The EV3 Core set that these students are working with does not hav all of these sensors. For example, there are no probes in this kit.

Slide 3:

  • Navigate the palette with Up, Down, Left, Right buttons.
  • Select desired block with Center button.
  • Press Center button AGAIN to modify one parameter of this block. Here the movement has been changed to go 'left'.
  • Select Back button to return to Beginning.
  • Use Center button to Run program.