mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-25 01:05:27 +03:00
Removed profile storage code from writeEEProm() to remove the boolean
flag from the method signature. Now it is clear when the current profile needs to be stored.
This commit is contained in:
parent
e969d184e6
commit
3daaf66b14
7 changed files with 28 additions and 20 deletions
5
src/mw.c
5
src/mw.c
|
@ -496,7 +496,7 @@ void loop(void)
|
|||
i = 3;
|
||||
if (i) {
|
||||
mcfg.current_profile = i - 1;
|
||||
writeEEPROM(0, false);
|
||||
writeEEPROM(0);
|
||||
blinkLedAndSoundBeeper(2, 40, i);
|
||||
// TODO alarmArray[0] = i;
|
||||
}
|
||||
|
@ -529,7 +529,8 @@ void loop(void)
|
|||
i = 1;
|
||||
}
|
||||
if (i) {
|
||||
writeEEPROM(1, true);
|
||||
copyCurrentProfileToProfileSlot(mcfg.current_profile);
|
||||
writeEEPROM(1);
|
||||
rcDelayCommand = 0; // allow autorepetition
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue