Subversion Repositories FlightCtrl

Rev

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

Rev 1744 Rev 1760
Line 173... Line 173...
173
                        }
173
                        }
174
                        else I2C_WriteByte(TWI_BASE_ADDRESS + TW_WRITE + (motor_write<<1) ); // select slave address in tx mode
174
                        else I2C_WriteByte(TWI_BASE_ADDRESS + TW_WRITE + (motor_write<<1) ); // select slave address in tx mode
175
                        break;
175
                        break;
176
        case 1: // Send Data to Slave
176
        case 1: // Send Data to Slave
177
                        I2C_WriteByte(Motor[motor_write].SetPoint); // transmit setpoint
177
                        I2C_WriteByte(Motor[motor_write].SetPoint); // transmit setpoint
178
if(Motor[motor_write].SetPoint == 0) if(MotorenEin) DebugOut.Analog[17]++;
-
 
179
                        // if old version has been detected
178
                        // if old version has been detected
180
                        if(!(Motor[motor_write].Version & MOTOR_STATE_NEW_PROTOCOL_MASK))
179
                        if(!(Motor[motor_write].Version & MOTOR_STATE_NEW_PROTOCOL_MASK))
181
                        {
180
                        {
182
                                twi_state = 4; //jump over sending more data
181
                                twi_state = 4; //jump over sending more data
183
                        }
182
                        }