LCD bugfix on EEPROM alerts. No more Splash if splash disabled
This commit is contained in:
@@ -2575,16 +2575,13 @@ void opentxInit(OPENTX_INIT_ARGS)
|
|||||||
eeReadAll();
|
eeReadAll();
|
||||||
|
|
||||||
#if defined(CPUARM)
|
#if defined(CPUARM)
|
||||||
if (UNEXPECTED_SHUTDOWN())
|
if (UNEXPECTED_SHUTDOWN()) {
|
||||||
unexpectedShutdown = 1;
|
unexpectedShutdown = 1;
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(PCBTARANIS)
|
#if defined(PCBTARANIS)
|
||||||
#if !defined(SIMU)
|
|
||||||
lcdInitFinish();
|
|
||||||
#endif
|
|
||||||
BACKLIGHT_ON();
|
BACKLIGHT_ON();
|
||||||
Splash();
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if MENUS_LOCK == 1
|
#if MENUS_LOCK == 1
|
||||||
|
|||||||
@@ -28,6 +28,10 @@
|
|||||||
extern void hw_delay(uint16_t time);
|
extern void hw_delay(uint16_t time);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if !defined(BOOT)
|
||||||
|
bool lcdInitFinished = false;
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
In boot-loader: init_hw_timer() must be called before the first call to this function!
|
In boot-loader: init_hw_timer() must be called before the first call to this function!
|
||||||
In opentx: delaysInit() must be called before the first call to this function!
|
In opentx: delaysInit() must be called before the first call to this function!
|
||||||
@@ -188,6 +192,12 @@ void lcdRefreshWait()
|
|||||||
|
|
||||||
void lcdRefresh(bool wait)
|
void lcdRefresh(bool wait)
|
||||||
{
|
{
|
||||||
|
#if !defined(BOOT)
|
||||||
|
if (!lcdInitFinished) {
|
||||||
|
lcdInitFinish();
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
//wait if previous DMA transfer still active
|
//wait if previous DMA transfer still active
|
||||||
WAIT_FOR_DMA_END();
|
WAIT_FOR_DMA_END();
|
||||||
lcd_busy = true;
|
lcd_busy = true;
|
||||||
@@ -231,6 +241,12 @@ extern "C" void DMA1_Stream7_IRQHandler()
|
|||||||
#else // #if defined(REVPLUS)
|
#else // #if defined(REVPLUS)
|
||||||
void lcdRefresh()
|
void lcdRefresh()
|
||||||
{
|
{
|
||||||
|
#if !defined(BOOT)
|
||||||
|
if (!lcdInitFinished) {
|
||||||
|
lcdInitFinish();
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
for (uint32_t y=0; y<LCD_H; y++) {
|
for (uint32_t y=0; y<LCD_H; y++) {
|
||||||
uint8_t *p = &displayBuf[y/2 * LCD_W];
|
uint8_t *p = &displayBuf[y/2 * LCD_W];
|
||||||
|
|
||||||
@@ -373,6 +389,10 @@ void lcdInitStart()
|
|||||||
*/
|
*/
|
||||||
void lcdInitFinish()
|
void lcdInitFinish()
|
||||||
{
|
{
|
||||||
|
#if !defined(BOOT)
|
||||||
|
lcdInitFinished = true;
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(REVPLUS)
|
#if defined(REVPLUS)
|
||||||
initLcdSpi();
|
initLcdSpi();
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Reference in New Issue
Block a user