Class fx_pot¶
Defined in File dreammakerfx.h
Class Documentation¶
-
class
fx_pot
¶ These functions are used to read the pots (aka the knobs) of the pedal.
Each knob has a value ranging from 0.0 (full counter-clockwise) to 1.0 (full clock-wise).
The first generation hardware has three pots (
pedal.pot_left
,pedal.pot_center
, andpedal.pot_right
).The second generation hardware has five pots (
pedal.pot_top_left
, ‘pedal.pot_top_right’, ‘pedal.pot_bot_left<tt>,pedal.pot_bot_center<tt>andpedal.pot_bot_right`). To preserve backwards compatibility with sketches developed on the first generation hardware, thepedal.pot_left
will map to ‘pedal.pot_bot_left` (and same for center and right pots).Use the
.has_changed()
function to determine when a pot has been adjusted by the user.void loop() { if (pedal.pot_left.has_changed()) { delay_effect.set_feedback(pedal.pot_left.val); // Set feedback of delay using left pot } // Other code in loop()...