Segregated clock and sequencer; added drum machine.

This is a pretty big change, probably the biggest since shedding
Surf.  The clock and sequencer are now discrete things which talk
to each other via the main code.  This means the sequencer is less
smart and has a much lower resolution, not being aware of time at
all anymore, which allows it to now (theoretically, by overriding
it listening to the internal clock, letting it listen to an external
clock) become a slave to another clock via DIN sync.  Sliding is no
longer tempo aware, now using a simple (software) slew limiter instead
of tempo based calculations.

Tracker 1 is completely gone.  Multiple channels are completely gone.
The different play modes are gone.

This is no longer a fully self-contained song writing tool.  It's
now one small cog in a larger overall machine.  This is major feature
retreat.

I also made a drum machine.

The code and comments are in bad need of refactoring, which should
be my next task.

Squashed commit of the following:

commit 162842ff5152522a55b94f6fda59cbce76db237a
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 19:30:11 2012 +0100

    Made slew limiter time aware.

    I had to completely guess what might be a good time for the portamento
    to take.  Currently, the exact value of the slide is ignored (it's
    treated as a boolean, which is all the interface will allow anyway),
    and if it's activated, then the pitch creeps one 12-bit integer
    closer to the correct pitch value per millisecond.

commit ef50d6ce144e5fb435ea22296258b5e55462e949
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 19:22:32 2012 +0100

    Renamed song/memory files.

    This is to reflect the fact that they've now diverged, and are no
    longer compatible with one another.

commit 77e5d29156fac6ae24fd12b4637dfe0fe04624b3
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 19:15:26 2012 +0100

    Fixed pattern changing in both machines.

commit d9546ceea43fc291ad8f0d27870a7933f3e429fc
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 18:52:55 2012 +0100

    Fixed drum machine pattern loading/saving issues.

commit 5824b512282b99f5af1e6dd2152fecf7095c0b21
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 17:09:28 2012 +0100

    Started debugging drum machine pattern writing.

commit 94e9e1b128487a6aeff96bb6f8d104e257659d1e
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 16:47:59 2012 +0100

    Triggers now act like triggers.

    Or at least, gates that aren't under the effect of a slide.

commit 6bda625e6247cc3cc80474552cb98e653bdc5a77
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 16:38:57 2012 +0100

    Updated readme file.

commit 3db588381004a58517fd8f995c4c805175772c18
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 16:34:47 2012 +0100

    Trigger work.

    They're currently acting more like gates, so I'll need to fix that,
    for triggers that are on consecutive rows.  But they are starting
    to work already.

commit ca75f63c5d310358d1a894b7aa4d446c2eab7403
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 16:31:25 2012 +0100

    Started to bugfix drum machine.

commit cf50183354fb1218e45fbdaf574e1a8dea645582
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 16:24:25 2012 +0100

    Various minor touches.

    * Added slew notes to slew limiter
    * Removed main notes
    * Updated note length to better match original acid machine

commit a2ae53e9d76f3f096646e53b5f7832dea2abbec0
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 16:18:35 2012 +0100

    Fixed slide.

    The actual sliding of the pitch itself should occur on the note
    *after* the one which has slide set.

commit d891babf95b111b2b2ea1ee46fc92ccc04cfc643
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 16:13:20 2012 +0100

    We now have very basic sliding.

commit a8e2c33dcedf79dc6751e4df7c3f984ec49d1169
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 15:51:25 2012 +0100

    Stopped filenames of different machines clashing.

commit 2b8d3f93aa9497ed4607bca21b11b7b843a9f192
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 15:36:44 2012 +0100

    Started work on drum machine.

commit 687e8687727960ecf57539181d984d229e2685ff
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 15:22:08 2012 +0100

    Fixed gate!

commit 93ac54fce7bb71f8dd412515612b4a219c702bfb
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 15:19:16 2012 +0100

    Replacing magic numbers with constants.

    Still not quite there with the gate yet.

commit 16f5363f564ef5a28241911d4d2cd4336352c689
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 15:07:44 2012 +0100

    Getting there with implementing gate output...

commit 1d835117c80655462eb5e4e83ed2c124edc70337
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 14:58:22 2012 +0100

    Accent and slide tweaking.

    Stepper Acid will not slide accents, only pitches.

    The Stepper Acid sequencer won't slide anything at all.  I'll make
    a new time-aware function to act as a slew limiter.

commit bed19f5b5dec7c386e5b381d8b8c645f8a2ce7a0
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 14:43:53 2012 +0100

    More major overhauling.

    * Removed swing from both sequencers (the clock will do that now).
    * Removed everything but triggers from drum sequencer.

commit 212f0508f3ac030cfa1fcb12bc0772dd881576fe
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 14:31:36 2012 +0100

    Removed multiple channels, CV2, triggers and old sliding method from acid sequencer.

commit 49319ea6af3147aff04c7022d56f77e04025624d
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 14:09:38 2012 +0100

    Fixed acidline machine prototype.

commit 59c1d202042e4a039b1ac556e4a0a684f2d3533c
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 14:06:12 2012 +0100

    Segregating the acid and drum sequencers too.

