02/02/2017
Super simple setup to count beats per minute in Xpresso with Python node. Counting starts immediately when time is running. You can easily modify code for your needs e.g. starting time.
import c4d def main(): global out # Output port: 'Out' bpm = 128 # Beats per minute spb = 60.0 / int(bpm) # Seconds per beat if time != 0: # If current frame is not first frame out = int(time/spb) # Hits count else: # Otherwise out = 0 # Hits count is 0