<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>codehop &#187; radio baton</title>
	<atom:link href="https://codehop.com/tag/radio-baton/feed/" rel="self" type="application/rss+xml" />
	<link>https://codehop.com</link>
	<description>#code #art #music</description>
	<lastBuildDate>Mon, 23 Apr 2012 18:37:35 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=4.2.38</generator>
	<item>
		<title>Coding in Time with the @ Scheduler</title>
		<link>https://codehop.com/coding-in-time-with-the-scheduler/</link>
		<comments>https://codehop.com/coding-in-time-with-the-scheduler/#comments</comments>
		<pubDate>Wed, 31 Mar 2010 03:23:36 +0000</pubDate>
		<dc:creator><![CDATA[Jacob Joaquin]]></dc:creator>
				<category><![CDATA[News]]></category>
		<category><![CDATA[max mathews]]></category>
		<category><![CDATA[radio baton]]></category>
		<category><![CDATA[scheduler]]></category>
		<category><![CDATA[scheduling]]></category>

		<guid isPermaLink="false">http://slipmat.noisepages.com/?p=30</guid>
		<description><![CDATA[One idea I have for my theoretical computer music language is having scheduling built right into the syntax, with the hopes that it will add the right balance of functionality and clarity. I like the idea of having a score &#8230; <a href="https://codehop.com/coding-in-time-with-the-scheduler/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>One idea I have for my theoretical computer music language is having scheduling built right into the syntax, with the hopes that it will add the right balance of functionality and clarity.</p>
<p>I like the idea of having a score language separate from the orchestra language, though I&#8217;ve learned over the years that this approach acts as a bottle neck. The @ scheduler is a potential solution to bring both together, without losing the purpose of the score.</p>
<p>Instead of going into great detail on how the @ scheduler might work, I&#8217;ll just present the following four examples.</p>
<p><strong>Example 1 &#8212; Nested Time:</strong></p>
<pre style="font-family: 'Courier New', courier, monaco, monospace, sans-serif; font-size: 1.2em; padding-bottom: 16px">
do_something()     # Do something at beat 0, (@0 assumed)
@2 do_something()  # Do something at beat 2

@5:
    do_something()     # Do something at beat 5: 5 + 0, (@0 assumed)
    @3 do_something()  # Do something at beat 8: 5 + 3
    
    @4:                    # Block starts at beat 9: 5 + 4
        do_something()     # Do something at beat 9: 5 + 4 + 0, (@0 assumed)
        @1 do_something()  # Do something at beat 10: 5 + 4 + 1
</pre>
<p><strong>Example 2 &#8212; Changing values mid-event:</strong></p>
<pre style="font-family: 'Courier New', courier, monaco, monospace, sans-serif; font-size: 1.2em; padding-bottom: 16px">
def foo():
    freq = 440                                 # Initial frequency
    @1 freq *= 2                               # Frequncy doubles at time 1
    output Wavetable.osc(1, freq, sine(8192))  # Output signal
</pre>
<p><strong>Example 3 &#8212; Scheduler error:</strong></p>
<pre style="font-family: 'Courier New', courier, monaco, monospace, sans-serif; font-size: 1.2em; padding-bottom: 16px">
def foo():
    @1 freq = 440
    output Wavetable.osc(1, freq, sine(8192))  # Broken, freq doesn't exist
</pre>
<p><strong>Example 4 &#8212; Organized score + generated events:</strong></p>
<pre style="font-family: 'Courier New', courier, monaco, monospace, sans-serif; font-size: 1.2em; padding-bottom: 16px">
def hat_eights():
    for i in range(0, 8):
        @(i / 2.0) hat()

@0:
    hat_eights()
    @0 kick()
    @1 snare()
    @2 kick()
    @3 snare()
    
@4:
    hat_eights()
    @0 kick()
    @1 snare()
    @2 kick()
    @2.5 kick()
    @3 snare()
</pre>
<p>That last example reminds me of Max Mathews&#8217; <a href="http://www.csounds.com/mathews/manuals/ConductorManual.pdf">Radio Baton Conductor language</a>.</p>
]]></content:encoded>
			<wfw:commentRss>https://codehop.com/coding-in-time-with-the-scheduler/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
	</channel>
</rss>
