1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-23 16:25:16 +03:00

Reduced number of logical switch context to 2. Now we have only active fm context (lswFM[0]) and other context that is used for all other fms (lswFm[1]).

Much smaller RAM usage, but possible (I beleave unimportant) errors when trasitioning between more than two flight modes.
This commit is contained in:
Damjan Adamic 2014-05-18 18:08:41 +02:00
parent fbb1b65fd6
commit e14734c8af
3 changed files with 16 additions and 19 deletions

View file

@ -671,6 +671,7 @@ enum StartupWarningStates {
#endif
extern uint8_t s_current_mixer_flight_mode;
extern uint8_t s_last_phase;
#if defined(CPUARM)
#define bitfield_channels_t uint32_t
@ -695,8 +696,8 @@ getvalue_t getValue(uint8_t i);
bool getSwitch(int8_t swtch);
void logicalSwitchesTimerTick();
void logicalSwitchesReset();
void evalLogicalSwitches(uint8_t mode);
void logicalSwitchesCopyState(uint8_t oldPhase, uint8_t newPhase);
void evalLogicalSwitches();
void logicalSwitchesCopyState();
#if defined(PCBTARANIS)
void getSwitchesPosition(bool startup);