The MIDI Keyboard Node listens to an external MIDI keyboard, or a virtual keyboard, and outputs a live melody with notes generated from each keypress. This Node can also be used with a standard computer keyboard (see the Virtual Keyboard section of this documentation).
You can connect to a synthesizer Node (such as the Oscillator Node) to produce audio, connect to a Piano Roll Node to record, or connect to a MIDI Monitor Node to display the currently pressed note(s).
Settings
Device
The MIDI device to use.
Set to Virtual to use your computer keyboard. See Virtual Keyboard for more info on this.
The MIDI Keyboard Node remembers your setting, even if you disconnect your device in the meantime. The next time you reconnect it, the Node will automatically start listening to events.
Buffer duration
Adds a buffering delay to notes, in milliseconds, to smooth and eliminate potential rhythmic inaccuracies. Increase this value if you hear the sound falling apart, or if you hear missed sounds. Decrease if you need lower latency.
With 0 buffering, connected Nodes process MIDI events immediately. This means that, if a single MIDI Keyboard Node controls multiple Nodes (e.g. 3 Oscillator Nodes), the sounds produced by those Nodes may not be in perfect sync. This is because one of them might already be producing its output while another is starting, even if the difference is just a few microseconds.
These differences are usually extremely small, and a buffer duration of a few milliseconds is usually enough, even with complex synth setups.
Outputs
Melody
The live melody data.
To turn this data into sound, connect it to a synth Node, such as the Oscillator Node.
To apply changes to the melody data before turning it to sound, connect through any of the melody processor Nodes.
Virtual keyboard
If no external MIDI hardware is available, a standard computer keyboard can be used instead. This has a fixed layout resembling that of a MIDI keyboard:
Keyboard key | Pitch interpretation |
A | C |
---|---|
W | C# |
S | D |
E | D# |
D | E |
F | F |
T | F# |
G | G |
Y (Z on qwertz) | G# |
H | A |
U | A# |
J | B |
K | C (one octave up) |
Additionally, the following command keys are supported by the virtual keyboard:
Keyboard key | Command |
X | Octave up |
---|---|
Z (Y on qwertz) | Octave down |
V | Increase keypress velocity by 0.1 |
C | Decrease keypress velocity by 0.1 |
Recording
To record keyboard play, a Piano Roll Node can be used. See its documentation for more information.
Technical details
Many MIDI keyboards use the same MIDI message for key-press and key-release. AudioNodes keeps track of which keys are pressed and releases them accordingly, effectively implementing a “key-toggle” system.
Occasionally, it may happen (often due to a non-fatal hardware fault) that a corresponding key-release message fails to reach AudioNodes and a note gets “stuck”. When this happens, the Unstuck button can be used to release all keys (make sure all keys are released before using it, for correct results).
Remarks
Additional controls
MIDI Keyboards often have a “Pitch Bend” and a “Modulate” control (using MIDI channels 224 and 176, respectively). The values from these controls are not exposed in this Node, as the exact controls available vary from keyboard to keyboard. To access these controls, use a MIDI Input Node.