Check against rotations.
This commit is contained in:
parent
78fb25b5a1
commit
d96e0d30b3
|
@ -87,7 +87,7 @@ void loop() {
|
||||||
}
|
}
|
||||||
|
|
||||||
rotations = (int) floor((float) pos / (float) maxPulses);
|
rotations = (int) floor((float) pos / (float) maxPulses);
|
||||||
if (pos != lastRotationPosition) {
|
if (rotations != lastRotationPosition) {
|
||||||
lastRotationPosition = rotations;
|
lastRotationPosition = rotations;
|
||||||
frames = rotations * framesPerRotation;
|
frames = rotations * framesPerRotation;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue