Motivation
We were inspired by JK Brickworks’ Lego domino car. In the video referenced, the domino car is remote-controlled and places dominos as the vehicle moves.
Improvements
JK Brickworks’ domino car places dominos along the car’s path and does not construct a pattern to resemble any image. Our vehicle is intended to place dominos in a grid, building a pattern. The user can input any image and choose the domino dimensions they would like, and our vehicle automatically places the dominos to complete the pattern. Currently, the default dimensions are set to 20 by 20 dominos because of the limited number of dominos.
The Lego car’s domino-placing mechanism is linked mechanically to the rotation of the wheels. The distance between the dominos is thus fixed. Ours is operated by a separate motor, allowing the vehicle flexibility to change the distance between dominos.
Lastly, JK Brickworks’ vehicle only contains one column of dominos. On the other hand, ours has three columns, each one with dominos of the same colour. The design and placement of our domino cartridges are flexible and can be conveniently redesigned to fit more colours.
Details
The vehicle will be controlled by an Arduino Mega. The user input image will be processed in Python and the necessary output will be wirelessly transmitted to the Arduino via the Bluetooth module, HC-05.
Image Processing
The input image will be processed with a Python script. It will first be resized to the user’s required dimensions. Each pixel value will then be read for its colour value (RGB channel). These values will be each mapped to one of three colours, corresponding to our three domino colours. The three colours correlate to the three most dominant colours in the image. K-Means clustering, a data reduction technique, was adopted to identify these colours by finding three centres or means. This was implemented with the sklearn.cluster module from the library sci-kit. K-Means clustering appears to perform the best compared to our previous attempts, which are discussed in a later section. An array containing the values 0, 1 and 2, with each value corresponding to one of the identified colours, will be returned. A preview of the image with only three colours is then shown to the user.
A dedicated GUI is created to allow the user to execute all these commands. After the preview, the user can send the output array to the Arduino on the car body. After successful transmission, the user is finally prompted to initiate the run.
Pattern Construction and Car Movement
The vehicle will build the pattern by placing the dominos row by row. The domino mechanism will push the domino of the required colour out of the vehicle body. Two DC motors are used to push out the dominos. The Python array received by the Arduino will determine which colour will need to be pushed out.
At the end of each row, the vehicle, fitted with Mecanum wheels, will move laterally to the new row. Each wheel is operated by a Stepper motor for accurate step sizes.
Car Construction
Arduino Mega is used as the micro-controller of the car, to which the RAMS1.4 shield is connected.
The vehicle frame and all components of the domino sliding mechanism are fully 3D-printed. The designs are optimised after numerous iterations and consideration of design principles.