OVERVIEW Tclmidi is language designed for creating and editing standard MIDI files. With the proper device interface it will also play and record MIDI files. Since tclmidi is a language supporting function calls, recursion and conditionals, you can use these features for editing, sequencing and writing complex scripts. The brave might even want to try their hand at algorithmic composition. The basis of tclmidi is John Ousterhout's popular TCL language. tclmidi adds a few new commands specific to manipulating MIDI files, and playing/recording them. You'll need to have TCL-7.X or later installed on your system to build tclmidi. I've tried to be POSIX complient while writing tclmidi. It has been built on numerous machines and should compile on any Unix like machine with a C++ compiler. It has also been ported to Windows (though not recently tested). MPU401 comes with a device driver to interface with MPU401 compatible MIDI cards. It will also support external SMPTE timing if you have one of the Music Quest cards with SMPTE support. 90% of the driver is portable, and only the remaining 10% must be written for a specific UNIX varient. This distribution comes with support for BSD/OS, Linux, NetBSD and Unixware*. These three cover a wide range of systems and one should make a good basis for a port to a new system. * The Unixware driver is still a bit buggy. TCLMIDI-2.2.1 - TCLMIDI-2.2.2 CHANGES A few bug fixes in the tclmidi code and some new features in the supplied driver. The driver now has a "raw" access device. This device bypasses the queue and timing features of the driver. Events written to this device will be sent out as soon as possible. Both the normal timed device and the raw device can be used at the same time. The events written to the raw device are parsed to avoid any running status conflicts. TCL-7.4 is now assumed as the default. TCLMIDI-2.1 - TCLMIDI-2.2 CHANGES A few bug fixes and an updated, unified driver. One driver will now work for different UNIX like OSes. Only small .h and .c files need to be created for each different system type. Support files are provided for BSD/OS 2.0, Linux 1.2 and UnixWare. TCLMIDI-2.0 - TCLMIDI-2.1 CHANGES tclmidi-2.1 is mostly a bug fix and platform update release. Most of the Unixes that are supported by the MPU401 driver have changed since 2.0. The driver found in 2.1 has been updated to work with the newer releases. The MPU401 driver now works as a loadable module under Linux. All long file names have been changed to fit DOS restrictions, and modifications have been made so tclmidi will build under Windows (given a VC++ compiler and twin tk port). The driver now also has SMPTE support for those Music Quest board that have a SMPTE interface. The driver timing is now more accurate that in 2.0. There is also a new command, miditime that reports the current time in the driver. TCLM-1.0 - TCLMIDI-2.0 CHANGES tclmidi-2.0 is completely incompatible with tclm-1.0, though it does contain some similarities. The biggest change is that tclmidi-2.0 uses a red-black tree of MIDI events as its underlying data structure. This means events can be inserted and accessed at any time/position in a song. In tclm-1.0 events could only be appended to a track and could only be accessed sequentially. I believe that this change will make sequencing with tclmidi-2.0 feasible (in fact I plan on writing an X based song editor using tclmidi, sometime in the future). The second big change is the implementation language. tclm-1.0 was written in C. tclmidi-2.0 is written in C++. MIDI events were just screaming "object" at me and so I obliged them. Though C++ isn't as prevelent as C, I feel this shouldn't pose much of a problem since there exits a fine, freely availble C++ compiler (g++). The last big change is the inclusion of an MPU401 device driver. My development platform is a BSD/OS system with a Music Quest PC MIDI card. My previous drivers have used the MPU401 in smart mode, the new driver uses it UART mode so as to be more compatible with different MPU401 type cards (and for other reasons. See doc/trials.me). The driver is now almost 90% generic code that will run on any UNIX like system. Only small .h and .c files need to be created for each different system. Other changes involve syntax of the tclmidi commands. These have changed since 1.0 and are a bit more flexible I think. Please see the man pages to familiarize yourself with the new syntax. REQUIREMENTS You need tcl-7.X installed. You don't need the source though, (as opposed to tclm-1.0) as all the information tclmidi needs can be found in the installed header files and libtcl.a. You also need a C++ compiler. G++ is free and works. COMPILATION NOTES Take a look at the Makefile and edit the stuff at the top. Then just "make" and "make install". You might also want to "make tkmidi" and "make install-tkmidi". To install the man pages choose one of "make install-man-cooked" or "make install-man-raw". The cooked formats the man pages before installing them, raw does not. WINDOWS SUPPORT Stephen Yost took tclmidi and ported it to Windows, I've incorporated these changes into the primary source tree. I don't run windows and haven't be able to verify how well it works. See the README.Win file for more details. MISSING THINGS Scripts. I've included four, mplay, mrec, minfo and midtocl. If you write some good ones, send them to me and I'll include them. Lucho Georgiev has written a few, which can be found in the contrib directory. I'm hoping others will contribute too. Xdrum support. Xdrum won't work with this version of tclmidi. I'll eventually redo xdrum to work with tclmidi, but it might be a while. I also want to write a X based score editor based on this stuff. That will probably take *quite* a while. MAILING LIST I've set up a mailing list for tclmidi discussion. To subscribe, send mail to majordomo@advtech.uswest.com and include the phrase "subscribe tclmidi" in the body of the message. The subject line is ignored, so don't put the phrase there. To send mail to the list, email tclmidi@advtech.uswest.com. SPECIAL THANKS Thanks goes to all those who have helped me get this thing working. Extra special thanks goes to the following for putting up with a lot of system crashes and debugging to make the driver ports usable. Thank them for getting the driver to work. Blame me for any bugs you find. Ralf Jaegar - Linux Andreas Gustafsson - NetBSD Luchezar Georgiev - Linux Stephen Yost - Windows Greg Wolodkin - SMPTE, Linux Alberto Vignani - Linux Allaoua Bouabdallah - UnixWare And of course I'd like to thank everyone who has been using tclmidi, finding bugs and helping me test. mike durian@boogie.com