diff --git a/source/drivers/MicroBitAccelerometer.cpp b/source/drivers/MicroBitAccelerometer.cpp index da71ccb..df56ae7 100644 --- a/source/drivers/MicroBitAccelerometer.cpp +++ b/source/drivers/MicroBitAccelerometer.cpp @@ -311,6 +311,7 @@ void MicroBitAccelerometer::updateGesture() if (g == MICROBIT_ACCELEROMETER_EVT_SHAKE) { + lastGesture = MICROBIT_ACCELEROMETER_EVT_SHAKE; MicroBitEvent e(MICROBIT_ID_GESTURE, MICROBIT_ACCELEROMETER_EVT_SHAKE); return; }