Hi - I just started with the patch.Init(). I’m trying to do something obvious but that doesn’t work: print the current value of a knob. Here’s what I’m using:
#include <daisy_patch.h>
using namespace daisy;
DaisyPatch dp;
void InitHardware(bool debug) {
dp.Init();
dp.seed.StartLog(debug);
}
int main(void)
{
InitHardware(true);
int i = 0;
for(;;) {
dp.ProcessAnalogControls();
int v = dp.controls[0].GetRawValue();
dp.seed.PrintLine("Value %d", v);
dp.seed.PrintLine("Cycle: %d", i++);
System::Delay(10);
}
}
I’ve been also using GetKnobValue(CTRL_1)
, removing ProcessAnalogControls()
as I’m going through trial and errors but I’m not getting any value as I’m turning the knob:
Cycle: 1343
Value 0
Cycle: 1344
Value 0
Cycle: 1345
Value 0
I must be missing something obvious - before I spend more time digging, has anyone any idea? Thanks!