Pattern recognition is always an important skill for
teaching the looping concept in programming. Fol-
lowing the instruction manual for building a Lego
model as well gives an example for student on algo-
rithmic design. Thus, we can deduce how building
Lego models and programming them can contribute
in teaching students main aspects of Computational
Thinking in an enjoyable way. However, those kits
can be expensive and difficult to attain for personal
use (Cardoso et al., 2018). Moreover, with the current
Covid-19 situation, some parents prefer online learn-
ing which can be difficult when hardware (in our case
programmable Lego kits) are included. All of these
reasons were the main inspirations for Let’s LEGO.
The aim of this project is to investigate the feasibility
and applicability of creating a simulator for building
and constructing robots, controlling them program-
matically, and observing them in different environ-
ments. The work aims at building a simulator for the
well-known Lego Education WeDo 2.0 Robotics con-
struction set, aimed at children aged 7-9. The rea-
son behind that was the lack of presence of any (free)
simulators for this specific version of the Lego Educa-
tional Kits, to the best of our knowledge. The WeDo
set is simple yet versatile, making it a great candidate
to teach children robotics and programming (Useng
¨
ul
and Bahc¸eci, 2020).
The paper is organized as follows: Section 2 in-
troduces some related work. Section 3 shows more
details about let’s LEGO. The experimental design is
introduced in Section 4. We finally conclude with di-
rections to future work.
2 RELATED WORK
This section discusses virtual prototyping for the lat-
est Lego Mindstorms robot, the EV3. Lego Mind-
storms is a platform that allows users to operate a
programmable and customizable ’brick.’ This brick
serves as the control center and power station for the
robot and is compatible with a variety of extra con-
nectable modules for a variety of purposes, such as
LEDs, motors, colour sensors, and buttons. These
sensors and actuators can be controlled by creating
code and uploading it to the brick. As of 2013, the
Mindstorms EV3 is the third and most recent addition
to the Mindstorms family, and its software includes an
upgraded brick that runs Linux locally (Cornelissen,
2019).
The Mindstorms series has proven to be success-
ful in education, where it is used to teach program-
ming and computer science (Klassner and Anderson,
2003). However, there are some drawbacks to using
this type of instruction. Mindstorms robots are expen-
sive, making it difficult to provide each student with
their own robot. The frequent swapping of the robot
between students limits the amount of time available
for each student to actively work with it. Further-
more, working with Mindstorms might be inefficient
owing to the substantial effort required to upload code
to the brick on a regular basis. Given the popularity
of the Mindstorms series in education, as well as its
short comings, simulation software for the EV3 series
might be beneficial. As the fundamental idea behind
these robots is real-life interaction (driving around,
flashing LEDs, handling physical input, etc...), the
simulation component would be distinct from tradi-
tional virtual prototyping in that it would need a com-
pletely visual depiction of the brick and its linked
components (Cornelissen, 2019).
A real-world EV3 brick interfaces with its hard-
ware to set and retrieve variables based on software
execution (Cornelissen, 2019).
In the simulation, this concept must be repro-
duced. When programming languages are incompati-
ble, a dilemma arises: the simulation software is cre-
ated in Unity using C#, and Python is utilized to oper-
ate the simulated robot. One solution is to include an
interpreter within the simulation program, allowing
the simulated brick to run suitable code natively. A
more achievable approach is to develop a mechanism
to communicate between the simulation software and
a user-written application running on the same com-
puter (Cornelissen, 2019).
The idea of the work presented in the paper is
to provide an easy to use simulator for lego WeDo.
WeDo has proved to help in teaching children about
robotics and programming (Chalmers, 2018). It tar-
gets an age group that is younger than EV3. Since the
aim is to introduce programming and computational
thinking as early as possible, this was the motivation
to fill int he gap and provide a free simulator that can
allow children to learn about WeDo without having to
own a kit.
There is a difference between ‘input’ and ‘output’
values. The Python application assigns input values,
while the simulation retrieves result values. A LED
module’s ’Colour’ value counts as input, while an ul-
trasonic sensor’s ’Distance’ value counts as output.
The objective is to achieve structural equivalence be-
tween the simulation (in C#) and ev3dev2 in terms
of hardware modelling. In this manner, despite the
language barrier, a connection between the two pro-
cesses may be established. When this model is imple-
mented on the simulator side, it generates a ’virtual’
brick that represents the current state of the simulated
hardware. The simulation may then be performed us-
Building, Controlling and Simulating We-Do Robots
377