@@ -57,7 +57,7 @@ static buttonAction_t button_action;
5757static unsigned switch_is_on (unsigned sw , volatile s32 * raw );
5858static s32 get_trim (unsigned src );
5959
60- static void MIXER_CreateCyclicOutput (volatile s32 * raw , s32 * cyc );
60+ static void MIXER_CreateCyclicOutput (volatile s32 * raw , s32 * cyclic );
6161
6262struct Mixer * MIXER_GetAllMixers ()
6363{
@@ -178,14 +178,14 @@ void MIXER_CalcChannels()
178178 MIXER_EvalMixers (raw );
179179
180180 //4th step: apply auto-templates
181- s32 cyc [3 ];
182- MIXER_CreateCyclicOutput (raw , cyc );
181+ s32 cyclic [3 ];
182+ MIXER_CreateCyclicOutput (raw , cyclic );
183183 for (i = 0 ; i < NUM_OUT_CHANNELS ; i ++ ) {
184184 switch (Model .templates [i ]) {
185185 case MIXERTEMPLATE_CYC1 :
186186 case MIXERTEMPLATE_CYC2 :
187187 case MIXERTEMPLATE_CYC3 :
188- raw [NUM_INPUTS + i + 1 ] = cyc [Model .templates [i ] - MIXERTEMPLATE_CYC1 ];
188+ raw [NUM_INPUTS + i + 1 ] = cyclic [Model .templates [i ] - MIXERTEMPLATE_CYC1 ];
189189 break ;
190190 }
191191 }
@@ -232,12 +232,12 @@ char* MIXER_GetChannelDisplayFormat(unsigned channel)
232232
233233#define REZ_SWASH_X (x ) ((x) - (x)/8 - (x)/128 - (x)/512) // 1024*sin(60) ~= 886
234234#define REZ_SWASH_Y (x ) (1*(x)) // 1024 => 1024
235- void MIXER_CreateCyclicOutput (volatile s32 * raw , s32 * cyc )
235+ void MIXER_CreateCyclicOutput (volatile s32 * raw , s32 * cyclic )
236236{
237237 if (! Model .swash_type ) {
238- cyc [0 ] = raw [NUM_INPUTS + NUM_OUT_CHANNELS + 1 ];
239- cyc [1 ] = raw [NUM_INPUTS + NUM_OUT_CHANNELS + 2 ];
240- cyc [2 ] = raw [NUM_INPUTS + NUM_OUT_CHANNELS + 3 ];
238+ cyclic [0 ] = raw [NUM_INPUTS + NUM_OUT_CHANNELS + 1 ];
239+ cyclic [1 ] = raw [NUM_INPUTS + NUM_OUT_CHANNELS + 2 ];
240+ cyclic [2 ] = raw [NUM_INPUTS + NUM_OUT_CHANNELS + 3 ];
241241 return ;
242242 }
243243 s32 aileron = raw [NUM_INPUTS + NUM_OUT_CHANNELS + 1 ];
@@ -252,41 +252,41 @@ void MIXER_CreateCyclicOutput(volatile s32 *raw, s32 *cyc)
252252 switch (Model .swash_type ) {
253253 case SWASH_TYPE_NONE :
254254 case SWASH_TYPE_LAST :
255- cyc [0 ] = aileron ;
256- cyc [1 ] = elevator ;
257- cyc [2 ] = collective ;
255+ cyclic [0 ] = aileron ;
256+ cyclic [1 ] = elevator ;
257+ cyclic [2 ] = collective ;
258258 break ;
259259 case SWASH_TYPE_120 :
260260 aileron = Model .swashmix [0 ] * aileron / normalize ;
261261 elevator = Model .swashmix [1 ] * elevator / normalize ;
262262 collective = Model .swashmix [2 ] * collective / normalize ;
263- cyc [0 ] = collective - elevator ;
264- cyc [1 ] = collective + elevator /2 + aileron ;
265- cyc [2 ] = collective + elevator /2 - aileron ;
263+ cyclic [0 ] = collective - elevator ;
264+ cyclic [1 ] = collective + elevator /2 + aileron ;
265+ cyclic [2 ] = collective + elevator /2 - aileron ;
266266 break ;
267267 case SWASH_TYPE_120X :
268268 aileron = Model .swashmix [0 ] * aileron / normalize ;
269269 elevator = Model .swashmix [1 ] * elevator / normalize ;
270270 collective = Model .swashmix [2 ] * collective / normalize ;
271- cyc [0 ] = collective - aileron ;
272- cyc [1 ] = collective + aileron /2 + elevator ;
273- cyc [2 ] = collective + aileron /2 - elevator ;
271+ cyclic [0 ] = collective - aileron ;
272+ cyclic [1 ] = collective + aileron /2 + elevator ;
273+ cyclic [2 ] = collective + aileron /2 - elevator ;
274274 break ;
275275 case SWASH_TYPE_140 :
276276 aileron = Model .swashmix [0 ] * aileron / normalize ;
277277 elevator = Model .swashmix [1 ] * elevator / normalize ;
278278 collective = Model .swashmix [2 ] * collective / normalize ;
279- cyc [0 ] = collective - elevator ;
280- cyc [1 ] = collective + elevator + aileron ;
281- cyc [2 ] = collective + elevator - aileron ;
279+ cyclic [0 ] = collective - elevator ;
280+ cyclic [1 ] = collective + elevator + aileron ;
281+ cyclic [2 ] = collective + elevator - aileron ;
282282 break ;
283283 case SWASH_TYPE_90 :
284284 aileron = Model .swashmix [0 ] * aileron / normalize ;
285285 elevator = Model .swashmix [1 ] * elevator / normalize ;
286286 collective = Model .swashmix [2 ] * collective / normalize ;
287- cyc [0 ] = collective - elevator ;
288- cyc [1 ] = collective + aileron ;
289- cyc [2 ] = collective - aileron ;
287+ cyclic [0 ] = collective - elevator ;
288+ cyclic [1 ] = collective + aileron ;
289+ cyclic [2 ] = collective - aileron ;
290290 break ;
291291 }
292292}
0 commit comments