I am currently taking graduate school classes to get a second teaching certification in Computer Science (my primary certification is in music). As the final project for my Curriculum Development course, I had to develop a unit plan for a subject of my choosing. Naturally, I wanted to do something with Sonic Pi, so I decided to do a unit on creating generative music. It is meant to be a later unit in a class for beginners to coding.
The unit is posted on github. It includes detailed lesson plans with code examples, assignment sheets, lesson slides etc. I figured I’d share it here for others to take a look at. The lessons and documents are uploaded as pdfs but this link is to a Google Drive folder where each part is in its own Google Doc.
Here are the topics covered:
- Using Randon Events to Write a Song
- Defining Indeterminate/Aleotoric
- Create piece using dice rolls and coin flips
- Recreating Dice Roll and Coin Flip piece in Sonic Pi
- True random vs Pseudo random
- Using rrand_i to choose random integer from a range of numbers
- Establish why same number is always chosen
- Use_random_seed
- Discuss concept of pseudo random
- Time.now.to_i
- Manipulating data structures
- Identify ways to manipulate a sequence of numbers
- Introduce methods for manipulating data structures
- Provide randomized input to methods
- Looping through data structures of different lengths
- Identify issues with basic looping structures
- Finding length of data structures = .length
- Single Line Conditional Statements
- Single Line if statements
- Storing randomized output in variables
- Dice Roll simulation
- Out of Class Assignment Roll Out
- Nested Conditionals
- Intro to Nested Conditionals
- Probability
- one_in() function
- Random Durations
- Note Duration
- Sample Rate
8-11. Final Project - Generative Music
- Defining Generative Music
- Assignment Roll Out
- In Class Work Time
- Gallery Walk