commit dc4d0809fe564d34b37bcd1b1f8e2ef1cc3dfb52
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 13:55:52 2012 +0100

    Removed tracker interface and clock test.

    This is another fundamental philosophical change.

    Someone requested DIN sync input in this thread:
    http://www.muffwiggler.com/forum/viewtopic.php?t=59325 This led to
    me reading up on DIN sync and tape sync, and realising that even
    internally, clocks and sequencers segregate work, forcing the sequencer
    to be very simple as it can no longer have any higher resolution
    than a few clicks per sixteenth note (24, 12 or 6, depending on the
    clock's resolution...  *possibly* 48 with a 96 PPQN clock with an
    exact 50% duty cycle, but I digress...).

    This fundamentally changes the nature of the game, making the sequencer
    less smart by design.  So I'm getting back to basics for now, making
    a stripped-down set of machines closer to my original designs: a
    single channel acid machine, and an eight channel drum machine, which
    require you to manually change pattern, and can't press run/stop on
    your behalf.

commit 96a5015bab5ca85010b25bbd8a11dc8fbb681e8c
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 13:54:31 2012 +0100

    Implemented 96 PPQN in clock and 48 PPQN in sequencer.

commit 487e9163c95a9a1a6340dbf4eb970c51d32d3742
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 13:43:34 2012 +0100

    Updating notes.

commit 64d6c1b3f54603dd73d523ff24f8aa8180cefa98
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 12:29:00 2012 +0100

    Note update.

    Noting the pulse when low as well as high lets us double our resolution.

commit b2456a2dc1d2dc06eda05aede13c5e7d5f248043
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 12:25:50 2012 +0100

    Added notes, as I'm starting to lose track of what I'm doing.

commit a3af29000ca440bc01fa1fb2e75e8ef67f1d473d
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 11:32:08 2012 +0100

    Fixed pattern changing.

    Both while paused and while playing.

commit 6c470ae6470d1f125cce1a661052f9e1d2185240
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 11:22:39 2012 +0100

    I knew I shouldn't have used "==".  Fixed.

    You can now storm right through the end of the pattern as you're
    decreasing its length, and you'll always get pulled right back to
    the beginning.

commit 8fd0c0dcd6c8b8810128de4e19e7ba3fb01c0f8f
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 11:20:37 2012 +0100

    Variable length patterns are now OK to play again.

    ...just as long as you don't decrement the number of rows while playing
    the last one...

commit d1d4567d1560f33815f61d31c92ea6240acab3df
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 11:16:30 2012 +0100

    Removed alternate play modes.  Now there's only one.

commit 631a87cd9580d47e78f2cc9cd2f14c54cb80b3ec
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 11:10:14 2012 +0100

    You can now toggle run/stop.

    We're heading deep into a rabbit hole of the sequencer becoming very
    stupid.  As people seem to prefer anyway, it won't have automatic
    song playing anymore, only manual pattern changing.

commit efcd6c431568b4eb51c3e1dd16be96d8928c211e
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 11:04:12 2012 +0100

    Alternate lastPulse routine.

    Easier to keep track of.

commit e6bd1c55ef069679ad7cdeca30b841930e2650de
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 11:02:38 2012 +0100

    Got the sequencer cycling row numbers, at least.

commit 37e7c62bd76c621b93f53cb982aea5bb93a37591
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 10:48:31 2012 +0100

    Songs do *not* store the tempo, again.

    We're basically making the step sequencer more stupid, delegating
    all tempo related tasks (even swing, eventually) to the
    newly-externalised clock instead.

commit 1fc2adfd9eb6a7e77f89c93f26b4ae5f1e009fca
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 10:39:18 2012 +0100

    Starting work on making the sequencer simpler.

commit ee219001c4acc043cd169ad75f1ce2b963ea198b
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 10:10:15 2012 +0100

    Counting beats.  Looking good.

commit 673711ab682b629a1b9f129b37b058af4e993574
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 09:49:45 2012 +0100

    Trying out a completely different clock method.

    No modulo arithmetic this way.  Let's see if this makes changing the
    tempo smoother.

commit 347c965089a1f9a81e46b89a4c648dcf7a7df645
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 09:34:01 2012 +0100

    Minor refactoring.

commit 74209a352a0f5c68b5f3c86054c895e253e078e1
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 09:32:29 2012 +0100

    Commented things a bit better.

commit d965e97accc784287d5cc3c02802389b562bb118
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 09:28:47 2012 +0100

    Simplified terminology.

    I know I want it to be simple to understand, but sometimes that means
    being just a *little* terse.

commit 23bfccbc913f7c881cd1392d03889cf5068c7fa8
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 09:19:46 2012 +0100

    Added key and tempo up/down to clock test app.

    I believe we still have the problem of minor glitches when changing
    the tempo, as it pretends it's always been that tempo.

commit a52c2e99da0f8a620a6c949511bc445d25d9a144
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 09:06:26 2012 +0100

    Fixed clock testing code.  All working.

commit a2fd222cbb2721a497d6fb61ff6ac26c6018102d
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sat May 26 09:01:56 2012 +0100

    Tempo setting bugfix.

    Removed redundant line.

commit 8ed1f2768e78f70e133bfeca89c76b1cf9a367e8
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Fri May 25 23:51:40 2012 +0100

    Implemented rudimentary clock based shenanigans.

commit 933db4bfe5bfa2cb2692041df475ad4919c32f55
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Fri May 25 23:20:14 2012 +0100

    Testing the waters with segregating the clock from the sequencer.