StatusDisplay shows wifi status and ip again

This commit is contained in:
2021-06-29 11:10:42 +02:00
parent 4b9ef50d06
commit 7bbe705331
3 changed files with 7 additions and 4 deletions

View File

@ -417,7 +417,7 @@ void sendCanCommands()
case 10:
if (send(Boardcomputer::Feedback::ButtonLeds, buttonLeds) == ESP_OK)
lastValues.buttonLeds = buttonLeds;
[[fallthrough]]
[[fallthrough]];
default:
i=0;
break;

View File

@ -157,9 +157,12 @@ void StatusDisplay::redraw()
m_backStatus.redraw(controllers.back);
tft.setTextFont(2);
//m_labelWifiStatus.redraw(to_string(WiFi.status()));
m_labelWifiStatus.redraw(wifi_stack::toString(wifi_stack::get_sta_status()));
m_labelLimit0.redraw(std::to_string(controllers.front.command.left.iMotMax) + "A");
//m_labelIpAddress.redraw(to_string(WiFi.localIP()));
if (const auto result = wifi_stack::get_ip_info(TCPIP_ADAPTER_IF_STA))
m_labelIpAddress.redraw(wifi_stack::toString(result->ip));
else
m_labelIpAddress.clear();
m_labelLimit1.redraw(std::to_string(controllers.front.command.left.iDcMax) + "A");
m_labelPerformance.redraw(std::to_string(performance.last));
m_labelMode.redraw(currentMode->displayName());