MIDI messages decoder.
More...
#include <stdbool.h>
#include <unistd.h>
Go to the source code of this file.
|
typedef enum midi_cmd | midi_cmd |
|
typedef enum midi_sys_cmd | midi_sys_cmd |
|
typedef struct midi_decoder | midi_decoder |
|
|
enum | midi_cmd {
Note_Off = 0x8
, Note_On = 0x9
, Aftertouch = 0xA
, Continous_Controller = 0xB
,
Patch_Change = 0xC
, Channel_Pressure = 0xD
, Pitch_Bend = 0xE
, Sys = 0xF
} |
|
enum | midi_sys_cmd {
Exclusive = 0x0
, Song_Position = 0x2
, Song_Select = 0x3
, Bus_Select = 0x5
,
Tune_Request = 0x6
, End_Exclusive = 0x7
, Timming_Tick = 0x8
, Start_Song = 0xA
,
Continue_Song = 0xB
, Stop_Song = 0xC
, Active_Sensing = 0xE
, Reset = 0xF
} |
|
◆ midi_decoder_init()
Init/reset a MIDI decoder.
- Parameters
-
◆ midi_decoder_push()
uint32_t midi_decoder_push |
( |
midi_decoder * |
dec, |
|
|
uint8_t |
byte |
|
) |
| |
Process and incoming byte of MIDI input.
- Parameters
-
dec | MIDI decoder instance |
byte | incoming byte of MIDI input |
- Returns
- decoded midi message or 0 for no message