File: node1.html

package info (click to toggle)
mma 0.12-1.1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 3,020 kB
  • ctags: 1,143
  • sloc: python: 5,235; makefile: 37
file content (434 lines) | stat: -rw-r--r-- 14,400 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">

<!--Converted with LaTeX2HTML 2002-2-1 (1.70)
original version by:  Nikos Drakos, CBLU, University of Leeds
* revised and updated by:  Marcus Hennecke, Ross Moore, Herb Swan
* with significant contributions from:
  Jens Lippmann, Marek Rouchal, Martin Wilck and others -->
<HTML>
<HEAD>
<TITLE>Overview and Introduction</TITLE>
<META NAME="description" CONTENT="Overview and Introduction">
<META NAME="keywords" CONTENT="mma">
<META NAME="resource-type" CONTENT="document">
<META NAME="distribution" CONTENT="global">

<META NAME="Generator" CONTENT="LaTeX2HTML v2002-2-1">
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">

<LINK REL="STYLESHEET" HREF="mma.css">

<LINK REL="next" HREF="node2.html">
<LINK REL="previous" HREF="mma.html">
<LINK REL="up" HREF="mma.html">
<LINK REL="next" HREF="node2.html">
</HEAD>

<BODY >
<!--Navigation Panel-->
<A NAME="tex2html267"
  HREF="node2.html">
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next"
 SRC="file:/usr/lib/latex2html/icons/next.png"></A> 
<A NAME="tex2html265"
  HREF="mma.html">
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up"
 SRC="file:/usr/lib/latex2html/icons/up.png"></A> 
<A NAME="tex2html259"
  HREF="mma.html">
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous"
 SRC="file:/usr/lib/latex2html/icons/prev.png"></A>   
<BR>
<B> Next:</B> <A NAME="tex2html268"
  HREF="node2.html">Running MMA</A>
<B> Up:</B> <A NAME="tex2html266"
  HREF="mma.html">Reference Manaul</A>
<B> Previous:</B> <A NAME="tex2html260"
  HREF="mma.html">Reference Manaul</A>
<BR>
<BR>
<!--End of Navigation Panel-->
<!--Table of Child-Links-->
<A NAME="CHILD_LINKS"><STRONG>Subsections</STRONG></A>

<UL>
<LI><A NAME="tex2html269"
  HREF="node1.html#SECTION00110000000000000000">License, Version and Legalities</A>
<LI><A NAME="tex2html270"
  HREF="node1.html#SECTION00120000000000000000">Installing <I><B>MMA</B></I></A>
<LI><A NAME="tex2html271"
  HREF="node1.html#SECTION00130000000000000000">Running <I><B>MMA</B></I></A>
<LI><A NAME="tex2html272"
  HREF="node1.html#SECTION00140000000000000000">Comments</A>
<LI><A NAME="tex2html273"
  HREF="node1.html#SECTION00150000000000000000">Theory Of Operation</A>
<LI><A NAME="tex2html274"
  HREF="node1.html#SECTION00160000000000000000">Case Sensitivity</A>
</UL>
<!--End of Table of Child-Links-->
<HR>

<H1><A NAME="SECTION00100000000000000000">
Overview and Introduction</A>
</H1>

<P>
<I>Musical MIDI Accompaniment</I>, <I><B>MMA</B></I><A NAME="tex2html2"
  HREF="#foot193"><SUP>1.1</SUP></A>, generates standard MIDI<A NAME="tex2html3"
  HREF="#foot194"><SUP>1.2</SUP></A> files which can be used as a backup track for a soloist. It was written especially for me--I am an aspiring saxophonist and wanted something to practice my jazz solos. With <I><B>MMA</B></I> I can create a track based on the chords in a song, transpose it to the correct key for my instrument, and play my very bad improvisations until they get a bit better.

<P>
I also have a small combo group which is always missing at least one player. With <I><B>MMA</B></I> generated tracks we can practice and perform even if a rhythm player is missing. This all works much better than I expected when I started to write the program.

<P>

<H1><A NAME="SECTION00110000000000000000">
License, Version and Legalities</A>
</H1>

<P>
The program <I><B>MMA</B></I> was written and is copyright Robert van der Poel, 2002--2004.

<P>
This program, the accompanying documentation, and library files can be freely distributed according to the terms of the GNU General Public License (see the distributed file ``COPYING''). 

<P>
If you enjoy the program, make enhancements, find bugs, etc. send a note to me at <TT><A NAME="tex2html4"
  HREF="bvdp@uniserve.com">bvdp@uniserve.com</A></TT>;  or a postcard (or even money) to PO Box 57, Wynndel, BC, Canada V0B 2N0. 

<P>
The current version of this package is maintained at: <TT><A NAME="tex2html5"
  HREF="http://mypage.uniserve.com/~bvdp/mma/mma.html">http://mypage.uniserve.com/~bvdp/mma/mma.html</A></TT>.

<P>
This document reflects version 0.12
 of <I><B>MMA</B></I>. 
<DIV ALIGN="CENTER">

	<TABLE CELLSPACING=0 CELLPADDING=10" BGCOLOR="#dddddd" BORDER=3><TR> <TD>
	<IMG
 WIDTH="504" HEIGHT="186" ALIGN="MIDDLE" BORDER="0"
 SRC="img1.png"
 ALT="$\textstyle \parbox{.9\textwidth}{
\vspace{1ex}
\textbf{Warning:} \it This progr...
...t much easier for me to generate a really good product for all of us to enjoy.}$">
<BR>
<BR> 

	</TD></TR></TABLE> 
</DIV>
<P>
<DIV ALIGN="CENTER">
</DIV>

<P>

<H1><A NAME="SECTION00120000000000000000">
Installing <I><B>MMA</B></I></A>
</H1>

<P>
<I><B>MMA</B></I> is a Python program developed with version 2.3 of Python. At the very least you will need this version (or later) of Python! 

<P>
To play the MIDI files you'll need a MIDI player. Pmidi, tse3play, and many others are available  for Linux systems. For Windows and Mac systems I'm sure there are many, many choices.

<P>
You'll need a text editor to create input files.

<P>
<I><B>MMA</B></I> consists of a variety of bits and pieces:

<P>

<UL>
<LI>The executable Python script, mma, must somewhere in your path. For users running a Windows system, please check our website for details on how to install on these systems.<A NAME="tex2html6"
  HREF="#foot244"><SUP>1.3</SUP></A>
<P>
</LI>
<LI>A number of Python modules. These should all be installed 		under the directory /usr/local/share/mma/modules.

<P>
</LI>
<LI>A number of library files defining standard rhythms. These should all be installed under the directory /usr/local/share/mma/lib/stdlib.

<P>
</LI>
</UL>

<P>
The script ``install'' will (hopefully) install <I><B>MMA</B></I> properly for you. It assumes that main script is to be installed in /usr/local/bin and the support files in /usr/local/share/mma. If you want an alternate location, you can edit the paths in the script. The only supported alternate to use is /usr/share/mma.

<P>
In addition, you <I>can</I> run <I><B>MMA</B></I> from the directory created by the untar. This is not recommended, but will show some of <I><B>MMA</B></I>'s stuff.

<P>
You should be ``root'' to run the install script.

<P>

<H1><A NAME="SECTION00130000000000000000">
Running <I><B>MMA</B></I></A>
</H1>

<P>
For details on the command line operations in <I><B>MMA</B></I> please refer to chapter <A HREF="node2.html#sec-running">2</A>.

<P>
To create a MIDI file you need to:

<P>

<OL>
<LI>Create a text file (also referred to as the ``input file'') with instructions which <I><B>MMA</B></I> understands. This includes the chord structure of the song, the rhythm to use, the tempo, etc. The file can be created with any 		suitable text editor.

<P>
</LI>
<LI>Process the input file. From a command line the instruction:

<P>

	<TABLE CELLSPACING=0 CELLPADDING=5" BGCOLOR="OldLace" BORDER=3><TR> <TD>
<BLOCKQUOTE><B>mma myfile &lt;ENTER&gt; </B></BLOCKQUOTE>

	</TD></TR></TABLE> 

<P>
will invoke <I><B>MMA</B></I> and, assuming no errors are found, create a MIDI file ``myfile.mid''. 

<P>
</LI>
<LI>Play the MIDI file with any suitable MIDI player.

