Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Might fix T4 pots in Grids #66

Merged
merged 1 commit into from
Mar 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion OMX-27-firmware/OMX-27-firmware.ino
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// OMX-27 MIDI KEYBOARD / SEQUENCER

// v1.13.4
// v1.13.5
// Last update: Feb 2024
//
// Original concept and initial code by Steven Noreyko
4 changes: 2 additions & 2 deletions OMX-27-firmware/src/config.h
Original file line number Diff line number Diff line change
@@ -15,10 +15,10 @@
// #include <cstdarg>

/* * firmware metadata */
// OMX_VERSION = 1.13.4
// OMX_VERSION = 1.13.5
const int MAJOR_VERSION = 1;
const int MINOR_VERSION = 13;
const int POINT_VERSION = 4;
const int POINT_VERSION = 5;

// 1.13.2 - Adds CV Trigger modes for legato and regtrig
// 1.13.3 - Bugfix for CV Trigger modes
18 changes: 18 additions & 0 deletions OMX-27-firmware/src/modes/omx_mode_grids.cpp
Original file line number Diff line number Diff line change
@@ -5,6 +5,7 @@
#include "../hardware/omx_leds.h"
// #include "../modes/sequencer.h"
#include "../midi/noteoffs.h"
#include "../consts/consts.h"

using namespace grids;

@@ -90,6 +91,22 @@ void OmxModeGrids::onPotChanged(int potIndex, int prevValue, int newValue, int a
// if (analogDelta < 3)
// return;

#if T4
// prevents values from being modified until pot is modified
if (potPostLoadThresh[potIndex])
{
int delta = newValue - prevValue;

if (delta >= 1)
{
potPostLoadThresh[potIndex] = false;
}
else
{
return;
}
}
#else
// prevents values from being modified until pot is modified
if (potPostLoadThresh[potIndex])
{
@@ -102,6 +119,7 @@ void OmxModeGrids::onPotChanged(int potIndex, int prevValue, int newValue, int a
potPostLoadThresh[potIndex] = false;
}
}
#endif

if (potIndex < 4)
{