Arduino MIDI Library Version 3.2
Classes | Defines | Typedefs | Enumerations | Variables
/Users/franky/Documents/Dropbox/SVN/embedded/toolbox/libraries/MIDILib/trunk/Arduino/MIDI/MIDI.h File Reference

MIDI Library for the Arduino Version 3.2. More...

#include <inttypes.h>

Go to the source code of this file.

Classes

struct  midimsg
class  MIDI_Class
 The main class for MIDI handling.
See member descriptions to know how to use it, or check out the examples supplied with the library. More...

Defines

#define COMPILE_MIDI_IN   1
#define COMPILE_MIDI_OUT   1
#define COMPILE_MIDI_THRU   1
#define USE_SERIAL_PORT   Serial
#define USE_RUNNING_STATUS   1
#define USE_CALLBACKS   1
#define USE_1BYTE_PARSING   1
#define MIDI_BAUDRATE   31250
#define MIDI_CHANNEL_OMNI   0
#define MIDI_CHANNEL_OFF   17
#define MIDI_SYSEX_ARRAY_SIZE   255

Typedefs

typedef uint8_t byte
typedef uint16_t word

Enumerations

enum  kMIDIType {
  NoteOff = 0x80, NoteOn = 0x90, AfterTouchPoly = 0xA0, ControlChange = 0xB0,
  ProgramChange = 0xC0, AfterTouchChannel = 0xD0, PitchBend = 0xE0, SystemExclusive = 0xF0,
  TimeCodeQuarterFrame = 0xF1, SongPosition = 0xF2, SongSelect = 0xF3, TuneRequest = 0xF6,
  Clock = 0xF8, Start = 0xFA, Continue = 0xFB, Stop = 0xFC,
  ActiveSensing = 0xFE, SystemReset = 0xFF, InvalidType = 0x00
}
enum  kThruFilterMode { Off = 0, Full = 1, SameChannel = 2, DifferentChannel = 3 }

Variables

MIDI_Class MIDI
 Main instance (the class comes pre-instantiated).

Detailed Description

MIDI Library for the Arduino Version 3.2.

Project MIDI Library

Author:
Francois Best
Date:
24/02/11 License GPL Forty Seven Effects - 2011

Definition in file MIDI.h.


Define Documentation

#define COMPILE_MIDI_IN   1

Definition at line 31 of file MIDI.h.

#define COMPILE_MIDI_OUT   1

Definition at line 32 of file MIDI.h.

#define COMPILE_MIDI_THRU   1

Definition at line 33 of file MIDI.h.

#define MIDI_BAUDRATE   31250

Definition at line 56 of file MIDI.h.

#define MIDI_CHANNEL_OFF   17

Definition at line 59 of file MIDI.h.

#define MIDI_CHANNEL_OMNI   0

Definition at line 58 of file MIDI.h.

#define MIDI_SYSEX_ARRAY_SIZE   255

Definition at line 61 of file MIDI.h.

#define USE_1BYTE_PARSING   1

Definition at line 49 of file MIDI.h.

#define USE_CALLBACKS   1

Definition at line 46 of file MIDI.h.

#define USE_RUNNING_STATUS   1

Definition at line 41 of file MIDI.h.

#define USE_SERIAL_PORT   Serial

Definition at line 37 of file MIDI.h.


Typedef Documentation

typedef uint8_t byte

Type definition for practical use (because "unsigned char" is a bit long to write.. )

Definition at line 64 of file MIDI.h.

typedef uint16_t word

Definition at line 65 of file MIDI.h.


Enumeration Type Documentation

enum kMIDIType

Enumeration of MIDI types

Enumerator:
NoteOff 

Note Off.

NoteOn 

Note On.

AfterTouchPoly 

Polyphonic AfterTouch.

ControlChange 

Control Change / Channel Mode.

ProgramChange 

Program Change.

AfterTouchChannel 

Channel (monophonic) AfterTouch.

PitchBend 

Pitch Bend.

SystemExclusive 

System Exclusive.

TimeCodeQuarterFrame 

System Common - MIDI Time Code Quarter Frame.

SongPosition 

System Common - Song Position Pointer.

SongSelect 

System Common - Song Select.

TuneRequest 

System Common - Tune Request.

Clock 

System Real Time - Timing Clock.

Start 

System Real Time - Start.

Continue 

System Real Time - Continue.

Stop 

System Real Time - Stop.

ActiveSensing 

System Real Time - Active Sensing.

SystemReset 

System Real Time - System Reset.

InvalidType 

For notifying errors.

Definition at line 68 of file MIDI.h.

               {
    NoteOff               = 0x80,   
    NoteOn                = 0x90,   
    AfterTouchPoly        = 0xA0,   
    ControlChange         = 0xB0,   
    ProgramChange         = 0xC0,   
    AfterTouchChannel     = 0xD0,   
    PitchBend             = 0xE0,   
    SystemExclusive       = 0xF0,   
    TimeCodeQuarterFrame  = 0xF1,   
    SongPosition          = 0xF2,   
    SongSelect            = 0xF3,   
    TuneRequest           = 0xF6,   
    Clock                 = 0xF8,   
    Start                 = 0xFA,   
    Continue              = 0xFB,   
    Stop                  = 0xFC,   
    ActiveSensing         = 0xFE,   
    SystemReset           = 0xFF,   
    InvalidType           = 0x00    
};

Enumeration of Thru filter modes

Enumerator:
Off 

Thru disabled (nothing passes through).

Full 

Fully enabled Thru (every incoming message is sent back).

SameChannel 

Only the messages on the Input Channel will be sent back.

DifferentChannel 

All the messages but the ones on the Input Channel will be sent back.

Definition at line 91 of file MIDI.h.

                     {
    Off                   = 0,  
    Full                  = 1,  
    SameChannel           = 2,  
    DifferentChannel      = 3   
};

Variable Documentation

Main instance (the class comes pre-instantiated).

Definition at line 18 of file MIDI.cpp.