<P>
</LI>
<LI>Edit the input file again and again until you get the perfect track.

<P>
</LI>
<LI>Share any patterns, sequences and grooves with the author so they can be included in future releases!
</LI>
</OL> 

<P>
An input file consists of the following information:

<P>

<OL>
<LI><I><B>MMA</B></I> directives. These include <I>Tempo</I>, <I>Time</I>, <I>Volume</I>, etc. See chapter <A HREF="node17.html#sec-directives">17</A>.		.

<P>
</LI>
<LI><I>Pattern</I>, <I>Sequence</I> and <I>Groove</I>  See chapters <A HREF="node4.html#sec-pats">4</A>, <A HREF="node5.html#sec-seqs">5</A> and <A HREF="node6.html#sec-grooves">6</A>.

<P>
</LI>
<LI>Music information. See chapter <A HREF="node8.html#sec-music">8</A>.

<P>
</LI>
<LI>Comment lines and blank lines. See below.

<P>
</LI>
</OL> 

<P>
Items 1 to 3 are detailed later in this manual. Please read them before you get too involved in this program.

<P>

<H1><A NAME="SECTION00140000000000000000">
Comments</A>
</H1>

<P>
We do believe that proper indentation, white space and comments are a <I>good thing</I>. But, in most cases <I><B>MMA</B></I> really doesn't care:

<P>

<UL>
<LI>Any leading space or tab characters are ignored,

<P>
</LI>
<LI>Multiple tabs and other white space are treated as single characters,

<P>
</LI>
<LI>Any blank lines in the input file are ignored.
</LI>
</UL>

<P>
Each line is initially parsed for comments. A comment is anything following a ``//'' (2 forward slashes).<A NAME="tex2html7"
  HREF="#foot275"><SUP>1.4</SUP></A>
<P>
Comments are stripped from the input stream. Lines starting with the <I>Comment</I> directive are also ignored. See  the <I>Comment</I>  discussion for details (<A HREF="node17.html#comment"><IMG  ALIGN="BOTTOM" BORDER="1" ALT="[*]"
 SRC="file:/usr/lib/latex2html/icons/crossref.png"></A>).

<P>

<H1><A NAME="SECTION00150000000000000000">
Theory Of Operation</A>
</H1>

<P>
To understand how <I><B>MMA</B></I> works it's easiest to look at the initial development concept.Initially, a program was wanted  which would take a file which looked something like:

<P>

	<TABLE CELLSPACING=0 CELLPADDING=5" BGCOLOR="OldLace" BORDER=3><TR> <TD>
<BLOCKQUOTE><B>Tempo 120 
<BR>
Fm 
<BR>
C7 
<BR>	...</B></BLOCKQUOTE>

	</TD></TR></TABLE> 

<P>
and end up with a MIDI file which played the specified chords over a drum track.

<P>
Of course, after starting this ``simple'' project a lot of complexities developed.

<P>
First, the chord/bar specifications. Just having a single chord per bar doesn't work--many songs have more than one chord per bar. Second, what is the rhythm of the chords? What about a bass line? Oh, and what drum track?

<P>
Well, things got more complex after that. At a bare minimum, we needed the ability to:

<P>

<UL>
<LI>Be able to specify multiple chords per bar,
</LI>
<LI>Be able to define different patterns for chords, bass lines and drum tracks,
</LI>
<LI>Make the input files easy to create and debug,
</LI>
<LI>Provide a reusable library that a user could simply plug in, or modify.
</LI>
</UL>

<P>
From these simple needs <I><B>MMA</B></I> was created.

<P>
The basic building blocks of <I><B>MMA</B></I> are <I>Pattern</I>s. A pattern is a  specification which tells <I><B>MMA</B></I> what notes of a chord to play, the start point in a bar for the chord/notes, and the duration and the volume of the notes.

<P>
<I><B>MMA</B></I> patterns are combined into <I>Sequence</I>s. This lets you create multi-bar rhythms.

<P>
A collection of patterns can be saved and recalled as <I>Groove</I>s. This makes it easy to pre-define complex rhythms in library files and incorporate them into your song with a simple two word command.

