Push button value range

Hi, does anyone have any information on the range of values for the buttonChanged(PatchButtonId bid, uint16_t value, uint16_t samples) function?

I can’t find any documentation on it, the emulator doesn’t have that button on it, and I can’t debug the hardware because I don’t have the stuff to attach to the debugging pins.

Hi @eugarps,

Here’s what firmware does:

  pv->buttonChangedCallback(bid, getButtonValue(bid)?4095:0, timestamps[bid]);

And it can also get called by MIDI:

  getProgramVector()->buttonChangedCallback(MIDI_NOTE_BUTTON+note, velocity<<5, getSampleCounter());

Which means that value would be 0 or 4095 (0xfff) with hardware buttons and 0 - 4096 with MIDI depending on velocity (last 5 bits would be 0).

Speaking of debugging, you probably can get away with $5 or so for St-link clone and soldering a few pins. So maybe you should consider it.

2 Likes

Perfect, thanks so much!