Teaching Lego Boost: A Beginner's Guide
The COVID-19 crisis has changed our lives. Many of us are trying to hold down our full-time jobs while managing homeschooling lessons, and juggling unpredictable schedules. We share this post as a potential at-home learning activity that can help fill the school calendar and bring a bit of joy. We wish you and your loved ones well during these taxing times.
Teaching Lego Boost
The memory of my first coding project was hacking Basic games back in the 1980s after my technophobic parents had the insight to realize that these new-fangled computery devices were going to be "big" and got a PC for the family. Of course, he was more right than he could ever have imagined, and for that, I'm very grateful, not least because now I'm lucky enough to make a living working from home doing something I love.
Several months ago, I came across Lego Boost programming while researching materials for a coding club some other parents and I were establishing at my children's school. What impressed me most about Lego Boost is that it combines the versatility of the ever-popular children's toy with robotics and a simple visual programming language to allow for extended play and learning at the same time.
The club turned out to be very popular, and although we do more than just Lego programming now, it continues to thrive and is still over-subscribed. So whether you are planning on teaching programming to a group of children or just to your own during lockdown, I want to pass along some tips, tricks, and resources that will hopefully make your time productive and enjoyable.
Why Lego Programming
Aside from just teaching common programming constructs (such as loops and flow control, etc.), Lego Boost is more of an holistic opportunity for hands-on learning. The children are guided visually by the tablet app to build the robots, code, test, fix, and repeat in short cycles until they get the result they want. Although they don't realize it, they're learning one of the most important skills we use in software development, and having fun at the same time.
There's a big focus today on personalized or customized learning that meets students where they are and what is great about Lego Boost is that it's suitable for a wide range of ages. Children develop the ability to learn abstractions, such as those used in computer programming at different rates. Having an option that is flexible to different ages and skill levels is essential. The coding club was to be open to children from around 5 or 6 years old, most of which are not yet proficient readers, so the visual approach of the Lego Boost programming language is ideal (similar in many ways to amazing Scratch Junior). Moreover, older or more adept children need the scope to build more complex robots and solve arbitrarily complex programming tasks. Lego Boost caters to this well with constructs such as sub-programs, variables, and eventing, as well as an unguided free-play mode.
Then there's the cost. Since we were putting this together for an after school club, the budget was very minimal. In a world where educational funding often spirals into the millions, having a solution around technology that only costs between $125.00 and $250.00 each and makes use of the school's current resources (in this case tablets), is a huge plus.
Teaching Is Hard
I am not a teacher. I am a computer programmer. The experience of trying to teach 18 young children some programming was humbling. Before attempting this myself, I observed some lessons delivered by professionals, and honestly, it looked like a cinch. I thought that as long as I knew my subject matter, the children would listen, engage, learn, and have fun. This is not true!
I expect that most of the things we learned (the hard way) are pretty rudimentary, but they seemed practical, so we used them all the time:
Hungry children get hangry. Make time for eating snacks, regularly, and bring some spares for those that forget. Don't learn that the hard way.
Taking the time to review the previous session, perhaps with a quiz, not only reinforces what was learned but helps set the scene for the programming tasks.
Setting small achievable goals and rewarding them for trying is an age-old technique used in parenting, and it works in a school setting too.
"1-2-3, look at me!"
This is one of many such mind-control techniques teachers use, and it was one I noticed when observing a proper lesson. It turns out that all the children in the school have this phrase repeated to them regularly, and their brains have little choice but to obey, so they turn their heads, stop chatting, and for a short time, give you their attention. To be used sparingly, however.
Break things up
As someone who can focus on a programming task for hours and days, it's not something that I understand, but children find it especially difficult to focus on one thing for very long — even an hour-long code-club needs breaking up. For example, snacks, review last session, snacks, present a challenge, snacks, tidy-up, and then home.
One key reason for running a code-club was to inspire the children. We found that showing a short video at the beginning of the session of something computer-related not only broke up the work but also showed the depth and breadth of the influence of computing on our lives. For example, we showed a video showing the crucial role of computer programming on the Apollo 11 mission on its 50th anniversary.
We went with groups of 2 or 3 where possible. This allows for mixing up different ages and abilities and tweaking the groups to improve the dynamic, while also creating some team cohesion.
Real teachers are amazing! Not only do they know their subject matter, but they also possess infinite patience. They're experts in mind control, crowd control, and many other things besides. Moreover, they do a tremendous amount of preparation. For each hour of teaching, it takes at least 2 hours of preparation. Needless to say, we didn't manage this, and unfortunately, it showed. Having said that, when running the club for the second time with different children, we were much better prepared, and that showed too.
What could be better than building things with Lego? Building programmable robots with Lego using a Tablet. Here is a list of things to get you started:
- Lego Boost sets
- Modern-ish tablets running Android or iOS
- Lots of rechargeable AA batteries
- Battery charger
- A small cross-head screwdriver to change the batteries
- Plenty of patience
Warning about Bluetooth Pairing
Bluetooth is used for communication between the app and what's called the Hub (the central motorized control unit). Bluetooth can be sketchy at the best of times, but when you have a whole bunch of tablets and hubs trying to pair at the same time, there can be some amusing results, for example, we've even seen robots running off tables and shattering into hundreds of pieces. What's more, the tablets don't remain paired to the Hub they were initially paired with but will pair with whichever Hub is turning on at the time. From what I can tell, there is no solution to this, except to try to take turns doing the pairing or try to move further away from others.
Fortunately, the Lego Boost App is a fully guided experience. It guides the children through the building, bluetooth pairing, and coding of a whole series of different models, unlocking new capabilities on the way. This is great in that it removes the need for much of the lesson planning, but on the other hand, we soon noticed that most children quickly latched on to this action-reward cycle and became motivated entirely to get to the end before the other groups. So it wasn't long before we started to set goals to provide a different focus around the concepts that we felt were important, such as the development cycle, loops, modularity, flow control, and so on.
We ended up creating many different tasks for the children to complete, some of them were quite simple, such as to make Vernie (think Johnny 5) drive around an obstacle.
Vernie: circumnavigate the obstacle
Most children start by "scripting" the solutions by repeating simple programming blocks
or running the programs a few times my mashing the run button:
By encouraging the children to solve the task using the fewest number of operations, many ended up creating more concise programs with some basic code reuse using loops:
Vernie: search and destroy
Vernie is the first full robot that the children are guided to build and program. There's lots of Lego building and some basic programming tasks. We created a fun "search and destroy" task to expose them to some important concepts: Vernie should move around randomly and fire at anything that comes within five units of distance, and we even held a mini-robot war at the end of the session!
In this program, the children must use:
- Concurrency (multiple start blocks)
- Control flow (red stop button stops the whole program, and conditional proximity trigger)
Frankie: play some music
In this sample program using Frankie the cat, one of the children introduces event producers and subscribers in the form of "flags." Curved flag (starting) blocks get triggered by the square ones with the same number. This teaches the concept of reusable sub-routines, and of course, this child has chosen to make poor Frankie fart at the end of his performance too.
There's a thriving community growing around Lego Boost, and Lego has subsequently released the Boost communication protocol specification. A few exciting projects have emerged, and I strongly recommend having a play around:
- Probably the most active project that allows controlling the robot remotely via Python, opening up a load more possibilities, such as controlling the models using different programming languages. This is great fun but most suitable for older children
- I haven't used this, but I love the idea of using a web-browser only to control Lego Boost
- Perhaps strap a Raspberry Pi to Vernie and make it full autonomous with some AI?
Teaching programming to young children is amazing, both for the teacher and the children. Unlike when I was learning about computers, children have exposure to computers every day in one form or another, so using tablets and drag-and-drop programming comes to them very naturally.
What was interesting is that we saw no real correlation between aptitude and age when it came to completing the programming tasks for children between the ages of 5 and 8 years old.
One criticism of the Lego Boost programming language I have is that it has a considerable amount of programming blocks available that could have been created by subroutines made up of other blocks. All the different models have their own model-specific programming constructs. Having fewer blocks would make the language easier to learn while keeping it just as versatile. Also, there are some blocks (such as the ones to play short tunes) that cannot be composed by smaller blocks, and this really limits what can be expressed using those blocks. In my opinion, Lego Boost should focus on a minimal set of simple primitives and how users can compose these to build more complex programs.
Having said all that, Lego Boost is a relatively cheap and fun educational toy that people of all ages can enjoy, whether you're a five-year-old wanting to make Frankie fart or an old fart like me hacking Vernie with Python and a Raspberry Pi.
If you're interested learning more about our code-club, or have some insights you'd like to share, please get in touch via @kipzter