melody

xod-proj/bz/melody

No description
melody
@/melody
SETpulse
FREQ1number (variadic)
DURA1number (variadic)
melody
SET
FREQ1
DURA1
DONE
DONEpulse
To use the node in your project you should have the xod-proj/bz library installed. Use the “File → Add Library” menu item in XOD IDE if you don’t have it yet. See Using libraries for more info.

C++ implementation

struct State {
};

{{ GENERATED_CODE }}

void evaluate(Context ctx) {
    if (!isInputDirty<input_SET>(ctx)) return;
    auto freq1 = getValue<input_FREQ1>(ctx);
    auto dura1 = getValue<input_DURA1>(ctx);
    tone(A0, freq1,dura1);
    emitValue<output_DONE>(ctx, true);
}