I'm not sure whether MIDI tempo information messages makes it through to the Faust node, but the tempo sync node is definitely the way to go. just build your Faust node with a absolute delay time parameter and then connect it to the tempo sync node - it automatically sends the correct time value matching the tempo and reacts to tempo changes etc.
upcoming docs:
Tempo Sync (control.tempo_sync)
Converts a musical tempo value to a duration in milliseconds and sends it as a modulation signal.
Tempo Sync converts a musical time value (such as 1/4 note or 1/8 triplet) to a duration in milliseconds based on the current DAW tempo. The output updates whenever the host tempo changes or any parameter is adjusted, making it suitable for driving time-based effects that need to lock to the beat.
The output is an unnormalised modulation signal carrying the raw millisecond value. If the target parameter expects a different unit (such as frequency in Hz), place a control.converter between this node and the target. When Enabled is set to Off, the node outputs the manual UnsyncedTime value instead, allowing a smooth fallback for standalone operation or manual control.
CPU: negligible, polyphonic.
Signal Path
Pseudo-code - hover highlighted terms for details
// control.tempo_sync - musical time to milliseconds
// BPM + parameters -> ms out (unnormalised)
onParameterChange() {
if Enabled:
output = tempoToMs(bpm, Tempo) * Multiplier
else:
output = UnsyncedTime
}
onTempoChange(newBpm) {
bpm = newBpm
if Enabled:
output = tempoToMs(bpm, Tempo) * Multiplier
}