Module metro

high-resolution metro API

The norns script reference has examples for this module.

Functions

init (arg, arg_time, arg_count) initialize a metro.
free (id) free
free_all () free all
new (id) constructor.
start ([time[, count[, stage]]]) start a metro.
stop () stop a metro.


Functions

init (arg, arg_time, arg_count)
initialize a metro. assigns unused id.

Parameters:

  • arg function callback function
  • arg_time number time period between ticks (seconds).
  • arg_count number number of ticks. infinite by default.
free (id)
free

Parameters:

  • id number
free_all ()
free all
new (id)
constructor.

Parameters:

  • id integer : identifier

Returns:

    Metro
start ([time[, count[, stage]]])
start a metro.

Parameters:

  • time number
    • time period between ticks (seconds.) by default, re-use the last period
    (optional)
  • count number
    • number of ticks. infinite by default
    (optional)
  • stage number
    • initial stage number (1-based.) 1 by default
    (optional)
stop ()
stop a metro.
generated by LDoc 1.5.0 Last updated 2024-10-13 17:45:04