Programming
When you boot up the software, you will have the choice to build any of the five robots already loaded up for you to build and use the code provided. Follow the instructions online provided in the software. If you need more information about the software and hardware and details about the kit, then head to https://www.lego.com/en-de/themes/mindstorms/about and you will get what you need from this page.
I find having the software on a computer or laptop for coding is quite helpful because of the larger screen and being able to store programs into my system. It is a good idea to have the software installed on your tablet or phone because these are good for the remote control feature of the software. Explore all the options to find what works best for you as a designer.
To get started, with version 10.0.3 (713488), LEGO updated the software to give you an option to get a quick overview of the sensors and builds and how they work with the Intelligent Hub. If you have any experience with Mindstorms, then you won't necessarily need this, but it is a great addition for those who are new to the Mindstorms robotics systems.
However, this little build and coding activity is a great start to explore much of the content shared in this chapter.
You can access this activity anytime by going to Settings | General and accessing the activity titled Welcome Robot Inventor:
Beyond this quick intro screen, you are prompted right away with the screen featuring the five robot builds, where you can choose any of them and build, code, and expand based on all the activities each robot provides.
This is a great time to explore these builds if you want to learn more about what this kit can do. These builds will give you ideas on how to build certain parts of robots as well as seeing how the coding platform operates. While this chapter has been mostly informative, take the time to build these models to experience what this robot kit is capable of making:
Once you have had your fill of those robots, then it is time to begin to build your own projects. When you are ready to create your own builds and programs, you can scroll down to Other and get started on your ideas.
You will have the choice to program with blocks or Python, as shown in the following screenshot:
When you choose Word Blocks, you will get a Scratch-like interface to explore and build. This is a drag-and-drop application. You can see how the software looks when you choose the block coding option:
The software is a Scratch-based programming platform. It uses a drag-and-drop coding process that many will already be familiar with if you have used Scratch, Blockly, MakeCode, or Code.org, and so you will be quite comfortable with the interface. The layout of colors on the black backdrop makes it easy to organize, find blocks, and explore the interface.
If you are looking to see even more blocks and add your Xbox or PlayStation controller, be sure to add the necessary extensions to your software by clicking on the gray-outlined blocks at the bottom of your screen, as shown here:
There is also a Python coding option within the software that will allow those who know how to program in Python to really push the boundaries of coding. This is a very important feature to bring this kit to the next level of experience and expertise. The following screenshot showcases what the Python coding interface looks like in the software if you wish to go down this route:
I know that not everyone knows how to code in Python, so for the sake of this book, we will stick with the graphical interface for ease of understanding.
Having both options to code and program within the software is a huge bonus to prior kits. The option for text programming is going to allow the LEGO community to see some incredible projects being developed.
If you are new to Python, there is a manual icon on the side of the screen to help you see how the blocks look in Python, named Knowledge Base:
Once you click on the Knowledge Base icon, you will be provided with a menu of options to help with your learning and coding journey. Simply choose the topic you need help with, as shown in the following screenshot:
The one fundamental difference to this programming environment compared to the LEGO SPIKE Prime kit is that lessons are missing. Of course, this is designed for retail instead of education like the SPIKE Prime, so that makes sense, but it's still worth pointing out. However, please check out the lessons to expand your skills as there is compatibility between the two. You can find the lessons here: https://education.lego.com/en-us/lessons?products=SPIKE%E2%84%A2+Prime+Set.
When you boot up the software, there are no introductions or any quick demos. Instead, you have to decide to build one of the five robots to get started, or hopefully, you have enough confidence to get started without guidance. One bonus of this software is that with each robot build, there are several activities to expand on the robots to learn some new build techniques and use to inspire the building of your own creations.
One crucial part of the programming software is being able to access data from your motors and sensors. You can access the Intelligent Hub through the software to gather all the data on your motors and sensors to be able to enhance your coding and build ideas.
On your software interface, at the top left of your screen, you can see some basic data or you can click on the Intelligent Hub icon to open up a new screen to dive deeper:
There is a ton of potential in this kit as you continue to explore and unravel all that can be accomplished.