Skip pv screen if no generation
This commit is contained in:
parent
091fe5c926
commit
70d53bb2af
20
src/main.cpp
20
src/main.cpp
|
@ -500,7 +500,15 @@ void loop() {
|
|||
lastScreenChangeTime += DISPLAY_SCREEN_INTERVAL;
|
||||
if (display_screen == display_last_screen + 1)
|
||||
{
|
||||
display_screen = 0;
|
||||
//If no pv power generated, skip PV charger screen
|
||||
if (pv_kwh == 0)
|
||||
{
|
||||
display_screen = 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
display_screen = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -512,7 +520,15 @@ void loop() {
|
|||
display_screen++;
|
||||
if (display_screen == display_last_screen + 1)
|
||||
{
|
||||
display_screen = 0;
|
||||
//If no pv power generated, skip PV charger screen
|
||||
if (pv_kwh == 0)
|
||||
{
|
||||
display_screen = 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
display_screen = 0;
|
||||
}
|
||||
}
|
||||
lastButtonRotationState = currentButtonRotationState;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue