Rev 6 #1

Merged
oleksiy merged 37 commits from hardware-rev-4 into main 2024-08-25 12:37:13 +00:00
79 changed files with 20704 additions and 7914 deletions
Showing only changes of commit 02a8f6fdce - Show all commits

View File

@ -89,9 +89,11 @@ void checkInputs() {
if (encPositionOld != encPosition) {
int change = encPositionOld - encPosition;
unsigned long ms = encoder.getMillisBetweenRotations();
if (encDirectionOld == encDirection && ms < 50) { //encoder acceleration
/*if (encDirectionOld == encDirection && ms < 20) { //encoder acceleration
change = change * 5;
} else if (encDirectionOld != encDirection && ms < 150) { //filter out encoder "jumps"
} else if (encDirectionOld == encDirection && ms < 80) {
change = change * 2;
} else */ if (encDirectionOld != encDirection && ms < 200) { //filter out encoder "jumps"
change = 0;
}
encDirectionOld = encDirection;