I first stumbled upon MusicBlocks when I participated with Sugar Labs in Google Code In 2017/2018. As MusicBlocks was one of the main projects of Sugar Labs (alongside other projects such as the Sugar shell, Sugarizer and Turtle Blocks), I was eager to try the program out.
After downloading the MusicBlocks program from the repository, I ran the program locally on my Google Chrome browser by executing the index.html file inside. I was greeted with an animation of blocks which contained ascending notes. I was then brought to a screen containing a sample program.
Using MusicBlocks for the first time – reading the tutorial to understand the user interface.
I found the MusicBlocks interface to be very visually appealing and easy to use – at first glance of the sample program I knew what I could do. The names of the blocks, such as ‘note value’, ‘pitch’ and ‘start’ were very intuitive as well. The MusicBlocks interface reminded me of Scratch, another drag-and-drop educational tool.
However, on closer inspection , I feel that when it comes to music, especially in the field of creating and exploring tunes and melodies, MusicBlocks is an immensely better tool to use. Unlike Scratch, where users have to rely on prerecorded sounds and can only create simple notes, there exist a wide range of tools on MusicBlocks which users can use to their heart’s content, ranging from the widgets such as the pitch-time matrix to other functions such as the “Set Key”, “Crescendo” and “Staccato” blocks. Many of the blocks which exist in MusicBlocks by default were nowhere to be seen in Scratch (in fact Scratch users have to code them by themselves, a hard task given that understanding and replicating these blocks requires a substantial understanding of both computer logic and music terminology).
I clicked on the ‘Help’ button and was immediately brought to a tutorial of how the user interface of MusicBlocks worked and what I could do with the program. The tutorial allowed me to understand how to navigate around the user interface, how to find, drag, drop and use other blocks, as well as how to save the work I had done by converting it to a PNG file or a Lilypond file. Within minutes, I was on my way to develop projects which could integrate both music and graphics.
I decided to design a program for MusicBlocks as part of my Google Code In task. After familiarizing myself with the user interface and the various drag-and-drop blocks I could manipulate to achieve the desired outcome, I set out to design a MusicBlocks program which not only played a sequence of ascending notes, but also had some graphics to accompany it.
I began implementing the program by dragging out a “Note Value” block from the Rhythm palette, then using a “Pitch Number” block to set the pitch of the note played at the beginning to 0. Following that, I dragged out a “Repeat” block and a “Scalar Step” block to increment the pitch number and hence the pitch of the following notes, thereby creating a series of ascending notes. I set the number of repeats to 24 – this would mean that the ascending notes would span 3 octaves.
However, the program was by no means complete – there was no graphics implemented yet. I decided to use a “Set Pen Color” block, which I set to 0 in the beginning, and then incremented it over the next 24 repeats to produce a color spectrum. Using the “Arc” block, I set the program to cover one-eighths (45 degrees) of a circle for every repeat, hence creating a spiral. The spiral would cover 3 revolutions, with the spiral returning to its original location every 8 out of the 24 repeats.
After some time and feedback from my Google Code In task mentors on how I could improve my program, I further added an argument which tied the radius of the “arc” block to the pitch number in an exponential relationship. Through the next 24 repeats, the pitch number would increase, along with the block. to increase the radius of the spiral, in order to give the impression of the spiral spreading outwards. (A screenshot of the eventual spiral is shown below). After receiving the approval of my Google Code In mentors, I added my program to the MusicBlocks repository as one of the sample programs.
Contributing To MusicBlocks
After designing my first program which combined both music and graphics, my interest in MusicBlocks grew. I decided to contribute to the MusicBlocks community by adding functionalities as well as documentation to help other users who just like me are interested about MusicBlocks. Through various Google Code In tasks and the help of my mentors, I was able to design and implement new blocks into the MusicBlocks interface, such as the ‘Noise’ block in the ‘Set Timbre’ clamp, adding the ability to create different types of noise (white noise, pink noise and brown noise).
I also helped to improve the documentation by replacing some outdated images in the guide with new ones that help to demonstrate sample programs. Currently, I am working on translating the MusicBlocks guide into Simplified Chinese to allow MusicBlocks to reach a wider audience and for more people to learn how to use the program. Through contributing to MusicBlocks, not only was I given the chance to improve a program I had much interest in, I could also put my software development skills to good use through tackling bugs and other issues.
A snapshot of the program I developed integrating both graphics and music. (Link To Run Live)
Using MusicBlocks and experimenting with it definitely sparked my interest in music as well as coding. It allowed me to gain insights into how these two seemingly different topics can be integrated together and used to create something better and more enjoyable. Compared to the mundane music lessons I had at school (where we learnt about music theory and music theory only), MusicBlocks was on a different level of engagement. I actually felt motivated to discover and explore more about music through MusicBlocks as it was a place where I could freely explore and generate my own style of music and graphics. Moreover, unlike music lessons in school where there exists a strict lesson plan, I was able to create music to my heart’s content.
Furthermore, through MusicBlocks, I was able to learn about different music terminology which the music lessons had covered in school but I did not really understand, such as octaves, crescendo, staccato, slurring, swinging notes and tied notes. I was able to apply these terminology and the corresponding blocks to create a particular piece of music, thereby strengthening my understanding of these music terms.
Through trying MusicBlocks, I feel that music is not just about music theory and sight reading, but about experimenting and truly understanding how music works through playing it yourself. MusicBlocks gives me the opportunity to play around and in the process learn how different blocks and music terms can affect the eventual outcome of the music piece that is played. If MusicBlocks was used in music lessons, they would be much more engaging and fun!