Bonus : My Blocks

Topics Covered

  • My Blocks
  • Check Your Understanding:
    1. 1. What is a My Block?
    2. A custom block representing one or more regular blocks
      Your personal copy of the Project file
      The physical brick the program is stored on
      The online lesson store panel that appears on the right side of the screen
    3. 2. Which of the following are good uses for My Blocks?
    4. Saving space on-screen
      Combining multiple blocks into a single behavior
      Allowing a sequence of blocks to be easily reused
      All of the above
    Try It!
    Try it! 1

    Contents of My Blocks

    Double-click on the FwdLeft My Block in your program. Try it!

    What happens?

    A second tab opens within your project, which shows the content of the My Block.

    Try it! 2

    My Block Changes

    What happens if you change the commands inside a My Block?

    1. Change the left turn inside the My Block to a right turn, then run the main program.

    Does the robot turn left or right? Try it!

    What happens?

    The robot goes forward then right. Adjustments you make to a My Block will take effect everywhere the My Block is run in your main program.

    Try it! 3

    Where are 'My Blocks'?!

    Where are your My Blocks available once you write them?

    1. Create a new Project, then try to add the My Block from your old program to the new program.

    Is it available there? Try it!

    What happens?

    The My Block you wrote is not available in the new Project. My Blocks are only available in the Project in which they are created (unless you use the My Blocks Import and Export features to move them between project files).

    Did You Know?

    Did you know?

    Where are My Blocks stored?
    My Blocks are stored in the Project file along with programs, data logs, sounds, and other needed data.
    You can view the contents of your current Project by clicking the wrench icon at the far left of the lower tab bar from the top of the window.
    Click the 'Wrench' button to access the project properties.

    Select the 'My Blocks' tab below to view the My Blocks for that project.

    Here you can view all the custom My Blocks created in that project.