|
About Andrew Choi
MIDI Programs
MIDI File Player (External Device)
MIDI Destination Pop-Up Button
Other Programs Cocoa Sample Programs Syntax Coloring Using Flex Algorithms Jazz Chord Analysis as Optimization
|
A blog where I will write mostly about programming in Cocoa and CoreMIDI, and experiences from my ports of Emacs and XEmacs to the Mac OS.
I was thinking about how sysex input and output will fit into the ensemble/player model that I've been considering. I now think that perhaps they dont fit at all! A player is identified by name, MIDI device, channel, and program change. But a device for receiving and sending sysex messages is only identified by name and MIDI device. We also probably view these devices as capable of bidirectional transfers in, say, a library application. That's the whole interface! We may need to encapsulate the send and receive operation in objects as was done in SysExSenderX. Again, the CoreMIDI API makes it a little hard to identify such sysex devices. So I wrote this program to print out a lot of information about devices, entities, and source and destination endpoints. After looking at the output of this program, I've come up with the following design. Enumerate all devices (not external devices) in the system. For each device, enumerate all its entities. Consider listing as sysex devices those entities that have exactly one source endpoint and one destination endpoint. If the source and destination endpoints of an entity are both connected to the same external device, we list it as a sysex device using the name of the external device (e.g., DX-7 II). If the source and destination endpoints are not connected to external devices, we list it as a sysex device using the name of the device and entity (e.g., Opcode Studio 4, Port 3). The latter handles cases for which Audio MIDI Setup has not been run. In either case, the source and destination endpoints are remembered internally to implement the send and receive operations.
I've started to read the free book Dive Into Python: Python for experienced programmers today. It's looks like a nice book to skim through after finishing the official tutorial. Go here to look for other free computer books.
The MIDI Name Document format is the emerging standard for storing patch and note names of MIDI devices. At some point I'll need to learn it so I thought I might as well do this now. So I looked at this OMS to MIDI name document converter and CherryPicker. And I tried to write a program to parse their output. I read the documentation of Apple's XML parser and this article. The latter contains sample code that demonstrates the use of the parser. Unfortunately that code is more messy than necessary and doesn't print element information. I wrote this new version, which doesnt have these problems.
Read Apple's Documentation on Archives and Serializations today.
Here's a screen shot of a test program I've written today. It demonstrates the use of pop-up buttons in a table. It's not very hard to write. But you'll need to read about the difference between controls and cells. It's really quite clever how they use the lighter-weight cells instead of views in table columns and matrices.
|
Lists
Less-Known Facts About Emacs
Chinese Restaurants in Calgary
Calgary/Banff Tourist Attractions
Top-10 Reason I Stopped Working on Emacs
Misc
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Copyright © 2003, 2004, 2005 Andrew Choi (Contact Information). | Created with FCBlog |