chore(radio): Move const data from RAM to FLASH. (#4098)
Co-authored-by: philmoz <phil.a.mitchell@gmail.com>
This commit is contained in:
+1
-1
@@ -92,7 +92,7 @@ static const unsigned short crc16tab_1189[256] = {
|
|||||||
0x7bc7,0x6a4e,0x58d5,0x495c,0x3de3,0x2c6a,0x1ef1,0x0f78
|
0x7bc7,0x6a4e,0x58d5,0x495c,0x3de3,0x2c6a,0x1ef1,0x0f78
|
||||||
};
|
};
|
||||||
|
|
||||||
const unsigned short * crc16tab[] = {
|
const unsigned short * const crc16tab[] = {
|
||||||
crc16tab_1021,
|
crc16tab_1021,
|
||||||
crc16tab_1189
|
crc16tab_1189
|
||||||
};
|
};
|
||||||
|
|||||||
+1
-1
@@ -29,7 +29,7 @@ enum {
|
|||||||
CRC_1189,
|
CRC_1189,
|
||||||
};
|
};
|
||||||
|
|
||||||
extern const unsigned short * crc16tab[2];
|
extern const unsigned short * const crc16tab[2];
|
||||||
|
|
||||||
uint8_t crc8(const uint8_t * ptr, uint32_t len);
|
uint8_t crc8(const uint8_t * ptr, uint32_t len);
|
||||||
uint8_t crc8_BA(const uint8_t * ptr, uint32_t len);
|
uint8_t crc8_BA(const uint8_t * ptr, uint32_t len);
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ enum GVarFields {
|
|||||||
|
|
||||||
#define GVAR_2ND_COLUMN (12*FW)
|
#define GVAR_2ND_COLUMN (12*FW)
|
||||||
|
|
||||||
static const char* _str_units[] = { "-", "%" };
|
static const char* const _str_units[] = { "-", "%" };
|
||||||
|
|
||||||
void menuModelGVarOne(event_t event)
|
void menuModelGVarOne(event_t event)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -65,7 +65,7 @@ enum GVarFields {
|
|||||||
|
|
||||||
#define GVAR_2ND_COLUMN (12*FW)
|
#define GVAR_2ND_COLUMN (12*FW)
|
||||||
|
|
||||||
static const char* _str_units[] = { "-", "%" };
|
static const char* const _str_units[] = { "-", "%" };
|
||||||
|
|
||||||
void menuModelGVarOne(event_t event)
|
void menuModelGVarOne(event_t event)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -29,11 +29,11 @@ static const lv_coord_t row_dsc[] = {LV_GRID_CONTENT,
|
|||||||
|
|
||||||
#define SET_DIRTY()
|
#define SET_DIRTY()
|
||||||
|
|
||||||
static const char* _analog_outputs[] = { "PWM", "PPM" };
|
static const char* const _analog_outputs[] = { "PWM", "PPM" };
|
||||||
static const char* _bus_types[] = { "iBUS OUT", "iBUS IN", "SBUS" };
|
static const char* const _bus_types[] = { "iBUS OUT", "iBUS IN", "SBUS" };
|
||||||
static const char* _v1_bus_types[] = { "PWM", "PPM", "SBUS", "iBUS IN", "iBUS OUT" };
|
static const char* const _v1_bus_types[] = { "PWM", "PPM", "SBUS", "iBUS IN", "iBUS OUT" };
|
||||||
static const char* _v1_pwmfreq_types[] = { STR_ANALOG_SERVO, STR_DIGITAL_SERVO, "SR833HZ", "SFR1000HZ", STR_MULTI_CUSTOM };
|
static const char* const _v1_pwmfreq_types[] = { STR_ANALOG_SERVO, STR_DIGITAL_SERVO, "SR833HZ", "SFR1000HZ", STR_MULTI_CUSTOM };
|
||||||
static const char* _v0_pwmfreq_types[] = { STR_ANALOG_SERVO, STR_DIGITAL_SERVO, STR_MULTI_CUSTOM };
|
static const char* const _v0_pwmfreq_types[] = { STR_ANALOG_SERVO, STR_DIGITAL_SERVO, STR_MULTI_CUSTOM };
|
||||||
|
|
||||||
static const uint16_t _v1_index2pwmvalue[] = {50, 333, 2, 1, 50};
|
static const uint16_t _v1_index2pwmvalue[] = {50, 333, 2, 1, 50};
|
||||||
static const uint16_t _v0_index2pwmvalue[] = {50, 333, 50};
|
static const uint16_t _v0_index2pwmvalue[] = {50, 333, 50};
|
||||||
|
|||||||
@@ -23,9 +23,9 @@
|
|||||||
#include "afhds3_options.h"
|
#include "afhds3_options.h"
|
||||||
#include "opentx.h"
|
#include "opentx.h"
|
||||||
|
|
||||||
static const char* _afhds3_region[] = { "CE", "FCC" };
|
static const char* const _afhds3_region[] = { "CE", "FCC" };
|
||||||
|
|
||||||
static const char* _afhds3_phy_mode[] = {
|
static const char* const _afhds3_phy_mode[] = {
|
||||||
// V0
|
// V0
|
||||||
"Classic 18ch",
|
"Classic 18ch",
|
||||||
"C-Fast 10ch",
|
"C-Fast 10ch",
|
||||||
|
|||||||
@@ -26,8 +26,8 @@ constexpr int BAR_MARGIN = 5;
|
|||||||
constexpr int BAR_TOP_MARGIN = 5;
|
constexpr int BAR_TOP_MARGIN = 5;
|
||||||
constexpr int BAR_HEIGHT_OFFSET = BAR_TOP_MARGIN + 25;
|
constexpr int BAR_HEIGHT_OFFSET = BAR_TOP_MARGIN + 25;
|
||||||
|
|
||||||
static const char *RGBChars[MAX_BARS] = { "R", "G", "B" };
|
static const char * const RGBChars[MAX_BARS] = { "R", "G", "B" };
|
||||||
static const char *HSVChars[MAX_BARS] = { "H", "S", "V" };
|
static const char * const HSVChars[MAX_BARS] = { "H", "S", "V" };
|
||||||
|
|
||||||
void ColorBar::pressing(lv_event_t* e)
|
void ColorBar::pressing(lv_event_t* e)
|
||||||
{
|
{
|
||||||
@@ -276,7 +276,7 @@ uint32_t HSVColorType::getRGB()
|
|||||||
return HSVtoRGB(bars[0]->value, bars[1]->value, bars[2]->value);
|
return HSVtoRGB(bars[0]->value, bars[1]->value, bars[2]->value);
|
||||||
}
|
}
|
||||||
|
|
||||||
const char** HSVColorType::getLabelChars()
|
const char* const* HSVColorType::getLabelChars()
|
||||||
{
|
{
|
||||||
return HSVChars;
|
return HSVChars;
|
||||||
}
|
}
|
||||||
@@ -306,7 +306,7 @@ uint32_t RGBColorType::getRGB()
|
|||||||
return RGB(bars[0]->value, bars[1]->value, bars[2]->value);
|
return RGB(bars[0]->value, bars[1]->value, bars[2]->value);
|
||||||
}
|
}
|
||||||
|
|
||||||
const char** RGBColorType::getLabelChars()
|
const char* const* RGBColorType::getLabelChars()
|
||||||
{
|
{
|
||||||
return RGBChars;
|
return RGBChars;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ protected:
|
|||||||
lv_obj_t* barLabels[MAX_BARS];
|
lv_obj_t* barLabels[MAX_BARS];
|
||||||
lv_obj_t* barValLabels[MAX_BARS];
|
lv_obj_t* barValLabels[MAX_BARS];
|
||||||
|
|
||||||
virtual const char** getLabelChars() { return nullptr; };
|
virtual const char* const* getLabelChars() { return nullptr; };
|
||||||
|
|
||||||
lv_obj_t* create_bar_label(lv_obj_t* parent, lv_coord_t x, lv_coord_t y);
|
lv_obj_t* create_bar_label(lv_obj_t* parent, lv_coord_t x, lv_coord_t y);
|
||||||
lv_obj_t* create_bar_value_label(lv_obj_t* parent, lv_coord_t x, lv_coord_t y);
|
lv_obj_t* create_bar_value_label(lv_obj_t* parent, lv_coord_t x, lv_coord_t y);
|
||||||
@@ -88,7 +88,7 @@ public:
|
|||||||
uint32_t getRGB() override;
|
uint32_t getRGB() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
const char** getLabelChars() override;
|
const char* const* getLabelChars() override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// Color editor for RGB color input
|
// Color editor for RGB color input
|
||||||
@@ -98,7 +98,7 @@ public:
|
|||||||
uint32_t getRGB() override;
|
uint32_t getRGB() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
const char** getLabelChars() override;
|
const char* const* getLabelChars() override;
|
||||||
};
|
};
|
||||||
|
|
||||||
// Color editor that shows the system theme colors as buttons
|
// Color editor that shows the system theme colors as buttons
|
||||||
|
|||||||
@@ -187,7 +187,7 @@ class TSStyle
|
|||||||
|
|
||||||
static TSStyle tsStyle;
|
static TSStyle tsStyle;
|
||||||
|
|
||||||
static uint8_t freshBitmap[] = {
|
static uint8_t const freshBitmap[] = {
|
||||||
0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x00,
|
0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x00,
|
||||||
0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00,
|
0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00,
|
||||||
0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00,
|
0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00,
|
||||||
@@ -290,7 +290,7 @@ class SensorButton : public Button {
|
|||||||
|
|
||||||
box = tsStyle.newFreshCont(lvobj);
|
box = tsStyle.newFreshCont(lvobj);
|
||||||
fresh = tsStyle.newFreshIcon(box);
|
fresh = tsStyle.newFreshIcon(box);
|
||||||
lv_canvas_set_buffer(fresh, freshBitmap, 8, 8, LV_IMG_CF_ALPHA_8BIT);
|
lv_canvas_set_buffer(fresh, (void*)freshBitmap, 8, 8, LV_IMG_CF_ALPHA_8BIT);
|
||||||
lv_obj_add_flag(fresh, LV_OBJ_FLAG_HIDDEN);
|
lv_obj_add_flag(fresh, LV_OBJ_FLAG_HIDDEN);
|
||||||
|
|
||||||
valLabel = tsStyle.newValue(lvobj);
|
valLabel = tsStyle.newValue(lvobj);
|
||||||
|
|||||||
@@ -26,7 +26,7 @@
|
|||||||
// TODO: format for LCD_WIDTH > LCD_HEIGHT
|
// TODO: format for LCD_WIDTH > LCD_HEIGHT
|
||||||
|
|
||||||
// TODO: translation
|
// TODO: translation
|
||||||
const char* RFSCAN_TITLE = "MPM: Scanning protocols...";
|
const char* const RFSCAN_TITLE = "MPM: Scanning protocols...";
|
||||||
|
|
||||||
RfScanDialog::RfScanDialog(Window* parent, MultiRfProtocols* protos,
|
RfScanDialog::RfScanDialog(Window* parent, MultiRfProtocols* protos,
|
||||||
std::function<void()> onClose) :
|
std::function<void()> onClose) :
|
||||||
|
|||||||
@@ -128,7 +128,7 @@ static const struct YamlNode r_struct_YAMLTheme[] = {
|
|||||||
YAML_END
|
YAML_END
|
||||||
};
|
};
|
||||||
|
|
||||||
static const char *colorNames[COLOR_COUNT] = {
|
static const char * const colorNames[COLOR_COUNT] = {
|
||||||
STR_THEME_COLOR_DEFAULT, STR_THEME_COLOR_PRIMARY1, STR_THEME_COLOR_PRIMARY2, STR_THEME_COLOR_PRIMARY3,
|
STR_THEME_COLOR_DEFAULT, STR_THEME_COLOR_PRIMARY1, STR_THEME_COLOR_PRIMARY2, STR_THEME_COLOR_PRIMARY3,
|
||||||
STR_THEME_COLOR_SECONDARY1, STR_THEME_COLOR_SECONDARY2, STR_THEME_COLOR_SECONDARY3, STR_THEME_COLOR_FOCUS,
|
STR_THEME_COLOR_SECONDARY1, STR_THEME_COLOR_SECONDARY2, STR_THEME_COLOR_SECONDARY3, STR_THEME_COLOR_FOCUS,
|
||||||
STR_THEME_COLOR_EDIT, STR_THEME_COLOR_ACTIVE, STR_THEME_COLOR_WARNING, STR_THEME_COLOR_DISABLED, STR_THEME_COLOR_CUSTOM,
|
STR_THEME_COLOR_EDIT, STR_THEME_COLOR_ACTIVE, STR_THEME_COLOR_WARNING, STR_THEME_COLOR_DISABLED, STR_THEME_COLOR_CUSTOM,
|
||||||
|
|||||||
@@ -839,7 +839,7 @@ const lv_obj_class_t etx_bar_class = {
|
|||||||
.destructor_cb = nullptr,
|
.destructor_cb = nullptr,
|
||||||
.user_data = nullptr,
|
.user_data = nullptr,
|
||||||
.event_cb = nullptr,
|
.event_cb = nullptr,
|
||||||
.width_def = lv_pct(100),
|
.width_def = LV_PCT(100),
|
||||||
.height_def = 32,
|
.height_def = 32,
|
||||||
.editable = LV_OBJ_CLASS_EDITABLE_INHERIT,
|
.editable = LV_OBJ_CLASS_EDITABLE_INHERIT,
|
||||||
.group_def = LV_OBJ_CLASS_GROUP_DEF_INHERIT,
|
.group_def = LV_OBJ_CLASS_GROUP_DEF_INHERIT,
|
||||||
@@ -852,8 +852,8 @@ const lv_obj_class_t etx_checkbox_class = {
|
|||||||
.destructor_cb = nullptr,
|
.destructor_cb = nullptr,
|
||||||
.user_data = nullptr,
|
.user_data = nullptr,
|
||||||
.event_cb = nullptr,
|
.event_cb = nullptr,
|
||||||
.width_def = lv_pct(100),
|
.width_def = LV_PCT(100),
|
||||||
.height_def = lv_pct(100),
|
.height_def = LV_PCT(100),
|
||||||
.editable = LV_OBJ_CLASS_EDITABLE_INHERIT,
|
.editable = LV_OBJ_CLASS_EDITABLE_INHERIT,
|
||||||
.group_def = LV_OBJ_CLASS_GROUP_DEF_INHERIT,
|
.group_def = LV_OBJ_CLASS_GROUP_DEF_INHERIT,
|
||||||
.instance_size = sizeof(lv_checkbox_t),
|
.instance_size = sizeof(lv_checkbox_t),
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ static void sendDSM(uint8_t*& p_buf, uint8_t module);
|
|||||||
|
|
||||||
#include "hal/module_port.h"
|
#include "hal/module_port.h"
|
||||||
|
|
||||||
etx_serial_init multiSerialInitParams = {
|
etx_serial_init const multiSerialInitParams = {
|
||||||
.baudrate = MULTIMODULE_BAUDRATE,
|
.baudrate = MULTIMODULE_BAUDRATE,
|
||||||
.encoding = ETX_Encoding_8E2,
|
.encoding = ETX_Encoding_8E2,
|
||||||
.direction = ETX_Dir_TX,
|
.direction = ETX_Dir_TX,
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
#if defined(SIMU)
|
#if defined(SIMU)
|
||||||
const uint32_t cpu_uid[3] = { 0x12345678, 0x55AA55AA, 0x87654321};
|
const uint32_t cpu_uid[3] = { 0x12345678, 0x55AA55AA, 0x87654321};
|
||||||
#else
|
#else
|
||||||
const uint32_t * cpu_uid = (uint32_t *)0x1FFF7A10;
|
const uint32_t * const cpu_uid = (uint32_t *)0x1FFF7A10;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
void getCPUUniqueID(char * s)
|
void getCPUUniqueID(char * s)
|
||||||
|
|||||||
@@ -29,5 +29,5 @@ EXTERN_C(void getCPUUniqueID(char * s));
|
|||||||
#if defined(SIMU)
|
#if defined(SIMU)
|
||||||
extern const uint32_t cpu_uid[3];
|
extern const uint32_t cpu_uid[3];
|
||||||
#else
|
#else
|
||||||
extern const uint32_t * cpu_uid;
|
extern const uint32_t * const cpu_uid;
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -24,8 +24,8 @@
|
|||||||
|
|
||||||
#include "opentx.h"
|
#include "opentx.h"
|
||||||
|
|
||||||
const char *ghstRfProfileValue[GHST_RF_PROFILE_COUNT] = { "Auto", "Norm", "Race", "Pure", "Long", "Unused", "Race2", "Pure2" };
|
const char * const ghstRfProfileValue[GHST_RF_PROFILE_COUNT] = { "Auto", "Norm", "Race", "Pure", "Long", "Unused", "Race2", "Pure2" };
|
||||||
const char *ghstVtxBandName[GHST_VTX_BAND_COUNT] = { "- - -" , "IRC", "Race", "BandE", "BandB", "BandA" };
|
const char * const ghstVtxBandName[GHST_VTX_BAND_COUNT] = { "- - -" , "IRC", "Race", "BandE", "BandB", "BandA" };
|
||||||
|
|
||||||
struct GhostSensor
|
struct GhostSensor
|
||||||
{
|
{
|
||||||
|
|||||||
Vendored
+2
-2
@@ -50,7 +50,7 @@ extern LROT_TABLE(tablib);
|
|||||||
extern LROT_TABLE(rotables_meta);
|
extern LROT_TABLE(rotables_meta);
|
||||||
extern LROT_TABLE(base_func);
|
extern LROT_TABLE(base_func);
|
||||||
|
|
||||||
static const ROTable* _global_symbols[] = {
|
static const ROTable* const _global_symbols[] = {
|
||||||
LROT_TABLEREF(base_func),
|
LROT_TABLEREF(base_func),
|
||||||
LROT_TABLEREF(etxlib),
|
LROT_TABLEREF(etxlib),
|
||||||
LROT_TABLEREF(etxdir),
|
LROT_TABLEREF(etxdir),
|
||||||
@@ -61,7 +61,7 @@ static const ROTable* _global_symbols[] = {
|
|||||||
|
|
||||||
static int _index_hook_fct(lua_State * L)
|
static int _index_hook_fct(lua_State * L)
|
||||||
{
|
{
|
||||||
const ROTable** t = _global_symbols;
|
const ROTable* const* t = _global_symbols;
|
||||||
const TValue* res = luaO_nilobject;
|
const TValue* res = luaO_nilobject;
|
||||||
TString* key;
|
TString* key;
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -22,7 +22,7 @@
|
|||||||
constexpr coord_t KEYBOARD_HEIGHT = 90;
|
constexpr coord_t KEYBOARD_HEIGHT = 90;
|
||||||
NumberKeyboard * NumberKeyboard::_instance = nullptr;
|
NumberKeyboard * NumberKeyboard::_instance = nullptr;
|
||||||
|
|
||||||
static const char* number_kb_map[] = {
|
static const char* const number_kb_map[] = {
|
||||||
"<<", "-", "+", ">>", "\n",
|
"<<", "-", "+", ">>", "\n",
|
||||||
"MIN", "DEF", "+/-", "MAX", ""
|
"MIN", "DEF", "+/-", "MAX", ""
|
||||||
};
|
};
|
||||||
@@ -71,7 +71,7 @@ NumberKeyboard::NumberKeyboard() :
|
|||||||
{
|
{
|
||||||
// setup custom keyboard
|
// setup custom keyboard
|
||||||
lv_keyboard_set_map(keyboard, LV_KEYBOARD_MODE_USER_1,
|
lv_keyboard_set_map(keyboard, LV_KEYBOARD_MODE_USER_1,
|
||||||
number_kb_map, number_kb_ctrl_map);
|
(const char**)number_kb_map, number_kb_ctrl_map);
|
||||||
|
|
||||||
lv_keyboard_set_mode(keyboard, LV_KEYBOARD_MODE_USER_1);
|
lv_keyboard_set_mode(keyboard, LV_KEYBOARD_MODE_USER_1);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -48,8 +48,6 @@ ISTR(FUNCSOUNDS);
|
|||||||
ISTR(VTELEMUNIT);
|
ISTR(VTELEMUNIT);
|
||||||
ISTR(GPSFORMAT);
|
ISTR(GPSFORMAT);
|
||||||
ISTR(VTELEMSCREENTYPE);
|
ISTR(VTELEMSCREENTYPE);
|
||||||
ISTR(STICK_NAMES);
|
|
||||||
ISTR(SURFACE_NAMES);
|
|
||||||
ISTR(ON_ONE_SWITCHES);
|
ISTR(ON_ONE_SWITCHES);
|
||||||
#if defined(IMU)
|
#if defined(IMU)
|
||||||
ISTR(IMU_VSRCRAW);
|
ISTR(IMU_VSRCRAW);
|
||||||
@@ -1068,3 +1066,10 @@ const char STR_SYNC[] = TR_SYNC;
|
|||||||
const char STR_ENABLED_FEATURES[] = TR_ENABLED_FEATURES;
|
const char STR_ENABLED_FEATURES[] = TR_ENABLED_FEATURES;
|
||||||
const char STR_RADIO_MENU_TABS[] = TR_RADIO_MENU_TABS;
|
const char STR_RADIO_MENU_TABS[] = TR_RADIO_MENU_TABS;
|
||||||
const char STR_MODEL_MENU_TABS[] = TR_MODEL_MENU_TABS;
|
const char STR_MODEL_MENU_TABS[] = TR_MODEL_MENU_TABS;
|
||||||
|
|
||||||
|
const char STR_STICK_NAMES0[] = TR_STICK_NAMES0;
|
||||||
|
const char STR_STICK_NAMES1[] = TR_STICK_NAMES1;
|
||||||
|
const char STR_STICK_NAMES2[] = TR_STICK_NAMES2;
|
||||||
|
const char STR_STICK_NAMES3[] = TR_STICK_NAMES3;
|
||||||
|
const char STR_SURFACE_NAMES0[] = TR_SURFACE_NAMES0;
|
||||||
|
const char STR_SURFACE_NAMES1[] = TR_SURFACE_NAMES1;
|
||||||
|
|||||||
@@ -161,9 +161,7 @@ extern const char* const STR_GPSFORMAT[];
|
|||||||
extern const char* const STR_VTELEMSCREENTYPE[];
|
extern const char* const STR_VTELEMSCREENTYPE[];
|
||||||
extern const char* const STR_VSWASHTYPE[];
|
extern const char* const STR_VSWASHTYPE[];
|
||||||
|
|
||||||
extern const char* const STR_STICK_NAMES[];
|
|
||||||
extern const char* const STR_ON_ONE_SWITCHES[];
|
extern const char* const STR_ON_ONE_SWITCHES[];
|
||||||
extern const char* const STR_SURFACE_NAMES[];
|
|
||||||
#if defined(IMU)
|
#if defined(IMU)
|
||||||
extern const char* const STR_IMU_VSRCRAW[];
|
extern const char* const STR_IMU_VSRCRAW[];
|
||||||
#endif
|
#endif
|
||||||
@@ -247,6 +245,13 @@ extern const char* const STR_BLUETOOTH_MODES[];
|
|||||||
|
|
||||||
#define NO_INDENT(x) (x) + LEN_INDENT
|
#define NO_INDENT(x) (x) + LEN_INDENT
|
||||||
|
|
||||||
|
extern const char STR_STICK_NAMES0[];
|
||||||
|
extern const char STR_STICK_NAMES1[];
|
||||||
|
extern const char STR_STICK_NAMES2[];
|
||||||
|
extern const char STR_STICK_NAMES3[];
|
||||||
|
extern const char STR_SURFACE_NAMES0[];
|
||||||
|
extern const char STR_SURFACE_NAMES1[];
|
||||||
|
|
||||||
extern const char STR_EMPTY[];
|
extern const char STR_EMPTY[];
|
||||||
extern const char STR_POPUPS_ENTER_EXIT[];
|
extern const char STR_POPUPS_ENTER_EXIT[];
|
||||||
extern const char STR_OK[];
|
extern const char STR_OK[];
|
||||||
|
|||||||
@@ -141,8 +141,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Rud", "Ele", "Thr", "Ail"
|
#define TR_STICK_NAMES0 "Rud"
|
||||||
#define TR_SURFACE_NAMES "ST", "TH"
|
#define TR_STICK_NAMES1 "Ele"
|
||||||
|
#define TR_STICK_NAMES2 "Thr"
|
||||||
|
#define TR_STICK_NAMES3 "Ail"
|
||||||
|
#define TR_SURFACE_NAMES0 "ST"
|
||||||
|
#define TR_SURFACE_NAMES1 "TH"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -153,8 +153,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Smě", "Výš", "Pln", "Kři"
|
#define TR_STICK_NAMES0 "Smě"
|
||||||
#define TR_SURFACE_NAMES "Smě", "Pln"
|
#define TR_STICK_NAMES1 "Výš"
|
||||||
|
#define TR_STICK_NAMES2 "Pln"
|
||||||
|
#define TR_STICK_NAMES3 "Kři"
|
||||||
|
#define TR_SURFACE_NAMES0 "Smě"
|
||||||
|
#define TR_SURFACE_NAMES1 "Pln"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Defaultní","Vysoký"
|
#define TR_RFPOWER_AFHDS2 "Defaultní","Vysoký"
|
||||||
|
|||||||
@@ -149,8 +149,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Sid", "Høj", "Gas", "Kræ"
|
#define TR_STICK_NAMES0 "Sid"
|
||||||
#define TR_SURFACE_NAMES "Sid", "Gas"
|
#define TR_STICK_NAMES1 "Høj"
|
||||||
|
#define TR_STICK_NAMES2 "Gas"
|
||||||
|
#define TR_STICK_NAMES3 "Kræ"
|
||||||
|
#define TR_SURFACE_NAMES0 "Sid"
|
||||||
|
#define TR_SURFACE_NAMES1 "Gas"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Standard","Høj"
|
#define TR_RFPOWER_AFHDS2 "Standard","Høj"
|
||||||
|
|||||||
@@ -143,8 +143,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Sei", "Höh", "Gas", "Que"
|
#define TR_STICK_NAMES0 "Sei"
|
||||||
#define TR_SURFACE_NAMES "Str", "Gas"
|
#define TR_STICK_NAMES1 "Höh"
|
||||||
|
#define TR_STICK_NAMES2 "Gas"
|
||||||
|
#define TR_STICK_NAMES3 "Que"
|
||||||
|
#define TR_SURFACE_NAMES0 "Str"
|
||||||
|
#define TR_SURFACE_NAMES1 "Gas"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -146,8 +146,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Rud", "Ele", "Thr", "Ail"
|
#define TR_STICK_NAMES0 "Rud"
|
||||||
#define TR_SURFACE_NAMES "ST", "TH"
|
#define TR_STICK_NAMES1 "Ele"
|
||||||
|
#define TR_STICK_NAMES2 "Thr"
|
||||||
|
#define TR_STICK_NAMES3 "Ail"
|
||||||
|
#define TR_SURFACE_NAMES0 "ST"
|
||||||
|
#define TR_SURFACE_NAMES1 "TH"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -141,8 +141,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Rud", "Ele", "Thr", "Ail"
|
#define TR_STICK_NAMES0 "Rud"
|
||||||
#define TR_SURFACE_NAMES "ST", "TH"
|
#define TR_STICK_NAMES1 "Ele"
|
||||||
|
#define TR_STICK_NAMES2 "Thr"
|
||||||
|
#define TR_STICK_NAMES3 "Ail"
|
||||||
|
#define TR_SURFACE_NAMES0 "ST"
|
||||||
|
#define TR_SURFACE_NAMES1 "TH"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -152,8 +152,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Rud", "Ele", "Thr", "Ail"
|
#define TR_STICK_NAMES0 "Rud"
|
||||||
#define TR_SURFACE_NAMES "ST", "TH"
|
#define TR_STICK_NAMES1 "Ele"
|
||||||
|
#define TR_STICK_NAMES2 "Thr"
|
||||||
|
#define TR_STICK_NAMES3 "Ail"
|
||||||
|
#define TR_SURFACE_NAMES0 "ST"
|
||||||
|
#define TR_SURFACE_NAMES1 "TH"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -153,8 +153,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "--- ","120","120X","140","90"
|
#define TR_VSWASHTYPE "--- ","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Dir", "Prf", "Gaz", "Ail"
|
#define TR_STICK_NAMES0 "Dir"
|
||||||
#define TR_SURFACE_NAMES "Dir", "Gaz"
|
#define TR_STICK_NAMES1 "Prf"
|
||||||
|
#define TR_STICK_NAMES2 "Gaz"
|
||||||
|
#define TR_STICK_NAMES3 "Ail"
|
||||||
|
#define TR_SURFACE_NAMES0 "Dir"
|
||||||
|
#define TR_SURFACE_NAMES1 "Gaz"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Défaut","Haut"
|
#define TR_RFPOWER_AFHDS2 "Défaut","Haut"
|
||||||
|
|||||||
@@ -200,38 +200,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICKS_VSRCRAW STR_CHAR_STICK "ה.כיוון", STR_CHAR_STICK "ה.גובה", STR_CHAR_STICK "מצערת", STR_CHAR_STICK "מאזנות"
|
#define TR_STICK_NAMES0 "כיוון"
|
||||||
|
#define TR_STICK_NAMES1 "ה.גוב"
|
||||||
#if defined(PCBHORUS)
|
#define TR_STICK_NAMES2 "מצערת"
|
||||||
#define TR_TRIMS_VSRCRAW STR_CHAR_TRIM "ה.כיוון", STR_CHAR_TRIM "ה.גובה", STR_CHAR_TRIM "מצערת", STR_CHAR_TRIM "מאזנות", STR_CHAR_TRIM "T5", STR_CHAR_TRIM "T6"
|
#define TR_STICK_NAMES3 "מאזנות"
|
||||||
#else
|
#define TR_SURFACE_NAMES0 "ST"
|
||||||
#define TR_TRIMS_VSRCRAW STR_CHAR_TRIM "ה.כיוון", STR_CHAR_TRIM "ה.גובה", STR_CHAR_TRIM "מצערת", STR_CHAR_TRIM "מאזנות"
|
#define TR_SURFACE_NAMES1 "TH"
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(PCBHORUS)
|
|
||||||
#define TR_TRIMS_SWITCHES STR_CHAR_TRIM "Rl", STR_CHAR_TRIM "Rr", STR_CHAR_TRIM "Ed", STR_CHAR_TRIM "Eu", STR_CHAR_TRIM "Td", STR_CHAR_TRIM "Tu", STR_CHAR_TRIM "Al", STR_CHAR_TRIM "Ar", STR_CHAR_TRIM "5d", STR_CHAR_TRIM "5u", STR_CHAR_TRIM "6d", STR_CHAR_TRIM "6u"
|
|
||||||
#else
|
|
||||||
#define TRIM_SWITCH_CHAR TR("t",STR_CHAR_TRIM)
|
|
||||||
#define TR_TRIMS_SWITCHES TRIM_SWITCH_CHAR "Rl", TRIM_SWITCH_CHAR "Rr", TRIM_SWITCH_CHAR "Ed", TRIM_SWITCH_CHAR "Eu", TRIM_SWITCH_CHAR "Td", TRIM_SWITCH_CHAR "Tu", TRIM_SWITCH_CHAR "Al", TRIM_SWITCH_CHAR "Ar"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(PCBHORUS) || defined(PCBNV14)
|
|
||||||
#define TR_VKEYS "PGUP","PGDN","ENTER","MDL","RTN","TELE","SYS"
|
|
||||||
#elif defined(PCBXLITE)
|
|
||||||
#define TR_VKEYS "Shift","Exit","Enter","Down","Up","Right","Left"
|
|
||||||
#elif defined(RADIO_FAMILY_JUMPER_T12)
|
|
||||||
#define TR_VKEYS "Exit","Enter","Down","Up","Right","Left"
|
|
||||||
#elif defined(RADIO_TX12) || defined(RADIO_TX12MK2)
|
|
||||||
#define TR_VKEYS "Exit","Enter","PGUP","PGDN","SYS","MDL","TELE"
|
|
||||||
#elif defined(RADIO_T8) || defined(RADIO_COMMANDO8)
|
|
||||||
#define TR_VKEYS "RTN","ENTER","PGUP","PGDN","SYS","MDL","UP","DOWN"
|
|
||||||
#elif defined(RADIO_ZORRO)
|
|
||||||
#define TR_VKEYS "RTN","ENTER","PGUP","PGDN","SYS","MDL","TELE"
|
|
||||||
#elif defined(PCBTARANIS)
|
|
||||||
#define TR_VKEYS "תפריט","יציאה","אישור","דף","פלוס","מינוס"
|
|
||||||
#else
|
|
||||||
#define TR_VKEYS "תפריט","יציאה","למטה","למעלה","ימין","שמאל"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -146,8 +146,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Dir", "Ele", "Mot", "Ale"
|
#define TR_STICK_NAMES0 "Dir"
|
||||||
#define TR_SURFACE_NAMES "Dir", "Mot"
|
#define TR_STICK_NAMES1 "Ele"
|
||||||
|
#define TR_STICK_NAMES2 "Mot
|
||||||
|
#define TR_STICK_NAMES3 "Ale"
|
||||||
|
#define TR_SURFACE_NAMES0 "Dir"
|
||||||
|
#define TR_SURFACE_NAMES1 "Mot"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","Alto"
|
#define TR_RFPOWER_AFHDS2 "Default","Alto"
|
||||||
|
|||||||
@@ -146,8 +146,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Rud", "Ele", "Thr", "Ail"
|
#define TR_STICK_NAMES0 "Rud"
|
||||||
#define TR_SURFACE_NAMES "ST", "TH"
|
#define TR_STICK_NAMES1 "Ele"
|
||||||
|
#define TR_STICK_NAMES2 "Thr"
|
||||||
|
#define TR_STICK_NAMES3 "Ail"
|
||||||
|
#define TR_SURFACE_NAMES0 "ST"
|
||||||
|
#define TR_SURFACE_NAMES1 "TH"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -143,8 +143,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Rud", "Ele", "Thr", "Ail"
|
#define TR_STICK_NAMES0 "Rud"
|
||||||
#define TR_SURFACE_NAMES "ST", "TH"
|
#define TR_STICK_NAMES1 "Ele"
|
||||||
|
#define TR_STICK_NAMES2 "Thr"
|
||||||
|
#define TR_STICK_NAMES3 "Ail"
|
||||||
|
#define TR_SURFACE_NAMES0 "ST"
|
||||||
|
#define TR_SURFACE_NAMES1 "TH"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -141,8 +141,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "SK", "SW", "Gaz", "Lot"
|
#define TR_STICK_NAMES0 "SK"
|
||||||
#define TR_SURFACE_NAMES "SK", "Gaz"
|
#define TR_STICK_NAMES1 "SW"
|
||||||
|
#define TR_STICK_NAMES2 "Gaz"
|
||||||
|
#define TR_STICK_NAMES3 "Lot"
|
||||||
|
#define TR_SURFACE_NAMES0 "SK"
|
||||||
|
#define TR_SURFACE_NAMES1 "Gaz"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -149,8 +149,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Lem", "Pfd", "Mot", "Ail"
|
#define TR_STICK_NAMES0 "Lem"
|
||||||
#define TR_SURFACE_NAMES "Dir", "Mot"
|
#define TR_STICK_NAMES1 "Mot"
|
||||||
|
#define TR_STICK_NAMES2 "Thr"
|
||||||
|
#define TR_STICK_NAMES3 "Ail"
|
||||||
|
#define TR_SURFACE_NAMES0 "Dir"
|
||||||
|
#define TR_SURFACE_NAMES1 "Mot"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -157,8 +157,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Rod", "Hjd", "Gas", "Ske"
|
#define TR_STICK_NAMES0 "Rod"
|
||||||
#define TR_SURFACE_NAMES "Rod", "Gas"
|
#define TR_STICK_NAMES1 "Hjd"
|
||||||
|
#define TR_STICK_NAMES2 "Gas"
|
||||||
|
#define TR_STICK_NAMES3 "Ske"
|
||||||
|
#define TR_SURFACE_NAMES0 "Rod"
|
||||||
|
#define TR_SURFACE_NAMES1 "Gas"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","Hög"
|
#define TR_RFPOWER_AFHDS2 "Default","Hög"
|
||||||
|
|||||||
@@ -146,8 +146,12 @@
|
|||||||
|
|
||||||
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
#define TR_VSWASHTYPE "---","120","120X","140","90"
|
||||||
|
|
||||||
#define TR_STICK_NAMES "Rud", "Ele", "Thr", "Ail"
|
#define TR_STICK_NAMES0 "Rud"
|
||||||
#define TR_SURFACE_NAMES "ST", "TH"
|
#define TR_STICK_NAMES1 "Ele"
|
||||||
|
#define TR_STICK_NAMES2 "Thr"
|
||||||
|
#define TR_STICK_NAMES3 "Ail"
|
||||||
|
#define TR_SURFACE_NAMES0 "ST"
|
||||||
|
#define TR_SURFACE_NAMES1 "TH"
|
||||||
|
|
||||||
#if defined(PCBNV14)
|
#if defined(PCBNV14)
|
||||||
#define TR_RFPOWER_AFHDS2 "Default","High"
|
#define TR_RFPOWER_AFHDS2 "Default","High"
|
||||||
|
|||||||
@@ -7,13 +7,13 @@ import json_index
|
|||||||
|
|
||||||
MAIN_CONTROL_LUT = {
|
MAIN_CONTROL_LUT = {
|
||||||
# 2 Gimbal radios
|
# 2 Gimbal radios
|
||||||
"LH": { "str": "Rud", "local": "STR_STICK_NAMES[0]" },
|
"LH": { "str": "Rud", "local": "STR_STICK_NAMES0" },
|
||||||
"LV": { "str": "Ele", "local": "STR_STICK_NAMES[1]" },
|
"LV": { "str": "Ele", "local": "STR_STICK_NAMES1" },
|
||||||
"RV": { "str": "Thr", "local": "STR_STICK_NAMES[2]" },
|
"RV": { "str": "Thr", "local": "STR_STICK_NAMES2" },
|
||||||
"RH": { "str": "Ail", "local": "STR_STICK_NAMES[3]" },
|
"RH": { "str": "Ail", "local": "STR_STICK_NAMES3" },
|
||||||
# Surface radios
|
# Surface radios
|
||||||
"ST": { "str": "ST", "local": "STR_SURFACE_NAMES[0]" },
|
"ST": { "str": "ST", "local": "STR_SURFACE_NAMES0" },
|
||||||
"TH": { "str": "TH", "local": "STR_SURFACE_NAMES[1]" },
|
"TH": { "str": "TH", "local": "STR_SURFACE_NAMES1" },
|
||||||
}
|
}
|
||||||
|
|
||||||
# MUST be the same order as 'EnumKeys'
|
# MUST be the same order as 'EnumKeys'
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ static const etx_hal_adc_input_t _main_inputs[] = {
|
|||||||
{% set pot_offset = n_mains %}
|
{% set pot_offset = n_mains %}
|
||||||
{% set pot_inputs = adc_inputs.inputs | selectattr('type', '==', 'POT') | list %}
|
{% set pot_inputs = adc_inputs.inputs | selectattr('type', '==', 'POT') | list %}
|
||||||
{% set n_pots = pot_inputs | count %}
|
{% set n_pots = pot_inputs | count %}
|
||||||
static etx_hal_adc_input_t _pot_inputs[] = {
|
static const etx_hal_adc_input_t _pot_inputs[] = {
|
||||||
{% for input in pot_inputs %}
|
{% for input in pot_inputs %}
|
||||||
{ "{{ input.name }}", "{{ input.label }}", "{{ input.short_label }}" },
|
{ "{{ input.name }}", "{{ input.label }}", "{{ input.short_label }}" },
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
@@ -24,7 +24,7 @@ static etx_hal_adc_input_t _pot_inputs[] = {
|
|||||||
{% set axis_offset = pot_offset + n_pots %}
|
{% set axis_offset = pot_offset + n_pots %}
|
||||||
{% set axis_inputs = adc_inputs.inputs | selectattr('type', '==', 'AXIS') | list %}
|
{% set axis_inputs = adc_inputs.inputs | selectattr('type', '==', 'AXIS') | list %}
|
||||||
{% set n_axis = axis_inputs | count %}
|
{% set n_axis = axis_inputs | count %}
|
||||||
static etx_hal_adc_input_t _axis_inputs[] = {
|
static const etx_hal_adc_input_t _axis_inputs[] = {
|
||||||
{% for input in axis_inputs %}
|
{% for input in axis_inputs %}
|
||||||
{ "{{ input.name }}", "{{ input.label }}", nullptr },
|
{ "{{ input.name }}", "{{ input.label }}", nullptr },
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
@@ -33,7 +33,7 @@ static etx_hal_adc_input_t _axis_inputs[] = {
|
|||||||
{% set vbat_offset = axis_offset + n_axis %}
|
{% set vbat_offset = axis_offset + n_axis %}
|
||||||
{% set vbat_inputs = adc_inputs.inputs | selectattr('type', '==', 'VBAT') | list %}
|
{% set vbat_inputs = adc_inputs.inputs | selectattr('type', '==', 'VBAT') | list %}
|
||||||
{% set n_vbat = vbat_inputs | count %}
|
{% set n_vbat = vbat_inputs | count %}
|
||||||
static etx_hal_adc_input_t _vbat_inputs[] = {
|
static const etx_hal_adc_input_t _vbat_inputs[] = {
|
||||||
{% for input in vbat_inputs %}
|
{% for input in vbat_inputs %}
|
||||||
{ "{{ input.name }}", nullptr, nullptr },
|
{ "{{ input.name }}", nullptr, nullptr },
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
@@ -42,7 +42,7 @@ static etx_hal_adc_input_t _vbat_inputs[] = {
|
|||||||
{% set rtc_bat_offset = vbat_offset + n_vbat %}
|
{% set rtc_bat_offset = vbat_offset + n_vbat %}
|
||||||
{% set rtc_bat_inputs = adc_inputs.inputs | selectattr('type', '==', 'RTC_BAT') | list %}
|
{% set rtc_bat_inputs = adc_inputs.inputs | selectattr('type', '==', 'RTC_BAT') | list %}
|
||||||
{% set n_rtc_bat = rtc_bat_inputs | count %}
|
{% set n_rtc_bat = rtc_bat_inputs | count %}
|
||||||
static etx_hal_adc_input_t _rtc_bat_inputs[] = {
|
static const etx_hal_adc_input_t _rtc_bat_inputs[] = {
|
||||||
{% for input in rtc_bat_inputs %}
|
{% for input in rtc_bat_inputs %}
|
||||||
{ "{{ input.name }}", nullptr, nullptr },
|
{ "{{ input.name }}", nullptr, nullptr },
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|||||||
Reference in New Issue
Block a user