Sonic Pi té una interfície molt senzilla per programar música. Donem-li una ullada.
A - Controls d’execució B - Controls d’edició C - Informació i ajuda D - Editor de codi E - Tauler de preferències F - Visor de registre G - Sistema d’ajuda H - Visor
Aquests botons rosa són els controls principals per començar i aturar sons. Hi ha el botó Run, que serveix per iniciar l’execució del codi; el botó Stop, per aturar tot el codi en execució; Save, per desar el codi a un arxiu extern; i Record, per crear un enregistrament (un arxiu WAV) dels sons executats.
These orange buttons allow you to manipulate the code editor. The Size + and Size - buttons allow you to make the text bigger and smaller.
Aquests botons blaus et donen accès a informació, ajuda i preferències. El botó Info obre la finestra d’informació, la qual conté informació sobre el propi programa Sonic Pi -l’equip base, la seua història, els contribuïdors i la comunitat. El botó Help mostra o amaga el sistema d’ajuda (G) i el botó Prefs activa la finestra de preferències, que et permet controlar alguns paràmetres bàsics del sistema.
Aquesta és l’àrea on escriuràs el teu codi i composaràs/interpretaràs música. És un editor de text senzill on pots escriure codi, esborrar-lo, copiar-lo i enganxar-lo, etc. Pensa que és una versió simplificada de Word o Google Docs. L’editor pintarà de diferents colors el codi automàticament, tenint en compte el significat del codi. Al principi, això pot semblar estrany, però prompte ho trobaràs molt útil. Per exemple, sabràs que quelcom és un número perquè és de color blau.
Sonic Pi permet canviar certs paràmetres accessibles a través del botó Prefs. Aquest botó mostra o amaga el tauler de preferències, el qual inclou diverses opcions que poden ser canviades. Per exemple, forçar el mode mono, invertir l’estèreo, mostrar o amagar l’eixida de registre, així com un controlador de volum i un selector d’àudio per a la Raspberry Pi.
Quan executeu codi, el visualitzador del registre mostra informació sobre allò que està fent el programa. Per defecte, veureu un missatge per cada so que creeu amb el temps exacte en què fou disparat aquest so. Açò és molt útil per depurar codi i entendre què és el que el vostre codi està fent.
One of the most important parts of the Sonic Pi interface is the help system which appears at the bottom of the window. This can be toggled on and off by clicking on the blue Help button. The help system contains help and information about all aspects of Sonic Pi including this tutorial, a list of available synths, samples, examples, FX and a full list of all the functions Sonic Pi provides for coding music.
The scope viewer allows you to see the sound you’re hearing. You can easily see that the saw wave looks like a saw and that the basic beep is a curvey sine wave. You can also see the difference between loud and quiet sounds by the size of the lines. There are 3 scopes to play with - the default is a combined scope for the left and right channels, there is a stereo scope which draws a separate scope for each channel. Finally there is a Lissajous curve scope which will show the phase relationship between the left and right channels and allows you to draw pretty pictures with sound (https://en.wikipedia.org/wiki/Lissajous_curve).