Subversion Repositories FlightCtrl

Compare Revisions

Ignore whitespace Rev 1774 → Rev 1775

/branches/dongfang_FC_rewrite/flight.h
12,6 → 12,16
#define PITCH 0
#define ROLL 1
 
/*
* The output BLC throttles can be set in an [0..256[ interval. Some staticParams limits
* (min, throttle, max throttle etc) are in a [0..256[ interval.
* The calculation of motor throttle values from sensor and control information (basically
* flight.c) take place in an [0..1024[ interval for better precision.
* This is the conversion factor.
* --> Replaced back again by CONTROL_SCALING. Even though the 2 things are not quite the
* same, they are unseperable anyway.
*/
 
extern uint8_t RequiredMotors;
 
// looping params
18,14 → 28,16
// extern long TurnOver180Nick, TurnOver180Roll;
 
// external control
extern int16_t ExternStickNick, ExternStickRoll, ExternStickYaw;
// extern int16_t ExternStickNick, ExternStickRoll, ExternStickYaw;
// extern int16_t naviAccPitch, naviAccRoll, naviCntAcc;
 
extern int16_t naviAccPitch, naviAccRoll, naviCntAcc;
// TODO: Rip em up, replace by a flight-state machine.
// OK first step: Move to control mixer, where the state machine will be located anyway.
// extern volatile uint8_t MKFlags;
// extern uint16_t isFlying;
 
extern volatile uint8_t MKFlags;
 
void flight_control(void);
void sendMotorData(void);
void transmitMotorThrottleData(void);
void flight_setNeutral(void);
 
#endif //_FLIGHT_H