<P>
<I><B>MMA</B></I> is bar or measure based (we use the words interchangeably in this document). This means that <I><B>MMA</B></I> processes your song one bar at a time. The music specification lines all assume that you are specifying a single bar of music. The number of beats per bar can be adjusted; however, all chord changes must fall on a beat division (the playing of the chord or drum note can occur anywhere in the bar).

<P>
To make the input files look more musical, <I><B>MMA</B></I> supports <I>Repeats</I> and <I>RepeatEnding</I>s. However, complexities like D.S. and Coda are not internally supported (but can be created by using the <I>Goto</I> command).

<P>

<H1><A NAME="SECTION00160000000000000000">
Case Sensitivity</A>
</H1>

<P>
Just about everything in a <I><B>MMA</B></I> file is case insensitive.

<P>
This means that the command:

<P>

	<TABLE CELLSPACING=0 CELLPADDING=5" BGCOLOR="OldLace" BORDER=3><TR> <TD>
<BLOCKQUOTE><B>Tempo 120 </B></BLOCKQUOTE>

	</TD></TR></TABLE> 

<P>
could be entered in your file as:

<P>

	<TABLE CELLSPACING=0 CELLPADDING=5" BGCOLOR="OldLace" BORDER=3><TR> <TD>
<BLOCKQUOTE><B>TEMPO 120 </B></BLOCKQUOTE>

	</TD></TR></TABLE> 

<P>
or even

<P>

	<TABLE CELLSPACING=0 CELLPADDING=5" BGCOLOR="OldLace" BORDER=3><TR> <TD>
<BLOCKQUOTE><B>TeMpO 120 </B></BLOCKQUOTE>

	</TD></TR></TABLE> 

<P>
for the exact same results.

<P>
Names for patterns, and grooves are also case insensitive.

<P>
The only exceptions are the names for chords, notes in <I>Solo</I>s, and filenames. In keeping with standard chord notation, chord names are in mixed case; this is detailed in Chapter <A HREF="node8.html#sec-music">8</A>. Filenames are covered in Chapter <A HREF="node20.html#sec-paths">20</A>.

<P>
<BR><HR><H4>Footnotes</H4>
<DL>
<DT><A NAME="foot193">...</A><A
 HREF="node1.html#tex2html2"><SUP>1.1</SUP></A></DT>
<DD>Musical MIDI Accompaniment and the short form <I><B>MMA</B></I> in the distinctive script are names for a program written by Bob van der Poel. The ``MIDI Manufacturers Association, Inc.'' uses the acronym MMA, but there is no association between the two.

</DD>
<DT><A NAME="foot194">... MIDI</A><A
 HREF="node1.html#tex2html3"><SUP>1.2</SUP></A></DT>
<DD>MIDI is an acronym for Musical Instrument Digital Interface.

</DD>
<DT><A NAME="foot244">... systems.</A><A
 HREF="node1.html#tex2html6"><SUP>1.3</SUP></A></DT>
<DD>If someone using a Mac system could let me know how to install on this system I'd be glad to include those details on my website.

</DD>
<DT><A NAME="foot275">... slashes).</A><A
 HREF="node1.html#tex2html7"><SUP>1.4</SUP></A></DT>
<DD>We wanted to use ``#'' for comments, but that sign is used for ``sharps'' in chord notation.

</DD>
</DL><HR>
<!--Navigation Panel-->
<A NAME="tex2html267"
  HREF="node2.html">
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next"
 SRC="file:/usr/lib/latex2html/icons/next.png"></A> 
<A NAME="tex2html265"
  HREF="mma.html">
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up"
 SRC="file:/usr/lib/latex2html/icons/up.png"></A> 
<A NAME="tex2html259"
  HREF="mma.html">
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous"
 SRC="file:/usr/lib/latex2html/icons/prev.png"></A>   
<BR>
<B> Next:</B> <A NAME="tex2html268"
  HREF="node2.html">Running MMA</A>
<B> Up:</B> <A NAME="tex2html266"
  HREF="mma.html">Reference Manaul</A>
<B> Previous:</B> <A NAME="tex2html260"
  HREF="mma.html">Reference Manaul</A>
<!--End of Navigation Panel-->
<ADDRESS>
Bob
2004-12-02
</ADDRESS>
</BODY>
</HTML>