Issue 19 solved
Revert the last Haptic changes (was unfinished, no more spare time during the week-end, sorry!) Revert my last modification on main views (offset not displayed in Bar Graphs, I was wrong) PPM Center now configurable for each servo No mean on the Batt voltage when in the calibration menu to have a faster response when calibrating SD card Backup / Restore Models feature started Some french translations fixed
This commit is contained in:
+4
-3
@@ -193,9 +193,10 @@ ISR(TIMER1_COMPA_vect) //2MHz pulse generation
|
||||
|
||||
#endif
|
||||
|
||||
#define PPM_CENTER 1500
|
||||
|
||||
FORCEINLINE void setupPulsesPPM()
|
||||
{
|
||||
#define PPM_CENTER 1500*2
|
||||
int16_t PPM_range = g_model.extendedLimits ? 640*2 : 512*2; //range of 0.7..1.7msec
|
||||
|
||||
//Total frame length = 22.5msec
|
||||
@@ -211,7 +212,7 @@ FORCEINLINE void setupPulsesPPM()
|
||||
uint16_t rest = 22500u*2-q; //Minimum Framelen=22.5 ms
|
||||
rest += (int16_t(g_model.ppmFrameLength))*1000;
|
||||
for (uint8_t i=0; i<p; i++) {
|
||||
int16_t v = limit((int16_t)-PPM_range, g_chans512[i], (int16_t)PPM_range) + PPM_CENTER;
|
||||
int16_t v = limit((int16_t)-PPM_range, g_chans512[i], (int16_t)PPM_range) + 2*(PPM_CENTER+g_model.servoCenter[i]);
|
||||
rest -= v;
|
||||
*ptr++ = v - q; /* as Pat MacKenzie suggests, reviewed and modified by Cam */
|
||||
*ptr++ = q;
|
||||
@@ -818,7 +819,7 @@ void setupPulsesPPM16()
|
||||
uint16_t rest=22500u*2-q; //Minimum Framelen=22.5 ms
|
||||
rest += (int16_t(g_model.ppmFrameLength))*1000;
|
||||
for (uint8_t i=p-8; i<p; i++) { //NUM_CHNOUT
|
||||
int16_t v = limit((int16_t)-PPM_range, g_chans512[i], (int16_t)PPM_range) + PPM_CENTER;
|
||||
int16_t v = limit((int16_t)-PPM_range, g_chans512[i], (int16_t)PPM_range) + 2*(PPM_CENTER+g_model.servoCenter[i]);
|
||||
rest -= v;
|
||||
*ptr++ = q;
|
||||
*ptr++ = v - q; /* as Pat MacKenzie suggests, reviewed and modified by Cam */
|
||||
|
||||
Reference in New Issue
Block a user