Skip to content

Overview of the Modulo1 Programming Language

The Modulo1 programming language was specifically designed to make it easy to write code that makes music production easy. The primary focus is on algorithms that can be used to define a new musical genre (which we refer to as a vibe) via computer code. Modulo1's intelligent algorithms then create random music that matches the requirements specified in the code.

What is a computer program?

Basically, a computer program is a list of instructions, written in a computer language that, when run, will cause the computer's data to change in ways that are meaningful and result in a desirable outcome.

Computer programs usually also include comments, written by the programmer/s, that are for the benefit of programmer/s and not to be interpreted as code. To write a short comment, include the // symbol and Modulo1 will know to ignore any text between // and the end of the line. For example:

var myValue = 7;    // This is a comment!

If you need to write a longer comment, that occupies one or more lines. Then write your comment between /* and */. Any text between /* and */ will be ignored by Modulo1. For example:

This is a longer comment
that occupies multiple lines

var myValue = 12;

What kinds of instructions are possible in the Modulo1 programming language?

  1. Creating new data
  2. Changing the value of some existing data
  3. Changing the type of some existing data
  4. Performing mathematical calculations
  5. Controlling the flow of the app (e.g. by creating a loop)
  6. Creating a function
  7. Running functions
  8. Creating structures that hold data, functions, and/or other structures
  9. Retrieving data or code published by other developers
  10. Declaring that an error has occurred (and that the app should stop)
  11. Acknowledging that an error has occurred (and recovering from it)
  12. Loading data into an intelligent algorithm
  13. Running an intelligent algorithm

What kinds of outcomes are possible as a result of these instructions?

  • Designing a vibe, i.e. a new musical genre
  • Designing the tone of a drum
  • Designing the tone of an instrument
  • Composing the beats of a new drum riff
  • Composing the musical notes of a new instrument melody
  • Adjusting the audio effects on one or more drums and/or instruments
  • Designing a derivative drum tone, based on an existing drum tone
  • Designing a derivative instrument tone, based on an existing instrument tone
  • Composing a derivative drum riff, based on an existing drum riff
  • Composing a derivative melody, based on an existing melody
  • Creating a graphical user interface (GUI) for an app or plugin