[stock] Flash saving
Companion9x compilation
This commit is contained in:
+2
-2
@@ -3398,7 +3398,7 @@ void menuModelTelemetry(uint8_t event)
|
|||||||
case ITEM_TELEMETRY_SCREEN_LABEL3:
|
case ITEM_TELEMETRY_SCREEN_LABEL3:
|
||||||
{
|
{
|
||||||
uint8_t screenIndex = (k < ITEM_TELEMETRY_SCREEN_LABEL2 ? 0 : (k < ITEM_TELEMETRY_SCREEN_LABEL3 ? 1 : 2));
|
uint8_t screenIndex = (k < ITEM_TELEMETRY_SCREEN_LABEL2 ? 0 : (k < ITEM_TELEMETRY_SCREEN_LABEL3 ? 1 : 2));
|
||||||
bool screenType = IS_BARS_SCREEN(screenIndex);
|
int8_t screenType = IS_BARS_SCREEN(screenIndex);
|
||||||
putsStrIdx(0*FW, y, STR_SCREEN, screenIndex+1);
|
putsStrIdx(0*FW, y, STR_SCREEN, screenIndex+1);
|
||||||
if (screenType != selectMenuItem(10*FW, y, PSTR(""), STR_VSCREEN, screenType, 0, 1, attr, event))
|
if (screenType != selectMenuItem(10*FW, y, PSTR(""), STR_VSCREEN, screenType, 0, 1, attr, event))
|
||||||
g_model.frsky.screensType ^= (1 << screenIndex);
|
g_model.frsky.screensType ^= (1 << screenIndex);
|
||||||
@@ -3407,7 +3407,7 @@ void menuModelTelemetry(uint8_t event)
|
|||||||
#else
|
#else
|
||||||
{
|
{
|
||||||
uint8_t screenIndex = (k < ITEM_TELEMETRY_SCREEN_LABEL2 ? 1 : 2);
|
uint8_t screenIndex = (k < ITEM_TELEMETRY_SCREEN_LABEL2 ? 1 : 2);
|
||||||
bool screenType = g_model.frsky.screensType & screenIndex;
|
int8_t screenType = g_model.frsky.screensType & screenIndex;
|
||||||
putsStrIdx(0*FW, y, STR_SCREEN, screenIndex);
|
putsStrIdx(0*FW, y, STR_SCREEN, screenIndex);
|
||||||
if (screenType != selectMenuItem(10*FW, y, PSTR(""), STR_VSCREEN, screenType, 0, 1, attr, event))
|
if (screenType != selectMenuItem(10*FW, y, PSTR(""), STR_VSCREEN, screenType, 0, 1, attr, event))
|
||||||
g_model.frsky.screensType ^= screenIndex;
|
g_model.frsky.screensType ^= screenIndex;
|
||||||
|
|||||||
@@ -35,9 +35,6 @@
|
|||||||
#ifndef open9x_h
|
#ifndef open9x_h
|
||||||
#define open9x_h
|
#define open9x_h
|
||||||
|
|
||||||
#define MAJ_VERS 2
|
|
||||||
#define MIN_VERS 00
|
|
||||||
|
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
|||||||
+1
-1
@@ -685,5 +685,5 @@ void I2S_Cmd(SPI_TypeDef* SPIx, FunctionalState NewState) { }
|
|||||||
void SPI_I2S_ITConfig(SPI_TypeDef* SPIx, uint8_t SPI_I2S_IT, FunctionalState NewState) { }
|
void SPI_I2S_ITConfig(SPI_TypeDef* SPIx, uint8_t SPI_I2S_IT, FunctionalState NewState) { }
|
||||||
void RCC_LSEConfig(uint8_t RCC_LSE) { }
|
void RCC_LSEConfig(uint8_t RCC_LSE) { }
|
||||||
FlagStatus RCC_GetFlagStatus(uint8_t RCC_FLAG) { return RESET; }
|
FlagStatus RCC_GetFlagStatus(uint8_t RCC_FLAG) { return RESET; }
|
||||||
ErrorStatus RTC_WaitForSynchro(void) { return ERROR; }
|
ErrorStatus RTC_WaitForSynchro(void) { return SUCCESS; }
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
+2
@@ -1176,7 +1176,9 @@ typedef struct
|
|||||||
#define GPIOG ((GPIO_TypeDef *) GPIOG_BASE)
|
#define GPIOG ((GPIO_TypeDef *) GPIOG_BASE)
|
||||||
#define GPIOH ((GPIO_TypeDef *) GPIOH_BASE)
|
#define GPIOH ((GPIO_TypeDef *) GPIOH_BASE)
|
||||||
#define GPIOI ((GPIO_TypeDef *) GPIOI_BASE)
|
#define GPIOI ((GPIO_TypeDef *) GPIOI_BASE)
|
||||||
|
#if !defined WIN32 && defined __GNUC__
|
||||||
#define CRC ((CRC_TypeDef *) CRC_BASE)
|
#define CRC ((CRC_TypeDef *) CRC_BASE)
|
||||||
|
#endif
|
||||||
#define RCC ((RCC_TypeDef *) RCC_BASE)
|
#define RCC ((RCC_TypeDef *) RCC_BASE)
|
||||||
#define FLASH ((FLASH_TypeDef *) FLASH_R_BASE)
|
#define FLASH ((FLASH_TypeDef *) FLASH_R_BASE)
|
||||||
#define DMA1 ((DMA_TypeDef *) DMA1_BASE)
|
#define DMA1 ((DMA_TypeDef *) DMA1_BASE)
|
||||||
|
|||||||
Reference in New Issue
Block a user