Difference between revisions of "220a-fall-2014"

From CCRMA Wiki
Jump to: navigation, search
(Tutorial Session Oct. 6: HW1)
(How do I create an HTML file?)
Line 39: Line 39:
 
As Chris suggested, one way to do it is to use LibreOffice: https://ccrma.stanford.edu/courses/220a-fall-2013/resources/hw-factory-instructions.html
 
As Chris suggested, one way to do it is to use LibreOffice: https://ccrma.stanford.edu/courses/220a-fall-2013/resources/hw-factory-instructions.html
  
You can also write an HTML file from scratch. Here's a very good tutorial on that topic: http://www.w3schools.com/html/  
+
You can also write an HTML file from scratch. Here's a very good tutorial on this topic: http://www.w3schools.com/html/  
  
 
As an example, your HW1 html file could look like:
 
As an example, your HW1 html file could look like:
  
 
<pre>
 
<pre>
 +
 +
<!DOCTYPE html>
 +
<html>
 +
<body>
 +
<h1>Music 220a - Homework 1: Data Sonification</h1>
 +
<h2>Chuck Files / Data Files</h2>
 +
<ul>
 +
<li><a href="https://ccrma.stanford.edu/~me/220a/HW1/HW1-1.ck">file.ck</a></li>
 +
<li><a href="https://ccrma.stanford.edu/~me/220a/HW1/HW2-2.ck">file2.ck</a></li>
 +
<li><a href="https://ccrma.stanford.edu/~me/220a/HW1/data.dat">data.dat</a></li>
 +
</ul>
 +
<h2>Generated Wave File</h2>
 +
<ul>
 +
<li><a href="https://ccrma.stanford.edu/~me/220a/HW1/HW1.wav">HW1.wav</a></li>
 +
</ul>
 +
<h2>Description</h2>
 +
<p>Short description of your piece.</p>
 +
<h2>Sources</h2>
 +
<p>Something about the time series you used.</p>
 +
</body>
 +
</html>
  
 
</pre>
 
</pre>

Revision as of 09:52, 7 October 2013

Welcome on the Music 220a wiki!

Music Presentation Sign Up

Please use your full name as appeared on the class list.

  • 09/26 (THU) : 3 volunteers :)
  • 10/01 (TUE) : Chet Gnegy, Madeline Huberth, Holly Jachowski
  • 10/03 (THU) : Elliot Kermit-Canfield, Graham Davis, Clark Pang
  • 10/08 (TUE) : Victoria Grace, Alex Ramsey, Alex Chechile
  • 10/10 (THU) : Ezra Crowley, Freddy Avis, Diego Aguilar
  • 10/15 (TUE) : Nette Worthey, Constantin Basica,
  • 10/17 (THU) :
  • 10/22 (TUE) :
  • 10/24 (THU) :
  • 10/29 (TUE) :
  • 10/31 (THU) :
  • 11/05 (TUE) :

Tutorial Session Oct. 6: HW1

How do I format a .dat file on Linux?

Well it's very simple, just create a text a text file in gedit and fill it with the values you'd like to use. There must be one value per line and the last line of the file must be left blank.

How do I format a .dat file on Mac OSX?

  • open a terminal
  • cd to the directory where you want to create your data file like: cd Desktop/220a/
  • type: touch myData.dat This creates an empty file called myData.dat.
  • type: nano myData.dat This opens the file you just created in the terminal.
  • copy and paste the data values in the terminal.
  • make sure that you have at least one blank line at the end of your file.
  • do ctl+o to save the values in myData.dat
  • do ctl+x to exit nano

How do I create an HTML file?

As Chris suggested, one way to do it is to use LibreOffice: https://ccrma.stanford.edu/courses/220a-fall-2013/resources/hw-factory-instructions.html

You can also write an HTML file from scratch. Here's a very good tutorial on this topic: http://www.w3schools.com/html/

As an example, your HW1 html file could look like:


<!DOCTYPE html>
<html>
<body>
<h1>Music 220a - Homework 1: Data Sonification</h1>
<h2>Chuck Files / Data Files</h2>
<ul>
<li><a href="https://ccrma.stanford.edu/~me/220a/HW1/HW1-1.ck">file.ck</a></li>
<li><a href="https://ccrma.stanford.edu/~me/220a/HW1/HW2-2.ck">file2.ck</a></li>
<li><a href="https://ccrma.stanford.edu/~me/220a/HW1/data.dat">data.dat</a></li>
</ul>
<h2>Generated Wave File</h2>
<ul>
<li><a href="https://ccrma.stanford.edu/~me/220a/HW1/HW1.wav">HW1.wav</a></li>
</ul>
<h2>Description</h2>
<p>Short description of your piece.</p>
<h2>Sources</h2>
<p>Something about the time series you used.</p>
</body>
</html>

Tutorial Session Sept. 26: HW1, simplest Chuck code & UNIX

Quick UNIX tutorial: http://freeengineer.org/learnUNIXin10minutes.html

Download Chuck: http://chuck.cs.princeton.edu/release/

Download MiniAudicle: http://audicle.cs.princeton.edu/mini/

//TriOsc, SqrOsc, etc
SinOsc a => dac; 
//a => dac.right;
//a => dac.left;

440 => a.freq;
0.9 => a.gain;

while(true){
    //<<< Std.rand2f( 100.0, 1000.0 ) >>>;
    Std.rand2f( 100.0, 1000.0 ) => a.freq;
    100::ms => now;
}