Constructor
new MIDIOut(options)
Parameters:
Name | Type | Description |
---|---|---|
options |
TODO |
- Source:
Methods
allNotesOff()
Turn off all notes. Can fix "stuck" notes. Called automatically when Node.js exits.
- Source:
close() → {boolean}
Close the MIDI input port
- Source:
Returns:
true if the port was closed
- Type
- boolean
note(pitch, velocity, duration, channel)
Send a note on, followed by a note off after the given duration in milliseconds
Parameters:
Name | Type | Default | Description |
---|---|---|---|
pitch |
|||
velocity |
70 | ||
duration |
|||
channel |
1 |
- Source:
noteOff(pitch, velocity, channel)
Send a note off message
Parameters:
Name | Type | Default | Description |
---|---|---|---|
pitch |
|||
velocity |
70 | ||
channel |
1 |
- Source:
noteOn(pitch, velocity, channel)
Send a note on message
Parameters:
Name | Type | Default | Description |
---|---|---|---|
pitch |
|||
velocity |
70 | ||
channel |
1 |
- Source:
open(selector) → {boolean}
Open a MIDI input port
Parameters:
Name | Type | Default | Description |
---|---|---|---|
selector |
0 | TODO |
- Source:
Returns:
true if the port was opened
- Type
- boolean
play(songOrJSON) → {Scheduler}
Play a Song or MIDI JSON
Parameters:
Name | Type | Description |
---|---|---|
songOrJSON |
Song | object | a Song or MIDI JSON |
- Source:
Returns:
A Scheduler that has already been started. It's returned so you can stop it early if desired.
- Type
- Scheduler
ports()
List available MIDI input ports
- Source:
send(…bytes)
Send a raw byte list
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
bytes |
Iterable |
<repeatable> |
- Source: