score.beats

Functions for working with beat patterns and sets.

hex->pat

(hex->pat hex-str)
Converts a hexadecimal string into a beat sequence of 1's and 0's. Each hex digit within the string generates 4 beats of values.  0 = 0000, 1 = 0001, 2 = 0010, ... f = 1111.

hex->set

(hex->set hex-str)
Converts a hexadecimal string into a beat set.

hex->str

(hex->str hex-str)
Converts a hexadecimal string to binary string representation.

hexchar->str

(hexchar->str c)
Converts a hexadecimal char to 4-char binary string representation.

pat->set

(pat->set pat)
Converts a sequence of 1's and 0's into a beat set whose
members includes the indices in the sequence where 1's are
found. The set may then be used as a function to test
whether a beat number should trigger an action or not.

str->pat

(str->pat beat-str)
Converts beat string of 1's and 0's to sequence of 1's and 0's.

str->set

(str->set beat-str)
Converts beat string into beat set.