[comp.sys.mac.programmer] MAC MIDI tools.

fjo@cbnewsc.ATT.COM (frank.j.owen) (08/12/89)

  After posting the previous article proclaiming that the MIDI tools
are availible via APDA, I have received mail saying that you cannot
in fact get them from APDA. They are claiming that it's still in 
development and that they don't yet have the masters.

  I really got the impression from the Apple guy I talked with that
they were availible, so maybe APDA just haven't geared up. In any event,
I think that if they're not availible right now, they will be very
shortly.

  I hope I haven't inconvenienced too many people. 

-- 
Frank Owen (fjo@ttrdf)  312-982-2182
AT&T Bell Laboratories 
5555 Touhy Ave., Skokie, IL  60077
PATH:  ...!att!ttrdf!fjo

dudek@ai.toronto.edu (Gregory Dudek) (08/15/89)

  In lieu of actually getting the MIDI tools, I wonder if somebody
with the information might want to give us some idea
to what the details of using the package are like, for a programmers
point of view.  In particular, what kind of calls do you
make to do the MIDI I/O?  Is it easy to convert an existing MIDI
application that uses a raw SCC interface to the new package?

  Thanks, Greg Dudek
-- 
Dept. of Computer Science (vision group)    University of Toronto
Nice mailers:  dudek@ai.utoronto.ca
UUCP: {uunet,decvax,linus,pyramid,
		dalcs,watmath,garfield,ubc-vision,calgary}!utai!dudek
ARPA: user%ai.toronto.edu@relay.cs.net

fjo@cbnewsc.ATT.COM (frank.j.owen) (08/16/89)

From article <2384@cbnewsc.ATT.COM>, by fjo@cbnewsc.ATT.COM (frank.j.owen):
> 
>   After posting the previous article proclaiming that the MIDI tools
> are availible via APDA, I have received mail saying that you cannot
> in fact get them from APDA. 

  Well, I just called APDA and they said "it IS availible and
IS SHIPPING"!!
  So, you can get it.


  Now, are there any APDA members out there who'd be willing
to buy a copy for/with me?



-- 
Frank Owen (fjo@ttrdf)  312-982-2182
AT&T Bell Laboratories 
5555 Touhy Ave., Skokie, IL  60077
PATH:  ...!att!ttrdf!fjo

david.dmytryshyn@f428.n250.z1.fidonet.org (david dmytryshyn) (08/17/89)

 >   Now, are there any APDA members out there who'd be willing
 > to buy a copy for/with me?


This brings a question.  Why do I have to pay APDA so that I  can pay to buy 
things from them.  For instance, all I want to buy is the commtoolbox and the 
MIDImanager stuff.  I bought Lightspeed at the University Computer Shop, and 
get most other things at cost from a guy I know who runs a Computer Store. Now 
if I go into my University Computer shop and say, I want the commtoolbox and 
MIDImanager by Apple, I think I'll get a blank stare.  (I got enough of a 
blank stare when I asked for Lightspeed C, which seems to have undergone too 
many name changes, so I'll refer to it as that C compiler which isn't MPW)


If I join that other Mac Programming Association can I buy the MIDImanager and 
commtoolbox?  What is the name of that other one anyways, TechAlliance?


Am I going to get anything else besides the priviledge of buying from APDA by
joining APDA?  The magazine they put out sounds like a bunch of promotional 
drivel, which I get enough of as it is.


David..

---
 * Origin: Future Vision:  Progressive & Innovative (1:250/428)

cbm@well.UUCP (Chris Muir) (08/17/89)

In message <89Aug14.190143edt.10865@ephemeral.ai.toronto.edu>
dudek@ai.toronto.edu (Gregory Dudek) writes:

>  In lieu of actually getting the MIDI tools, I wonder if somebody
>with the information might want to give us some idea
>to what the details of using the package are like, for a programmers
>point of view.  In particular, what kind of calls do you
>make to do the MIDI I/O?  Is it easy to convert an existing MIDI
>application that uses a raw SCC interface to the new package?

I've just converted an application that was using the MacTutor (Kirk
Austin) MIDI drivers to run under the MidiManager. The hardest part
for me was that the MidiManager really wants to run at interrupt time,
and all my code assumed that I was going to be polling the driver from
my main event loop. This means that I had to play games to find my
globals and that I couldn't move memory, etc. This is all standard
driver/interrupt stuff, but I had never done it before. Basically the
calls to the MidiManager are pretty simple. A call to Initialize, a
call to "SignIn" your application, calls to add and subtract virtual
ports, calls to find out about other applications ports and connect
and connect to them, a call to write a packet, etc.

Data comes and goes in MIDIPackets:
  MIDIPacket = packed record
    flags: BYTE;      { what type of packet }
    len: BYTE;        { length of packet including 6 byte header }
    tStamp: LONGINT;  { in local time }
    data: packed array[0..250] of BYTE;
  end;
  MIDIPacketPtr = ^MIDIPacket;

When you add an input port you pass the address of a "readHook", which
is called at interrupt level when midi packets arrive. The MidiManager
only reports completed packets. It also "completes" any packets sent
with running status. 

You may write data to output ports at interrupt time or from the main
event loop.

The MidiManager comes with source for a few simple applications, some
in Pascal, some in C.

I'd be glad to answer any questions, if I can.


-- 
_______________________________________________________________________________
Chris Muir                             |   "There is no language in our lungs
{hplabs,pacbell,ucbvax,apple}          |    to tell the world just how we feel" 
!well!cbm                              |                         - A. Partridge

mnkonar@gorby.SRC.Honeywell.COM (Murat N. Konar) (08/17/89)

In article <2439@cbnewsc.ATT.COM> fjo@cbnewsc.ATT.COM (frank.j.owen) writes:
>  Well, I just called APDA and they said "it IS availible and
>IS SHIPPING"!!
>  So, you can get it.

I can confirm this fact.  I just placed my order.  Cost is $30.

I just hope it gets here before Christmas.



____________________________________________________________________
Have a day. :^|
Murat N. Konar        Honeywell Systems & Research Center, Camden, MN
mnkonar@SRC.honeywell.com (internet) {umn-cs,ems,bthpyd}!srcsip!mnkonar(UUCP)

mnkonar@manyjars.SRC.Honeywell.COM (Murat N. Konar) (08/18/89)

Queston:

Can I run MOTUs Performer 3.0 under Multifinder concurrently
with an application that uses the MIDI manager routines without
a) crashing
b) causing really bizzarre music?

Does Performer 3.0 use the MIDI manager if present?

Thanks!

____________________________________________________________________
Have a day. :^|
Murat N. Konar        Honeywell Systems & Research Center, Camden, MN
mnkonar@SRC.honeywell.com (internet) {umn-cs,ems,bthpyd}!srcsip!mnkonar(UUCP)