/beta/Code Redesign killagreg/eeprom.c |
---|
163,6 → 163,9 |
ParamSet.ServoRollComp = 40; |
ParamSet.ServoRollMin = 0; |
ParamSet.ServoRollMax = 250; |
ParamSet.Servo3 = 127; |
ParamSet.Servo4 = 127; |
ParamSet.Servo5 = 127; |
ParamSet.LoopGasLimit = 50; |
ParamSet.LoopThreshold = 90; |
ParamSet.LoopHysteresis = 50; |
263,6 → 266,9 |
ParamSet.ServoRollComp = 40; |
ParamSet.ServoRollMin = 0; |
ParamSet.ServoRollMax = 250; |
ParamSet.Servo3 = 127; |
ParamSet.Servo4 = 127; |
ParamSet.Servo5 = 127; |
ParamSet.LoopGasLimit = 50; |
ParamSet.LoopThreshold = 90; |
ParamSet.LoopHysteresis = 50; |
363,6 → 369,9 |
ParamSet.ServoRollComp = 40; |
ParamSet.ServoRollMin = 0; |
ParamSet.ServoRollMax = 250; |
ParamSet.Servo3 = 127; |
ParamSet.Servo4 = 127; |
ParamSet.Servo5 = 127; |
ParamSet.LoopGasLimit = 50; |
ParamSet.LoopThreshold = 90; |
ParamSet.LoopHysteresis = 50; |
/beta/Code Redesign killagreg/eeprom.h |
---|
93,7 → 93,7 |
#define CH_POTI7 10 |
#define CH_POTI8 11 |
#define EEPARAM_REVISION 81 // is count up, if paramater stucture has changed (compatibility) |
#define EEPARAM_REVISION 82 // is count up, if paramater stucture has changed (compatibility) |
#define EEMIXER_REVISION 1 // is count up, if mixer stucture has changed (compatibility) |
// values above 247 representing poti1 to poti8 |
150,6 → 150,9 |
uint8_t ServoRollMin; // Value : 0-247 // Anschlag |
uint8_t ServoRollMax; // Value : 0-247 // Anschlag |
uint8_t ServoRefresh; // Value: 0-247 // Refreshrate of servo pwm output |
uint8_t Servo3; // Value: 0-247 servo value or mapping |
uint8_t Servo4; // Value: 0-247 servo value or mapping |
uint8_t Servo5; // Value: 0-247 servo value or mapping |
uint8_t LoopGasLimit; // Value: 0-247 max. Gas während Looping |
uint8_t LoopThreshold; // Value: 0-247 Schwelle für Stickausschlag |
uint8_t LoopHysteresis; // Value: 0-247 Hysterese für Stickausschlag |
/beta/Code Redesign killagreg/fc.c |
---|
613,6 → 613,9 |
CHK_POTI(FCParam.UserParam8,ParamSet.UserParam8); |
CHK_POTI(FCParam.ServoNickControl,ParamSet.ServoNickControl); |
CHK_POTI(FCParam.ServoRollControl,ParamSet.ServoRollControl); |
CHK_POTI(FCParam.Servo3,ParamSet.Servo3); |
CHK_POTI(FCParam.Servo4,ParamSet.Servo4); |
CHK_POTI(FCParam.Servo5,ParamSet.Servo5); |
CHK_POTI(FCParam.LoopGasLimit,ParamSet.LoopGasLimit); |
CHK_POTI(FCParam.AxisCoupling1,ParamSet.AxisCoupling1); |
CHK_POTI(FCParam.AxisCoupling2,ParamSet.AxisCoupling2); |
737,7 → 740,7 |
else MKFlags |= MKFLAG_FLY; // set fly flag |
// update poti values |
//limit poti values |
// limit poti values |
#define POTI_MIN 0 |
#define POTI_MAX 255 |
for(i=0; i<8; i++) |
745,8 → 748,9 |
int tmp; |
tmp = PPM_in[ParamSet.ChannelAssignment[CH_POTI1+i]] + RC_POTI_OFFSET; |
LIMIT_MIN_MAX(tmp, POTI_MIN, POTI_MAX); |
if(tmp < Poti[i]) Poti[i]--; |
else if(tmp > Poti[i]) Poti[i]++; |
Poti[i] = tmp; |
//if(tmp < Poti[i]) Poti[i]--; |
//else if(tmp > Poti[i]) Poti[i]++; |
} |
// if motors are off and the gas stick is in the upper position |
/beta/Code Redesign killagreg/fc.h |
---|
56,6 → 56,9 |
uint8_t UserParam8; |
uint8_t ServoNickControl; |
uint8_t ServoRollControl; |
uint8_t Servo3; |
uint8_t Servo4; |
uint8_t Servo5; |
uint8_t LoopGasLimit; |
uint8_t AxisCoupling1; |
uint8_t AxisCoupling2; |
/beta/Code Redesign killagreg/timer2.c |
---|
289,6 → 289,15 |
ServoRollValue /= MULTIPLYER; |
break; |
case 3: RemainingPulse += 2 * FCParam.Servo3; |
break; |
case 4: RemainingPulse += 2 * FCParam.Servo4; |
break; |
case 5: RemainingPulse += 2 * FCParam.Servo5; |
break; |
default: // other servo channels |
RemainingPulse += 2 * PPM_in[ServoIndex]; // add channel value, factor of 2 because timer 1 increments 3.2µs |
break; |
/beta/Code Redesign killagreg/uart0.c |
---|
64,6 → 64,7 |
#include "uart0.h" |
#include "fc.h" |
#include "rc.h" |
#include "printf_P.h" |
#if defined (USE_KILLAGREG) || defined (USE_MK3MAG) |
#include "ubx.h" |
#endif |
694,7 → 695,7 |
} |
else // old format |
{ |
sprintf(DisplayBuff, "!!! INCOMPATIBLE !!!"); |
LCD_printfxy(0,0,"!!! INCOMPATIBLE !!!"); |
SendOutData('H', FC_ADDRESS, 2, &DisplayLine, sizeof(DisplayLine), (uint8_t *)DisplayBuff, 20); |
if(DisplayLine++ > 3) DisplayLine = 0; |
} |
/beta/Code Redesign killagreg/uart0.h |
---|
1,10 → 1,9 |
#ifndef _UART0_H |
#define _UART0_H |
#define RXD_BUFFER_LEN 150 |
// must be at least 4('#'+Addr+'CmdID'+'\r')+ (80 * 4)/3 = 111 bytes |
#define TXD_BUFFER_LEN 150 |
#define RXD_BUFFER_LEN 150 |
#define TXD_BUFFER_LEN 160 |
#define RXD_BUFFER_LEN 160 |
#include <inttypes.h> |
/beta/Code Redesign killagreg/version.txt |
---|
349,6 → 349,7 |
- Erweiterung auf 12 Kanäle |
- Bei Koptertool-Kanalabfrage kein Empfangsausfall-Piepsen |
- serielle Kanalerweiterung eingebaut -> PPM_in auf 25 erweitert |
- Servos3-5 einstellbar |
Anpassungen bzgl. V0.77a |