diff options
| author | miunau <55932282+miunau@users.noreply.github.com> | 2024-02-28 16:35:48 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-02-28 16:35:48 +0100 |
| commit | ccf0e8645a4a6f45b6b10319bc11d2a94d63d04c (patch) | |
| tree | 168db8dbab401b3a89e4871fa390875411d120c7 | |
| parent | ad5acab71aa91d93d6d0949f8fe9cdf654a22ce7 (diff) | |
| parent | 2a8cf137bd7370b2bcb433302702c12945cd2fc8 (diff) | |
| download | plinky-ccf0e8645a4a6f45b6b10319bc11d2a94d63d04c.tar.gz | |
Merge pull request #9 from plinkysynth/ap-latch-midi-fix-2
Arp/Latch MIDI fix 2
| -rwxr-xr-x | sw/.DS_Store | bin | 10244 -> 0 bytes | |||
| -rwxr-xr-x | sw/Core/Src/plinky.c | 20 |
2 files changed, 19 insertions, 1 deletions
diff --git a/sw/.DS_Store b/sw/.DS_Store Binary files differdeleted file mode 100755 index ca298f8..0000000 --- a/sw/.DS_Store +++ /dev/null diff --git a/sw/Core/Src/plinky.c b/sw/Core/Src/plinky.c index 013ee1a..5cac122 100755 --- a/sw/Core/Src/plinky.c +++ b/sw/Core/Src/plinky.c @@ -1495,7 +1495,7 @@ const s8 midicctable[128] = { /* 72 */ P_R, P_A, P_S, P_D, P_XFREQ, P_XDEPTH, P_XOFFSET, P_YFREQ, /* 80 */ P_YDEPTH, P_YOFFSET, P_SAMPLE, P_SEQPAT, -1, P_SEQSTEP, -1, -1, /* 88 */ -1, P_MIXINPUT, P_MIXINWETDRY,P_RVSEND, P_RVTIME, P_RVSHIM, P_DLSEND, P_DLFB, - /* 96 */ -1, -1, -1, -1, -1, -1, P_ARPONOFF, P_ARPMODE, + /* 96 */ -1, -1, -1, -1, -1, P_LATCHONOFF, P_ARPONOFF, P_ARPMODE, /* 104 */ P_ARPDIV, P_ARPPROB, P_ARPLEN, P_ARPOCT, P_SEQMODE, P_SEQDIV, P_SEQPROB, P_SEQLEN, /* 112 */ P_DLRATIO, P_DLWOB, P_RVWOB, -1, P_JIT_POS, P_JIT_GRAINSIZE, P_JIT_RATE, P_JIT_PULSE, /* 120 */ -1, -1, -1, -1, -1, -1, -1, -1, @@ -1599,6 +1599,24 @@ void processmidimsg(u8 msg, u8 d1, u8 d2) { if (param_flags[param] & FLAG_SIGNED) val = val * 2 - FULL; EditParamNoQuant(param, M_BASE, val); + + if (param == P_ARPONOFF){ + if (val > 64){ + rampreset.flags = rampreset.flags | FLAGS_ARP; + }else{ + rampreset.flags = rampreset.flags & ~FLAGS_ARP; + } + ShowMessage(F_32_BOLD, ((rampreset.flags & FLAGS_ARP)) ? "arp on" : "arp off", 0); + } + if (param == P_LATCHONOFF){ + if (val > 64){ + rampreset.flags = rampreset.flags | FLAGS_LATCH; + }else{ + rampreset.flags = rampreset.flags & ~FLAGS_LATCH; + } + ShowMessage(F_32_BOLD, ((rampreset.flags & FLAGS_LATCH)) ? "latch on" : "latch off", 0); + } + } break; } |
