mirror of
https://github.com/Ralim/IronOS.git
synced 2025-02-26 07:53:55 +00:00
Rotation fix
This commit is contained in:
@@ -472,10 +472,10 @@ static void settings_setDisplayRotation(void) {
|
||||
systemSettings.OrientationMode = systemSettings.OrientationMode % 3;
|
||||
switch (systemSettings.OrientationMode) {
|
||||
case 0:
|
||||
OLED::setRotation(true);
|
||||
OLED::setRotation(false);
|
||||
break;
|
||||
case 1:
|
||||
OLED::setRotation(false);
|
||||
OLED::setRotation(true);
|
||||
break;
|
||||
case 2:
|
||||
// do nothing on auto
|
||||
|
||||
@@ -770,7 +770,7 @@ void startGUITask(void const *argument __unused) {
|
||||
bool buttonLockout = false;
|
||||
bool tempOnDisplay = false;
|
||||
getTipRawTemp(1); // reset filter
|
||||
OLED::setRotation(!(systemSettings.OrientationMode & 1));
|
||||
OLED::setRotation(systemSettings.OrientationMode & 1);
|
||||
uint32_t ticks = xTaskGetTickCount();
|
||||
ticks += 400; // 4 seconds from now
|
||||
while (xTaskGetTickCount() < ticks) {
|
||||
@@ -1056,7 +1056,7 @@ void startMOVTask(void const *argument __unused) {
|
||||
osDelay(250); // wait for accelerometer to stabilize
|
||||
#endif
|
||||
|
||||
OLED::setRotation(!(systemSettings.OrientationMode & 1));
|
||||
OLED::setRotation(systemSettings.OrientationMode & 1);
|
||||
lastMovementTime = 0;
|
||||
int16_t datax[MOVFilter] = { 0 };
|
||||
int16_t datay[MOVFilter] = { 0 };
|
||||
|
||||
Reference in New Issue
Block a user