Make companion9x compile with recent changes
This commit is contained in:
@@ -75,7 +75,7 @@ inline void board_init()
|
||||
|
||||
uint8_t check_soft_power()
|
||||
{
|
||||
#ifndef REV0
|
||||
#if !defined(SIMU) && !defined(REV0)
|
||||
if ((PING & 0b00000010) && (~PINL & 0b01000000))
|
||||
return e_power_off;
|
||||
#endif
|
||||
|
||||
@@ -479,6 +479,12 @@ bool ee32LoadGeneral()
|
||||
return true;
|
||||
}
|
||||
}
|
||||
#ifdef SIMU
|
||||
else {
|
||||
printf("EEPROM version %d instead of %d\n", g_eeGeneral.myVers, EEPROM_VER);
|
||||
fflush(stdout);
|
||||
}
|
||||
#endif
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#include "open9x.h"
|
||||
#include "../open9x.h"
|
||||
|
||||
void start_sound( void ) ;
|
||||
void buzzer_on( void ) ;
|
||||
|
||||
+3
-3
@@ -375,8 +375,10 @@ PACK(typedef struct t_SwashRingData { // Swash Ring data
|
||||
#if defined(PCBV4)
|
||||
#define NUM_ROTARY_ENCODERS 2
|
||||
#define ROTARY_ENCODER_MAX 1024
|
||||
#define ROTARY_ENCODER_ARRAY int16_t rotaryEncoders[NUM_ROTARY_ENCODERS];
|
||||
#else
|
||||
#define NUM_ROTARY_ENCODERS 0
|
||||
#define ROTARY_ENCODER_ARRAY
|
||||
#endif
|
||||
|
||||
|
||||
@@ -388,9 +390,7 @@ PACK(typedef struct t_PhaseData {
|
||||
char name[6];
|
||||
uint8_t fadeIn:4;
|
||||
uint8_t fadeOut:4;
|
||||
#if defined(PCBV4)
|
||||
int16_t rotaryEncoders[NUM_ROTARY_ENCODERS];
|
||||
#endif
|
||||
ROTARY_ENCODER_ARRAY
|
||||
}) PhaseData;
|
||||
|
||||
#define MAX_MODELS 16
|
||||
|
||||
+4
-4
@@ -1221,9 +1221,9 @@ enum PerOutMode {
|
||||
|
||||
uint8_t s_perout_mode = e_perout_mode_normal;
|
||||
|
||||
uint8_t evalSticks(uint8_t phase)
|
||||
BeepANACenter evalSticks(uint8_t phase)
|
||||
{
|
||||
uint8_t anaCenter = 0;
|
||||
BeepANACenter anaCenter = 0;
|
||||
|
||||
#ifdef HELI
|
||||
uint16_t d = 0;
|
||||
@@ -1265,7 +1265,7 @@ uint8_t evalSticks(uint8_t phase)
|
||||
calibratedStick[ch] = v; //for show in expo
|
||||
|
||||
uint8_t tmp = (uint16_t)abs(v) / 16;
|
||||
if (tmp <= 1) anaCenter |= (tmp==0 ? 1<<ch : bpanaCenter & (1<<ch));
|
||||
if (tmp <= 1) anaCenter |= (tmp==0 ? (BeepANACenter)1<<ch : bpanaCenter & ((BeepANACenter)1<<ch));
|
||||
|
||||
if (ch < NUM_STICKS) { //only do this for sticks
|
||||
if (s_perout_mode==e_perout_mode_normal && (isFunctionActive(FUNC_TRAINER) || isFunctionActive(FUNC_TRAINER_RUD+ch))) {
|
||||
@@ -1392,7 +1392,7 @@ void perOut(uint8_t phase)
|
||||
s_perOut_flight_phase = phase;
|
||||
#endif
|
||||
|
||||
uint8_t anaCenter = evalSticks(phase);
|
||||
BeepANACenter anaCenter = evalSticks(phase);
|
||||
|
||||
if (s_perout_mode == e_perout_mode_normal) {
|
||||
//===========BEEP CENTER================
|
||||
|
||||
@@ -47,6 +47,7 @@ char* eeprom_buffer_data;
|
||||
volatile int32_t eeprom_buffer_size;
|
||||
bool eeprom_read_operation;
|
||||
#define EESIZE (128*4048)
|
||||
void configure_pins( uint32_t pins, uint16_t config ) { }
|
||||
#else
|
||||
extern uint16_t eeprom_pointer;
|
||||
extern const char* eeprom_buffer_data;
|
||||
|
||||
Reference in New Issue
Block a user