Subversion Repositories FlightCtrl

Rev

Rev 2108 | Rev 2110 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2108 Rev 2109
Line 52... Line 52...
52
void controlMixer_updateVariables(void) {
52
void controlMixer_updateVariables(void) {
53
  uint8_t i;
53
  uint8_t i;
54
  int16_t targetvalue;
54
  int16_t targetvalue;
55
  for (i=0; i < VARIABLE_COUNT; i++) {
55
  for (i=0; i < VARIABLE_COUNT; i++) {
56
    targetvalue = RC_getVariable(i);
56
    targetvalue = RC_getVariable(i);
-
 
57
    if (i<2) debugOut.analog[18+i] = targetvalue;
57
    if (targetvalue < 0)
58
    if (targetvalue < 0)
58
      targetvalue = 0;
59
      targetvalue = 0;
59
    if (variables[i] < targetvalue && variables[i] < 255)
60
    if (variables[i] < targetvalue && variables[i] < 255)
60
      variables[i]++;
61
      variables[i]++;
61
    else if (variables[i] > 0 && variables[i] > targetvalue)
62
    else if (variables[i] > 0 && variables[i] > targetvalue)