⏳ bpm
bpm
The bpm module provides a way to set the tempo of the current session. The tempo is a global setting that affects all loops and samples, it is measured in beats per minute (BPM) and can be adjusted in real-time.
Cookbook
Set the tempo
Get the current tempo
Get the current beat
Reference
beat()
Get the current beat.
Returns:
Type | Description |
---|---|
float
|
The current beat. |
get()
Get the BPM. This function can only be called from the global scope.
Returns:
Type | Description |
---|---|
float
|
The current BPM. |
Raises:
Type | Description |
---|---|
InLoopException
|
If called from inside a loop. |
set(bpm)
Set the BPM. This function can only be called from the global scope.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
bpm |
float
|
The new BPM. |
required |
Returns:
Type | Description |
---|---|
float
|
The new BPM. |
Raises:
Type | Description |
---|---|
InLoopException
|
If called from inside a loop. |